Re: Scheduled task doesn't get correct processlist under remote connec



Scheduled tasks run in session 0 under local SYSTEM account.
What API do you use to enumerate the processes?
NtQuerySystemInformation() should give you all processes running in all the
sessions on the server. But it can be run only locally.
WTSEnumerateProcesses() may give you the partial information depending on
the access rights of the account your client prosess uses.

--
This posting is provided "AS IS" with no warranties, and confers no rights.


"graciezzzzz" <graciezzzzz@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:7170B7DF-1DD0-43C4-9D03-1D69DE0571DA@xxxxxxxxxxxxxxxx
Hi all experts,

I'm experencing an issue. I created a .exe file to get the process list
running on our remote server. All the processes I need to monitor is
running
under the remote desktop connection session.

If I run the .exe manually then it works fine; but if I create a scheduled
task on server to run the .exe, the scheduled task doesn't get any process
except one as below:

C:\WINDOWS\SYSTEM32\SVCHOST.EXE

The scheduled task starts/runs/stops with no error. It seems the .exe runs
on another session so it cannot get the processes on the remote
connection.

Is there any suggetions how to fix it?

Many thanks in advance.



.



Relevant Pages

  • Re: scheduled task never run on RDP?
    ... You can monitor a scheduled task via a console or RDP ... > the same account as the account that is used for the scheduled ... > Whether your current session is a console or an RDP session is ...
    (microsoft.public.win2000.general)
  • Re: Getting services to see subst drives
    ... it up for the service's session. ... which is created using subst. ... scheduled task, logon time scheduled task, and setting the service to run ... as my user account & trying an HKCU Run task, but none of that seems to ...
    (microsoft.public.windowsxp.security_admin)
  • Re: Application caching
    ... I would expect such a behavior for every user session, ... We have set up Server 2008 with Terminal Server for about 10 users. ... All those users use the same application (a single exe from a network ...
    (microsoft.public.windows.terminal_services)
  • Re: How to allow a specific number of Instances of my app?
    ... copy of the EXE, rename it or put it into a different folder and run the EXE ... make a mutex that is not dependant on the file name. ... another terminal server session, or a second session in XP fast user ...
    (microsoft.public.vb.general.discussion)
  • Creating Scheduled Task
    ... I created a scheduled task to run an exe from a network share,that has a ... Then I change my profile and login as another user. ... The task is carried out on schedule and the exe is loaded and can be seen in ... But the problem is that the GUI is not displayed. ...
    (microsoft.public.security)