hi. we are having problems with hung processes on a production box onto which
i cannot install any 3rd paty software (e.g. sysinternals). the hung process
will be one of many scheduled tasks all executing as svchost. i would like to
find out which of these tasks is hanging without stopping the task scheduler
or doing anything which might impact our users.
is there any way, via managed code, to get detailed information about a
process. for example it would be useful to know the command line used to
start the process, any files locked by the process, etc. i can get loaded
modules no problem, but this is not particularly helpful in this instance.
thanks
kevin
lgs.lgs - 16 May 2006 12:11 GMT
> i cannot install any 3rd paty software (e.g. sysinternals)
From a command line, run WbemTest.
Click Connect
In the first box, type root\cimv2
Click Connect
Click Enum Instances
Type win32_process
Click ok.
Double click on the processid in question.
Click Show Mof.
This shows a variety of info about the process including command line,
creation time, etc.
Instead of clicking Show Mof, you can also click "Associators". This will
show the userid of the process and the dlls the process uses. It will NOT
show locks of any sort.
Kevin Hector - 16 May 2006 12:25 GMT
thats great. thanks.
> > i cannot install any 3rd paty software (e.g. sysinternals)
>
[quoted text clipped - 14 lines]
> show the userid of the process and the dlls the process uses. It will NOT
> show locks of any sort.