[systemd-devel] Support for pre-restart check

Michal Sekletar msekleta at redhat.com
Wed Jul 30 04:45:10 PDT 2014

On Wed, Jul 30, 2014 at 11:26:38AM +0000, "Jóhann B. Guðmundsson" wrote:
> On 07/30/2014 10:22 AM, Ansgar Burchardt wrote:
> >Hi,
> >
> >while looking at how to convert sysvinit scripts to service files in
> >Debian, I noticed that some scripts do an additional sanity check during
> >the restart action. That is, they run an extra command to validate the
> >configuration and only restart the service on success.
> >
> >Systemd doesn't seem to provide such an option so far. Would you think
> >this is something one would like to see? If yes, what about the
> >following idea:
> >
> >Add an ExecRestartPre option in the [Service] section. These commands
> >are executed when a restart is requested, before the service is stopped.
> >If they fail, the restart is aborted with an error.
> >
> Re-sending to list due to simple clicking reply not reply-list mistake.
> This has been discussed before and check the archive for that
> discussion but the bottom line is that this is not needed we already
> have ExecStartPre=, ExecStartPost=, ExecStop=, ExecStopPost=, or
> ExecReload= which cover those usecases

If that is the case, we should really delete TODO item:

* maybe introduce ExecRestartPre

> _______________________________________________
> systemd-devel mailing list
> systemd-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/systemd-devel

More information about the systemd-devel mailing list