Highlighted
Absent Member.
Absent Member.
2454 views

[archive] C$SYSTEM "acurcl -info" windows server

[Migrated content. Thread originally posted on 22 May 2008]

Has anyone run this command from a thin client session in order to parse the results to display in a window on the client to see who is connected via thin client from any workstation?

Here is what I'm doing. It does create the file, but it's empty and it seems to take a very long time. the command works properly (albeit a bit different looking) when run on a unix server. But when running windows 2000 server it doesn't... As you can see I have tried the full path to the .exe, I have tried just about everything and no go. Any ideas would be helpful.

          MOVE SPACES TO WS-COMMAND.
           STRING  "C:\Acucorp\Acucbl610\AcuGT\bin\acurcl ",
                       "-info 2> .\files\thinclients.log"
                 DELIMITED BY SIZE INTO WS-COMMAND
           END-STRING.
           MOVE ZEROS TO WS-CTR.
           INSPECT WS-COMMAND TALLYING WS-CTR FOR TRAILING SPACES.
           COMPUTE WS-CTR = FUNCTION LENGTH(WS-COMMAND) - WS-CTR.
           IF TERM-IS-REMOTE
              CALL "C$SYSTEM" USING WS-COMMAND(1:WS-CTR), 96
                              GIVING EXIT-STATUS
              CANCEL "C$SYSTEM"
           ELSE
              CALL "C$SYSTEM" USING WS-COMMAND(1:WS-CTR)
                              GIVING EXIT-STATUS
              CANCEL "C$SYSTEM"
           END-IF.
           IF EXIT-STATUS = 0
              | open notpad and view the file
           END-IF.
0 Likes
12 Replies
Highlighted
Absent Member.
Absent Member.

RE: [archive] C$SYSTEM "acurcl -info" windows server

I suspect your output is probably going to standard output instead of standard error, even though it goes to stderr when run in foreground. Try altering your redirection to this:-C:\Acucorp\Acucbl610\AcuGT\bin\acurcl -info > .\files\thinclients.log 2>&1
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] C$SYSTEM "acurcl -info" windows server

Unfortunately that didn't make any difference, still no output into my file. I have a sneaky suspicion that acurcl when run from a command line in a GUI environment (windows) it's attempting to open the GUI and not just run it as a command line.

On a side note, the call now works when I'm sitting on the server running the application, but it doesn't work from a thin client session...

Thanks for the input tho.
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] C$SYSTEM "acurcl -info" windows server

Excuse my ignorance - but what exactly is acurcl? It is not in my acugt/bin directory (version 720).
Keith
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] C$SYSTEM "acurcl -info" windows server

It's the thin client server, it handles all the thin client connections to your application.
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] C$SYSTEM "acurcl -info" windows server

attempting to send output to stdout is not available under thin client. output should be redirected to a file.
What are the permission on the .\files directory?
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] C$SYSTEM "acurcl -info" windows server

attempting to send output to stdout is not available under thin client. output should be redirected to a file.
What are the permission on the .\files directory?



Hmm I thought I was redirecting to a file... the folder has full access permissions set on it for all users so I don't think it's a permissions peroblem.

when I step through the code from the thin client session I notice the C$SYSTEM call takes almost 10 seconds to complete and come back. Also the EXIT-STATUS is zero, and the file does get created, so the call was successful just no output in the file.
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] C$SYSTEM "acurcl -info" windows server

When you execute your program on the server (without running it via Thin client) does the acurcl -info succeed?

I thought that you needed to be Administrator to execute acurcl -info

Is the Access file allowing you to execute as Administrator when you do use Thin client?
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] C$SYSTEM "acurcl -info" windows server

When you execute your program on the server (without running it via Thin client) does the acurcl -info succeed?


Yes

I thought that you needed to be Administrator to execute acurcl -info


You could be correct, but when running via thin client the user appears to be the SYSTEM (which has administrator privledges) but not Admistrator. I checked this by looking at the task manager on the server when I was connected to my application via thin client.

User is SYSTEM (not Administrator) could this be a problem?


Is the Access file allowing you to execute as Administrator when you do use Thin client?


We have the umask set to 222 and the local username is set to a user with administrator privledges but not the administrator, and not SYSTEM so I don't know why it's using SYSTEM to run the application via thin client.
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] C$SYSTEM "acurcl -info" windows server

It works for me using "c:\...\acurcl -info > c:\...\info.log 2>&1" in the command line.

The "96" flags setting hides the system window that wants to pop up so you are probably seeing a permissions issue.

My acurcl is configured so that my login maps to my account (by the same name) on the server. So the program and the C$SYSTEM command are executed as me on the server.

Rather than running as "SYSTEM" you should map the user to a specific account by an access file entry and/or the DEFAULT_USER configuration.

Note that I'm running everything in Version 7.2.0 as Version 6 is scheduled for end-of-life later this year. You should consider upgrading, although I don't think that has anything to do with this issue.
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] C$SYSTEM "acurcl -info" windows server

It works for me using "c:\...\acurcl -info > c:\...\info.log 2>&1" in the command line.

The "96" flags setting hides the system window that wants to pop up so you are probably seeing a permissions issue.

My acurcl is configured so that my login maps to my account (by the same name) on the server. So the program and the C$SYSTEM command are executed as me on the server.

Rather than running as "SYSTEM" you should map the user to a specific account by an access file entry and/or the DEFAULT_USER configuration.

Note that I'm running everything in Version 7.2.0 as Version 6 is scheduled for end-of-life later this year. You should consider upgrading, although I don't think that has anything to do with this issue.



Yes I think we will be upgrading in the future, however for now I would like to get it working.

I can't see where I would map the account name in the acurcl application (using the gui) other than under the access tab where you set the local user name which I do have set up for a specific user.

Also under the config tab I have the DEFAULT_USER set to the same username. (and it is NOT SYSTEM).

However, when a user is connected via thin client I can see under the windows task manager I can clearly see that the wrun32.exe is run with the username SYSTEM...

I'm beginning to wonder if it is a 6.1.0 thing and I may need to upgrade sooner rather than later.

Any ideas of where else I need to map the username? What is your UMASK set to on your access entry?
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] C$SYSTEM "acurcl -info" windows server

It sounds like you have it configured correctly. I recall now that regardless of what mappings are in the Access file or what DEFAULT-USER is set to, the child runtimes are seen by the OS as the same account that owns the AcuConnect Service. In this case it is the Local System Account.

Try this:

In Windows Services stop the AcuConnect service, right-click on it and select Properties. On the 'Log On' tab under 'Local System Account' check the box 'Allow service to interact with desktop'. Restart AcuConnect.

If that doesn't resolve it then after upgrading (this doesn't work in 6.1) on the same 'Log On' tab select 'This account', select an account that is part of the administrators group and enter the password. Start AcuConnect and it will be running as that account with all child Runtimes invoked as that user too.
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.