[systemd-devel] Fwd: Stopping a service at a specific time or after a specific duration

Jamie Kitson jamie at kitten-x.com
Thu Apr 21 08:51:11 UTC 2016


> >>>
> >>>   For stopping after a duration you can use RuntimeMaxSec=, introduced in
> >>>   v229.
> >>
> >>
> >> Thanks. The man page says:
> >>
> >>> If this is used and the service has been active for longer than the
> >>> specified
> >>> time it is terminated and put into a failure state
> >
> >
> > and i call that a design bug - why does it go into failure state?
> >
> 
> If you interpret RunTimeMax as "safety measure against run away
> process" it sounds logical. In this case if service had to be killed
> something went wrong indeed.

In my case I want to gracefully stop the service after a certain amount
of time, that's why I asked about the signal sent and any adverse
effects of the failed state.


More information about the systemd-devel mailing list