Bug#940034: libelogind0: replacing a core system library and conflicting against the default init considered harmful

Mark Hindley mark at hindley.org.uk
Mon Sep 23 21:05:30 BST 2019

On Mon, Sep 23, 2019 at 03:34:50PM -0400, Sam Hartman wrote:
> Hi.
> I've looked a bit at the systemd code as compared to the elogind code.
> One of the major reasons that libsystemd0 cannot be used as a
> replacement for libelogind0 is that elogind does not have compatible
> cgroup naming.
> The systemd (and elogind) libraries  do some operations over dbus.
> But other operations are done directly.  For example to look and see
> what session a pid is in, the library will look at the cgroups of the
> pid.
> Similarly to see whether a particular pid belongs to a uid, it looks at
> the cgroup naming.
> If you take a look at src/basic/cgroup-util.c in the elogind sources and
> take a look at what is #if 0'd you can see the naming differences.

Yes. systemd uses user units and scopes. elogind can not support either and uses
internal hash containers.  So if a system is running elogind and polkit asks
libsystemd0 for a session id to a pid, it will search for a session-<pid>.scope
and find nothing.

See the two implementations of  cg_path_get_session():



More information about the Debian-init-diversity mailing list