diff options
author | William Hubbs <w.d.hubbs@gmail.com> | 2017-05-09 18:20:52 -0500 |
---|---|---|
committer | William Hubbs <w.d.hubbs@gmail.com> | 2017-05-09 18:30:08 -0500 |
commit | 3673040722b75c0a4d06fbeb272f917c7d1ea7c4 (patch) | |
tree | 1329fd5b6e8354c41d56c239f1f7d1127fc0dc28 /man/supervise-daemon.8 | |
parent | 96c8ba2fb5f91a711ef5bfcfd8affe0b74ad18fe (diff) |
supervise-daemon: add a --respawn-limit option
Allow limiting the number of times supervise-daemon will attempt to respawn a
daemon once it has died to prevent infinite respawning. Also, set a
reasonable default limit (10 times in a 5 second period).
This is for issue #126.
Diffstat (limited to 'man/supervise-daemon.8')
-rw-r--r-- | man/supervise-daemon.8 | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/man/supervise-daemon.8 b/man/supervise-daemon.8 index 06087675..43e74ef7 100644 --- a/man/supervise-daemon.8 +++ b/man/supervise-daemon.8 @@ -34,6 +34,8 @@ .Ar user .Fl r , -chroot .Ar chrootpath +.Fl R , -respawn-limit +.Ar limit .Fl 1 , -stdout .Ar logfile .Fl 2 , -stderr @@ -99,6 +101,24 @@ Modifies the scheduling priority of the daemon. .It Fl r , -chroot Ar path chroot to this directory before starting the daemon. All other paths, such as the path to the daemon, chdir and pidfile, should be relative to the chroot. +.It Fl R , -respawn-limit Ar limit +Control how agressively +.Nm +will try to respawn a daemon when it fails to start. The limit argument +can be a pair of integers separated bya colon or the string unlimited. +.Pp +If a pair of integers is given, the first is a maximum number of respawn +attempts and the second is a time period. It should be interpreted as: +If the daemon dies and has to be respawned more than <first number> +times in any time period of <second number> seconds, exit and give up. +.Pp +For example, the default is 10:5. +This means if the supervisor respawns a daemon more than ten times +in any 5 second period, it gives up and exits. +.Pp +if unlimited is given as the limit, it means that the supervisor will +not exit or give up, no matter how many times the daemon it is +supervising needs to be respawned. .It Fl u , -user Ar user Start the daemon as the specified user. .It Fl 1 , -stdout Ar logfile |