Process and System Utilities for Python
open sourceBSD-3-Clausefree
psutil is a cross-platform Python library for reading information about running processes and system utilization: CPU, memory, disks, network and sensors. It is used for system monitoring, profiling, limiting process resources and managing running processes, and implements in Python much of what Unix tools such as ps, top, free, iotop, netstat, ifconfig and lsof show. It runs on Linux, Windows, macOS, FreeBSD, OpenBSD, NetBSD, Sun Solaris and AIX, and is BSD-3-Clause licensed.
Problems it solves
- get CPU and memory usage of my machine from a Python script
- find which process is using a port or a file from Python
- monitor a running process memory and kill it if it grows too much
Features
- CPU, memory, disk, network and sensor usage
- list, inspect and manage running processes
- per-process resource limits, open files and connections
- Python equivalents of ps, top, free, iotop, netstat, ifconfig and lsof
- runs on Linux, Windows, macOS, the BSDs, Sun Solaris and AIX
