LinuxCommandLibrary
GitHubF-DroidGoogle Play Store

runsv

Supervise a single runit service process

TLDR

Supervise a service
$ runsv [/etc/service/myservice]
copy
Check service status
$ sv status [myservice]
copy
Send signal
$ sv signal [myservice]
copy

SYNOPSIS

runsv servicedir

DESCRIPTION

runsv supervises a single service. It runs and monitors the service defined in the directory.The run script is executed and monitored. If it exits, runsv restarts it.Optional finish script runs after service exits. Cleanup operations go here.Optional log directory runs a logging service. Captures stdout/stderr.Control interface via supervise directory. The sv command communicates here.

SERVICE DIRECTORY

run - Executable service script (required)finish - Cleanup script (optional)log/run - Logger service (optional)supervise/ - Created by runsv for control

CONTROL COMMANDS

Written to service/supervise/control (typically via sv):u - Up; start service and restart if it stopsd - Down; send TERM+CONT and don't restarto - Once; start but don't restart on exitp - Pause (SIGSTOP)c - Continue (SIGCONT)h - Hangup (SIGHUP)a - Alarm (SIGALRM)i - Interrupt (SIGINT)q - Quit (SIGQUIT)1 - SIGUSR12 - SIGUSR2t - Terminate (SIGTERM)k - Kill (SIGKILL)x - Exit runsv and close log pipes

INSTALL

sudo apt install runit
copy
sudo apk add runit
copy
brew install runit
copy
nix profile install nixpkgs#runit
copy

CAVEATS

Usually run by runsvdir, not directly. Service directory must have correct permissions and an executable run script. A down file in the service directory prevents automatic startup. Exits with status 111 on startup errors or if another runsv is already supervising the same directory.

HISTORY

runsv is part of runit by Gerrit Pape. It provides the core supervision functionality for individual services.

SEE ALSO

runit(8), sv(8), runsvdir(8), svlogd(8), chpst(8)

Braincup
Open source brain training for math, memory and focus
Braincup mini-games
41 mini-games · Apache-2.0
No ads · No tracking
Play in browser
Download Braincup on the App StoreGet Braincup on Google PlayGet Braincup on F-Droid
276 stars
From the maker of Linux Command Library
Copied to clipboard
Braincup
Open source brain training for math, memory and focus. 41 mini-games, from mental arithmetic to Sudoku, N-Back and Solo Chess.
Apache-2.0 licensed · No ads · No tracking · No account
From the maker of Linux Command Library
Download Braincup on the App StoreGet Braincup on Google PlayGet Braincup on F-Droid