On Thu, 22.07.10 18:48, Miloslav Trmač (mitr@xxxxxxxx) wrote: > Lennart Poettering píše v Čt 22. 07. 2010 v 18:35 +0200: > > If a service A uses functionality provided by a service B which in turn > > uses functionality provided by A then things willbreak regardless > > whether systemd is used or not. > > > > Cyclic dependencies cause deadlocks. Introducing systemd has little > > effect on that. It won't make the situation worse, and it won't make > > itmuch better either. > <snip> > > > Or in even other words: this is a theoretical problem, not a practical > > one, and orthogonal to the problem set systemd tries to solve. > Not at all. If, there is a circular dependency between, say, syslogd > and dbus, with the old system: > - syslogd attempts to use dbus, which fails > - syslogd can detect the situation > - syslogd can choose to ignore it (or retry later) and complete startup > - dbus starts > - dbus uses syslog to say it has started successfully > - system boots normally > - [syslogd optionally reconnects to dbus] > > I don't know whether this currently happens with Fedora, but it is not > at all irrelevant and systemd could indeed make the situation much > worse. Nope, what you suggest will deadlock sooner or later: let's say syslog connects to dbus eventually. Doing that means it has to block (the authentication dbus does is already blocking) on some dbus request. Now, if dbus logs to syslog while processing that request it might block writing to /dev/log. And there you have it. A deadlock. Really, cyclic dependencies cause deadlocks. There's nothing new about that. This problem is completely theoretical. As is shown by MacOS which employs this technique and according to their engineers starts over 160 daemons like this. Lennart -- Lennart Poettering - Red Hat, Inc. -- devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxxx https://admin.fedoraproject.org/mailman/listinfo/devel