home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 11 Util
/
11-Util.zip
/
OS2RUN.ZIP
/
RUNNING.DOC
next >
Wrap
Text File
|
1989-10-22
|
4KB
|
76 lines
RUNNING: Shows Processes Running in OS/2
----------------------------------------
This program is released to the public domain and may be distributed
freely by any means.
RUNNING is a simple program which provides a listing of all processes
currently being used by OS/2. It provides information about the
processes such as their PID, their PARENT PID, the internal module ID
#, the number of children processes, the number of threads currently
running in each process, and dependency links to resources.
Resources are DLL's or font files.
Here is a sample of a listing of processes (not resources):
PID PPID Mod# Process Name Thds Chld Resource Module #s
---- ---- ---- -------------------- ---- ---- -------------------------
000e 0005 0332 CLOCK2 1 0 0084 0151 0152 0156
0011 0005 028b CMD 1 1 0072 0084 007b 008f 0085
0046 007c
000c 0005 0380 FREEMEM 1 0 0084 0151 0152
0006 0005 01f4 HARDERR 3 0 0084 007b 0058 008f 0085
0072 007c
000a 0005 0273 PMEXEC 1 0 0156 0084 0151 0152 0155
0159
0005 0000 016a PMSHELL 12 8 0151 0152 0155 0156 0159
0084
The PID is the process ID which might be used by a program such as
KILL (Copyright (c) 1988, Ed Braaten and available on many BBSs) to
totally remove a process from the system. The PPID is the parent
process' PID and the module # is a number used internally to identify
the process. The process name is the NAME or LIBRARY name from the
DEF file when the process is linked. The number of threads and
number of children are followed by the module numbers of all of the
resources currently in use by the process. Here is a sample of the
resource listing:
PID PPID Mod# Process Name Thds Chld Resource Module #s
---- ---- ---- -------------------- ---- ---- -------------------------
*Resource* 02a0 COURIER
*Resource* 0114 DISPLAY 007c 0084 0085 0151 013b
*Resource* 0084 DOSCALL1 0000 007b 0085 007c
*Resource* 00c0 DOSCALLS
*Resource* 02b6 HELV
*Resource* 0406 IBMNULL 013b 0084 0151 0156 02e0
*Resource* 007b KBDCALLS 0084
*Resource* 0178 MONCALLS 0084
*Resource* 0058 MOUCALLS 0084 007c
*Resource* 0152 PMGPI 0084 0085 013b 012b 0151
*Resource* 0156 PMSHAPI 0084 0085 0155 0151
*Resource* 0151 PMWIN 0114 0084 0085 0152 013b
0155 0156
We can see that CLOCK2 above uses DOSCALL1, PMWIN, PMGPI, and PMSHAPI as
its resources.
This program uses the undocumented function DosQProcStatus() which is
used by the programs PSTAT.EXE and PS.EXE which are provided with
OS/2. This function was brought to my attention by Franz Krainer in
a message in the OS2 echo (10-19-89), and helped fulfil a need that I
have had for a long time (since I moved over to OS/2 from QNX) to
know what exactly is running in my system at any moment. The
function works with OS/2 1.1 and should also work with version 1.2.
If you have questions or comments, you can send them to me Netmail at
my BBS, The Programmer's Oasis (1:151/402). You can also call the
BBS at (919) 226-6984 (North Carolina). Finally, you can Email me
through Compuserve (ID 76120,110).