cancel
Showing results for 
Search instead for 
Did you mean: 

How to display user list logged in SAP without SAP Gui

Former Member
0 Kudos

Hi Expert,

I want to know how many user logged in SAP.

But I can't use SAP Gui but can use UNIX command in UNIX (SUN).

Plz, tell me how to display user list logged in SAP wihout SAP Gui.

Thank you in advance.

regards,

1$

Accepted Solutions (1)

Accepted Solutions (1)

markus_doehr2
Active Contributor
0 Kudos

> I want to know how many user logged in SAP.

> But I can't use SAP Gui but can use UNIX command in UNIX (SUN).

There is a Java-SAPGUI for Sun Solaris

> Plz, tell me how to display user list logged in SAP wihout SAP Gui.

You can e. g. use emmon

Markus

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

If this is really an administration tool you want and not just a one-off, and if you're willing and able to do some coding, then this will certainly work:

1) Create an RFC-callable function module, which calls the SAP standard function TH_REMOTE_USER_LIST

2) Create a shell script in UNIX which uses the 'startrfc' utility to call your function and capture the output in a file, and which then decodes the file

Rgds,

Mark

Former Member
0 Kudos

One quick and dirty way i use, is to count the connections to the dispatcher port (for example 3200). Obviously this does not always show the correct number of users, but it is very simple:

user% netstat -an|grep 3200|grep ESTABLISHED|wc -l

Regards, Michael

Former Member
0 Kudos

Hi Michael,

Thank you for your help.

It is not equal between your recommend and Active list in t-code SM04 .

Count of netstat is much less than SM04.

(used command : netstat -an|grep ESTABLISHED|wc -l)

Could you help me again?

regards,

1$

Former Member
0 Kudos

Well I cannot see what you see in your SM04 with traditional methods. But I can give you a more detailed example.

I have a ERP 6.0 system were only gui users work, not http access is done. In SM04 I see a total of 75 users logged on, having 112 modi.

Doing the netstat I can count 53 connections (we get only one connection per user, no matter how many windows he opened). So why am I missing 22 users? In my case there are in fact only 53 gui users logged on, the others are RFC logons and they connect to port 3300 (the sap gateway).

But as i said earlier, your results will vary, because the netstat counts connections on the dispatcher, and the SM04 reports users logged on. Both things are related, but not the same...

Regards, Michael