Re: PAMName=login, systemctl stop

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

 



On Fr, 30.06.23 15:11, Valentijn Sessink (valentijn@xxxxxxxxxx) wrote:

> Hi,
>
> On 28-06-2023 18:04, Lennart Poettering wrote:
> > > "PAMName=login", then starts a script and a few (old X11 related) programs.
> [...]>> 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.
>
> I have tried to get my head around this but I couldn't find how to proceed,
> i.e. how to kill of the session.
>
> I can get the CGroup and session scope with "systemctl status <mainpid>";
> but I still can't figure out what to stop then. So how can I finish this
> "spawned off" session - the one that started from a "PAMName=login" option
> in the service file?

I am not sure I grok your question. But we do not provide a way
currently to associate session scope units with the service units they
have been created by. There's no nice way to go from one to ther
other.

You can terminate service units via "systemctl stop", and you can
terminate session scope units the same way, but there's no mechanism
to relate one to the other. And I am not sure that's even
unconditionally desirable, because typically scopes and the services
they are spawned from might have different lifecycles, i.e. the
sessions are fine with surviving if the invoking service dies.

Lennart

--
Lennart Poettering, Berlin



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

  Powered by Linux