On Wed, May 20, 2015 at 2:00 PM, Olaf Hering <olaf@aepfle.de> wrote:
On Wed, May 20, Andrei Borzenkov wrote:
I suspect that xenstored_ro.socket wants to be after /proc/xen which is by default after basic.target; but by default sockets are ordered before sockets.target which is before basic.target.
How do I get ordering info about basic.target and sockets.target?
In systemd documentaition? http://www.freedesktop.org/software/systemd/man/systemd.special.html basic.target A special target unit covering basic boot-up. systemd automatically adds dependencies of the types Requires= and After= for this target unit to all services (except for those with DefaultDependencies=no). Usually this should pull-in all mount points, swap devices, sockets, timers, and path units and other basic initialization necessary for general purpose daemons.
Xen related output adjusted to the expected order:
root@optiplex:~ # grep -Ei '^(\[|Want|Before|After|Req)' /usr/lib/systemd/system/*xen*.{service,mount,socket}
/usr/lib/systemd/system/xen-dom0-modules.service:[Unit] /usr/lib/systemd/system/xen-dom0-modules.service:Before=proc-xen.mount
This orders /proc/xen after xen-dom0-modules.service. Be default every service unit is ordered after basic target: http://www.freedesktop.org/software/systemd/man/systemd.service.html Unless DefaultDependencies= is set to false, service units will implicitly have dependencies of type Requires= and After= on basic.target as well as dependencies of type Conflicts= and Before= on shutdown.target. These ensure that normal service units pull in basic system initialization, and are terminated cleanly prior to system shutdown. Only services involved with early boot or late system shutdown should disable this option.
/usr/lib/systemd/system/xenstored_ro.socket:[Unit] /usr/lib/systemd/system/xenstored_ro.socket:Requires=proc-xen.mount var-lib-xenstored.mount /usr/lib/systemd/system/xenstored_ro.socket:After=proc-xen.mount var-lib-xenstored.mount /usr/lib/systemd/system/xenstored_ro.socket:[Socket] /usr/lib/systemd/system/xenstored_ro.socket:[Install] /usr/lib/systemd/system/xenstored_ro.socket:WantedBy=sockets.target
This makes xenstored_ro.socket ordered before sockets.target. Unless DefaultDependencies= is set to false, target units will implicitly complement all configured dependencies of type Wants=, Requires=, RequiresOverridable= with dependencies of type After= if the units in question also have DefaultDependencies=true. and sockets.target comes before basic.target. Just look at http://man7.org/linux/man-pages/man7/bootup.7.html. -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org