[systemd-devel] soft-reboot and service templates

Luca Boccassi luca.boccassi at gmail.com
Wed Jun 5 13:58:27 UTC 2024


On Wed, 5 Jun 2024 at 14:45, Thorsten Kukuk <kukuk at suse.com> wrote:
>
> Hi,
>
> while playing with soft-reboot and services surviving this:
> A standard service file works, but if I use a service template (e.g.
> test at .service), the service get's stopped during soft-reboot.
> Reasons is:
> -Slice=system.slice
> +Slice=system-test.slice
>
> Is it somehow possible, that also "test at .service" stays alive during a
> soft-reboot?
> Or is there another way to pass variables to a service file at
> startup? I don't need to run the same service several times in
> parallel.
>
> Thanks,
>   Thorsten

Yeah we haven't tested this scenario at all - did you try adding a
drop-in for system-test.slice.d that sets the parameters to avoid
having it stopped on softreboot?


More information about the systemd-devel mailing list