Two more issues: After installing the updated systemd-initctl.{service,socket}, they need to be restarted in postinst. systemctl try-restart for the service and restart for the socket is most likely what we want here.
On 01.02.2012 17:57, Roger Leigh wrote: > On Wed, Feb 01, 2012 at 05:42:28PM +0100, Michael Biebl wrote: >> If we provide a /dev/initctl → /run/initctl symlink, we don't need that >> Breaks afaics and I think we should add such a a symlink anyway for >> backwards compatibility. >> I'd guess there is more code out there hardcoding the location of the >> initctl socket (I could do an archive wide grep for "/dev/initctl" fwiw). > > They shouldn't, and I wouldn't worry too much about this possibility. > The protocol is private and undocumented, so there should be no > third-party users. The location is hard-coded directly into the > binaries and is likely only intended to be used by sysvinit binaries. > systemd is an exception to this rule, and I would suspect the only > one. If we don't provide backwards compatibility via a /dev/initctl symlink in systemd, sytemd needs a versioned breaks against sysvinit. On the other hand sysvinit needs to declare a versioned breaks against systemd. This means we have a kind of circular dep and the order in which the packages are updated is not deterministic. As the order of in which the postinst of sysvinit and systemd are run is not deterministic either, they need to work in both cases. But I *think* it should work. If systemd.postinst is run first (and the try-restart has been added), /run/initctl should exist and sysvinit.postinst does nothing. If sysvinit.postint is run first, it will shuffle the initctl socket around but systemd-initctl.socket will still listen on /dev/initctl. That means the "init u" call in sysvinit.postinst will not work and we try it for 7 times before we give up. Later then systemd.postinst is run, which will restart the socket, so we have a working /run/initctl, and in case the systemd-initctl service was running, we restart it, too. Michael -- Why is it that all of the instruments seeking intelligent life in the universe are pointed away from Earth?
signature.asc
Description: OpenPGP digital signature