|The stupid question is the question not asked|
Proc::ProcessTableby rob_au (Abbot)
|on Nov 02, 2001 at 17:41 UTC||Need Help??|
Item Description: Framework for obtaining and extracting information on process execution
Why use Proc::ProcessTable?
This module implements platform-independent methods for obtaining information on process execution on a system from the /proc file system by filling a procstat structure for the /proc/XXX/stat file relating to a process. This process execution information includes real and effective group and user IDs, parent and group process IDs, process priorities, CPU and memory utilisation and process TTYs. The supported process attributes available via this module vary from platform to platform as a result of the changes in platform procstat structs - Supported attributes for each platform are described in the README file for each platform.
The delivery of this process information by Process::ProcessTable allows you to do away with the ugly external shell calls to utilities such as ps.
How to use Proc::ProcessTable?
The documentation for the Proc::ProcessTable module is excellent and usage of this module is very simple with only three methods exported by default - new (create new ProcessTable object), fields (returns a list of the field names/attributes supported by the module on the current architecture) and table (reads the process table and returns an array of process information).