SERVICE(8)

NAME
service - Start or stop an operating system server or device driver.

SYNOPSIS

service up <service> [-args args] [-dev special] [-period ticks]

service down <pid>

service refresh <pid>

service shutdown

DESCRIPTION

Tells the reincarnation server to start or stop a system service, such as a server or device driver. The device driver will be automatically restarted when it unexpectedly exits, e.g., if it is killed because of a bad pointer. Starting requires an absolute path to the binary to be executed.

When an optional period is specified, the reincarnation server sends a status request to the system service after every period. If there the response does not arrive in time, the reincarnation server will kill the misbehaving process and restart a new one. The period must be specified in ticks, but can be appended with HZ to make it seconds.

Stopping a system service requires the process id of a running system service. Issuing a kill command from the shell will not work, since the reincarnation server interprets this as an unexpected exit and will automatically restart a fresh copy of the process. The clean way to restart a process is using the refresh option of the service utility.

If the system is to be shutdown, the reincarnation server should know about this event to prevent it from restarting services that are killed during the shutdown sequence.

EXAMPLES

SEE ALSO

boot(8), monitor(8)