NAME

dmctl - Daemon Manager control

SYNOPSIS

dmctl list|rescan
dmctl [<daemon-id>] status
dmctl <daemon-id> start|stop|restart
dmctl <daemon-id> log|tail

DESCRIPTION

dmctl allows the user to communicate and interact with the L<daemon-manager(1)> daemon. If no command is given, "status" is assumed.

COMMANDS

list

This command will list all the daemon ids that the user is allowed to control.

[<daemon-id>] status

This command will print a human readable list of the daemons-ids and their current stats. If the optional parameter <daemon-id> is specified then only the status for the daemon with that id will be shown.

The following pieces of data are shown per daemon:

daemon-id

The daemon id.

state

One of "stopped", "running", "stopping", "coolingdown".

The cooling down state happens when the daemon starts respawning too quickly. In order to prevent too much resource utilization, daemon-manager(1) will require the daemon to cool off for some period of time before respawning it.

pid

The process id of the running daemon, or zero if it is not running.

respawns

The number of times the daemon has been respawned by daemon-manager(1) due to it quitting unexpectadly.

cooldown

The number of seconds left in the cooldown period.

uptime

The number of seconds the daemon has been running for since the last respawn.

total

The total number of seconds the daemon has been running for since the last start.

rescan

Upon receiving this command, daemon-manager(1) will look through the user’s home directory (and the home directories of the other users managed by the user) for new daemon config files. Any new files will be loaded (and started if their autostart option is set).

It is not necessary to issue the rescan command if a config file has been edited or deleted. start and stop will catch those 2 cases respectively.

<daemon-id> start

This will start the daemon identified by <daemon-id> if it hasn’t already been started.

If the daemon is cooling down then start will attempt to start it immediately. This is useful if you are debugging a daemon that is not launching properly and don’t want to wait for the cooldown period.

<daemon-id> stop

This will stop the daemon identified by <daemon-id> if it isn’t already stopped.

<daemon-id> restart

Currently this is just a short hand for a stop command followed by a start command.

<daemon-id> log

This lets you view the daemon identified by <daemon-id>'s log file. If the PAGER environment variable is set, then it will be used to view the file. Otherwise less will be used and if it is not found then more will be used and, failing that, cat.

If this command is part of a pipeline, then cat will always be used.

<daemon-id> tail

This runs "tail -f" on the log file of the daemon identified by <daemon-id>.

SEE ALSO

daemon-manager(1), daemon.conf(5)

Last Modified on: Oct 15, 2015 19:35pm