Bug#989317: systemd kill background processes after user logs out (#825394 regression)
Matt Corallo
dbsdsfdog at mattcorallo.com
Tue Jun 8 17:08:26 BST 2021
Hmmm, with set-linger and --scope I can't seem to reproduce now either, its possible I had forgotten the --scope at some
point while testing set-linger before, sorry for the noise here.
Still, based on my read of #825394, it seems like it should be the case that you do not need set-linger and the default
behavior should be that things aren't automatically killed in the background? Is that something that was an intentional
change?
The systemd-run manpage seems to indicate that with debian's default change of KillUserProcesses=no this should not
occur with or without linger. In either case, it seems the manpage should be updated to describe this behavior, and
maybe updated to mention that KilUserProcesses is *not* the default on Debian, which it states in the EXAMPLES section.
Thanks,
Matt
On 6/8/21 10:19, Michael Biebl wrote:
> Control: tags -1 + unreproducible
>
> So, I've been following the instructions in /usr/share/doc/lxc/README.Debian to allow unprivileged containers.
>
> After that, I could successfully run a container. I used the command line as suggested in that README.Debian:
>
> $ systemd-run --scope --quiet --user --property=Delegate=yes \
> lxc-start -n mycontainer
>
>
> Once I logged out, the systemd --user session was stopped including the container, which is expected, as ansgar wrote.
>
> After enabling "linger" for that user, the systemd --user session was not stopped anymore after logging out and the
> container continued running.
>
> I'm thus marking this bug report as unreproducible.
>
> (note that the lxc maintainers recommend to use --scope with systemd-run)
>
> Michael
>
More information about the Pkg-systemd-maintainers
mailing list