Supervisor is a client/server system that allows users to monitor and control a number of processes on UNIX-like operating systems. The Python package installs the `supervisord` server, `supervisorctl` client, and utilities. It also enables programmatic interaction with `supervisord` via its XML-RPC interface. The current stable version is 4.3.0, with releases occurring a few times a year for maintenance and feature updates.
pip install supervisorVerified import paths — ran on the pinned version, not inferred.
This quickstart demonstrates how to connect to a running `supervisord` instance using the standard Python `xmlrpc.client` and retrieve process information. It requires `supervisord` to be configured with an XML-RPC interface (e.g., `inet_http_server` in `supervisord.conf`) and running. Environment variables are used for URL and credentials, falling back to localhost defaults.
Review the Supervisor 4.0.0 release notes and update client code to reflect the new XML-RPC API signatures and return types. Ensure Python 3.7+ is used as Python 2.6 support was dropped.
After installation, you must manually create a `supervisord.conf` file, then typically start `supervisord` via command line, or integrate it with a system's service manager (e.g., systemd, init.d) to run it as a persistent background daemon. Refer to the official Supervisor documentation for setup instructions.
Always ensure paths specified in `supervisord.conf` exist and are writable by the user `supervisord` runs as. Verify that the user running `supervisord` has appropriate permissions for managing child processes. Check `supervisord` logs (`supervisord -c /path/to/supervisord.conf -n`) for startup errors.
Ensure the Python environment where supervisor was installed is active (e.g., `source venv/bin/activate`), or add the directory containing the `supervisord` executable to your system's PATH.
Verify that `supervisord` is running. Check your `supervisord.conf` file, specifically the `[supervisord]` and `[supervisorctl]` sections, to ensure `file` (for unix socket) or `port` and `username`/`password` (for HTTP) settings match and are correct. Restart `supervisord` if necessary.
Check the `stdout_logfile` and `stderr_logfile` specified in the program's configuration for detailed error messages. Manually run the `command` from your configuration file in the same user context and directory as supervisor to debug the underlying issue.
Change the `file` path for `unix_http_server`, `inet_http_server` port, or `log` paths in `supervisord.conf` to a directory where the `supervisord` user has write permissions (e.g., `/tmp`, `/var/tmp`, or a user-specific directory). If binding to a privileged port, either use a port above 1024 or configure system-level port forwarding.
No dependency data recorded yet.