[systemd-devel] Is restart gracefull?

Cecil Westerhof Cecil.Westerhof at Snow.nl
Fri Nov 29 04:20:44 PST 2013


On 11/29/2013 01:12 PM, Jan Alexander Steffens wrote:
> On Fri, Nov 29, 2013 at 12:52 PM, Cecil Westerhof
> <Cecil.Westerhof at snow.nl> wrote:
>>> Just to clarify, "stop" (and, by extension "restart") is also up to
>>> the implementer of the unit file. There just happens to be a default,
>>> unlike with "reload." See the service and exec man pages for details.
>>> Regardless, "restart" and "stop" usually both involve a full shutdown
>>> of every process running the daemon. I think it's possible to override
>>> this behavior with certain options, but you shouldn't.
>>
>>
>> There is of-course an important difference. As I understood it, Apache is
>> notorious for processes that escape. (That is one of the reasons that
>> cgroups usage of systemd is such an improvement.) In the old situation
>> nothing happened to those processes. (With potential nasty results.) What
>> happens to those processes under systemd?
>
> Unless otherwise configured, as soon as the ExecStop command is
> finished, systemd terminates all remaining processes. After a grace
> period, the processes are killed.
>
> If there's no ExecStop command defined, termination begins
> immediately. For many services this is simple and appropriate
> behavior.
Clear. Thanks.

By the way: is thanks appreciated or frowned upon?


More information about the systemd-devel mailing list