[systemd-devel] generators and service symlink

Frederic Crozat fcrozat at suse.com
Wed Aug 24 05:30:22 PDT 2011


Le mercredi 24 août 2011 à 14:12 +0200, Lennart Poettering a écrit :
> On Wed, 24.08.11 13:42, Frederic Crozat (fcrozat at suse.com) wrote:

> > It didn't work as expected due to a bug in
> > path-lookup.c:lookup_paths_init which remove from the lookup path lists
> > empty directories : therefore /run/systemd/system was evicted from the
> > directory list to monitor and wasn't used at all.
> 
> Hmm, are you suggesting lookup_paths_init() is called before the
> generators? That would be wrong. We should definitely strip empty
> directories, but of course taking into account everything the generators
> might have generated.

Yes, it is :
lookup_paths_init is called in manager_new and generators are called
later, in manager_startup.

If we make sure lookup_paths_init is called last, we could remove from
manager_run_generators the need to add "/run/systemd/generator" to
lookup_paths : instead, we always "put it" in the list and it will
evicted if empty by lookup_paths_init

-- 
Frederic Crozat <fcrozat at suse.com>
SUSE



More information about the systemd-devel mailing list