Re: PAMName=login, systemctl stop

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Do, 22.06.23 16:22, Valentijn Sessink (valentijn@xxxxxxxxxx) wrote:

> Hello list,
>
> I have a rather simple service file that sets up a user session with
> "PAMName=login", then starts a script and a few (old X11 related) programs.
> Starting it is easy, but stopping the service will send SIGTERM only to the
> main process, because "Any child processes of that process will however be
> associated with the session scope unit only" - as per man systemd.exec(5).
>
> Is there a way to amend the service file to stop these children?

Not really, from systemd's PoV they are part of the login session, not
the original service anymore.

You can't have it both ways: be a session and a service. In system
it's either/or.

Lennart

--
Lennart Poettering, Berlin



[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux