JANOS Help System: [Commands] [Topics] [Tech Support] [Printable Manual] [Search]
PS User Commands NAME ps - Process List SYNOPSIS ps [OPTIONS] DESCRIPTION Lists currently active processes along with the Process ID (PID). Processes are listing in order of decreasing demand on the CPU (%). This command also displays the current uptime. -V Provides additional process information. runtime - Total runtime accumulated % - percentage of CPU usage mem - Amount of memory in use (KB) msg - Number of inter-process messages pending (should be 0) hnd - Number of handles allocated stk - Maximum stack usage (percent) frm - Count of Stack frames (Applications) pram - available internal processor RAM -M [N] [LOGFILES] The PS command displays the process activity at a moment in time. As this activity can at times be very dynamic, two successive PS commands might display dramatically different results. Processes my be added. Others may terminate. Still others normally dormant might get busy. The -M option monitors the process status dynamically updating the display every couple of seconds. Any keystroke will exit from this mode. An optional log file such as jniorsys.log or list of log files may be provided. These files are monitored for newly appended lines which are then displayed as notifications. This offers a convenient means for correlating changes in process activity to logged events. The [N] option specifies an approximate number of log lines to display before rolling. N is 5 lines by default and is constrained to a number between 5 and 20. NOTES Developers want to insure that an application does not monopolize CPU resources. An application abnormally accumulating runtime may benefit from the use of process sleep() and yield() functions where appropriate. Stack usage above 50% should be watched carefully. Use of recursive routines in programs can drive stack usage up. A program will assert and stop should it use up the available stack space. Handles are required for various I/O activities and should be released if no longer required. These are a limited resource as well. Inter-process messaging is essential in creating functionality like custom protocols. The application program creates a message pump/queue in order to send and receive such messages. It is imperative that the queue be serviced promptly. A building msg count signals a messaging issue which certainly will impact system performance. The Idle Process should typically involve 90% or more of the CPU time. Other tasks may at times have work to do and require 100% of the CPU for certain possible extended periods of time. This is normal. The CPU however should return to the Idle state at some point. If this does not occur it may indicate that some process is not performing efficiently and may require modification. SEE ALSO HELP Topics: THD, KILL, STOP [/flash/manpages/manpages.hlp:4184]