Running supervisorctl

To start supervisorctl, run $BINDIR/supervisorctl. Ashell will be presented that will allow you to control the processesthat are currently managed by supervisord. Type “help” atthe prompt to get information about the supported commands.

The supervisorctl executable may be invoked with “one time”commands when invoked with arguments from a command line. An example:supervisorctlstopall. If arguments are present on thecommand-line, it will prevent the interactive shell from beinginvoked. Instead, the command will be executed and supervisorctlwill exit with a code of 0 for success or running and non-zero forerror. An example: supervisorctlstatusall would return non-zeroif any single process was not running.

If supervisorctl is invoked in interactive mode against asupervisord that requires authentication, you will be askedfor authentication credentials.

supervisorctl Command-Line Options

-c, —configuration
Configuration file path (default /etc/supervisord.conf)
-h, —helpPrint usage message and exit
-i, —interactive
Start an interactive shell after executing commands
-s, —serverurl URL
URL on which supervisord server is listening (default “http://localhost:9001”).
-u, —usernameUsername to use for authentication with server
-p, —passwordPassword to use for authentication with server
-r, —history-file
Keep a readline history (if readline is available)

action [arguments]

Actions are commands like “tail” or “stop”. If -i is specified or no action isspecified on the command line, a “shell” interpreting actions typedinteractively is started. Use the action “help” to find out about availableactions.

supervisorctl Actions

help

Print a list of available actions

help <action>

Print help for <action>

add <name> […]

Activates any updates in config for process/group

remove <name> […]

Removes process/group from active config

update

Reload config and add/remove as necessary, and will restart affected programs

update all

Reload config and add/remove as necessary, and will restart affected programs

update <gname> […]

Update specific groups, and will restart affected programs

clear <name>

Clear a process’ log files.

clear <name> <name>

Clear multiple process’ log files

clear all

Clear all process’ log files

fg <process>

Connect to a process in foreground modePress Ctrl+C to exit foreground

pid

Get the PID of supervisord.

pid <name>

Get the PID of a single child process by name.

pid all

Get the PID of every child process, one per line.

reload

Restarts the remote supervisord

reread

Reload the daemon’s configuration files, without add/remove (no restarts)

restart <name>

Restart a processNote: restart does not reread config files. For that, see reread and update.

restart <gname>:*

Restart all processes in a groupNote: restart does not reread config files. For that, see reread and update.

restart <name> <name>

Restart multiple processes or groupsNote: restart does not reread config files. For that, see reread and update.

restart all

Restart all processesNote: restart does not reread config files. For that, see reread and update.

signal

No help on signal

start <name>

Start a process

start <gname>:*

Start all processes in a group

start <name> <name>

Start multiple processes or groups

start all

Start all processes

status

Get all process status info.

status <name>

Get status on a single process by name.

status <name> <name>

Get status on multiple named processes.

stop <name>

Stop a process

stop <gname>:*

Stop all processes in a group

stop <name> <name>

Stop multiple processes or groups

stop all

Stop all processes

tail [-f] <name> [stdout|stderr] (default stdout)

Output the last part of process logsEx:tail -f <name> Continuous tail of named process stdout Ctrl-C to exit.tail -100 <name> last 100 bytes of process stdouttail <name> stderr last 1600 bytes of process stderr