[systemd-devel] Jobs dropped to readily (predm/start dropped as a dep while deleting plymouth-quit/stop)

Colin Guthrie gmane at colin.guthr.ie
Sun Apr 8 17:56:56 PDT 2012


'Twas brillig, and Colin Guthrie at 09/04/12 00:29 did gyre and gimble:
> Here we can see why prefdm doesn't get started. It was dropped as a dep
> to break an ordering cycle. However, it's actually part of the cycle
> itself, and thus it likely should be excluded from the dependant jobs
> when they are deleted.
> 
> i.e. a job may be a dependency of the job being dropped, but it might
> also exist in it's own right as a dep elsewhere. In such circumstances,
> shouldn't it be allowed to continue?
> 
> Or perhaps dependant jobs should not be cleared in the first loop. i.e.
> try continuing without deleting dependant jobs, but keep a list of those
> that would be deleted. If the first loop did not solve the problem, then
> delete the deps.
> 
> Or perhaps when deleting a stop job, we should not delete any dependant
> start jobs? Or even somehow process conflicts first before verifying the
> order? To explain some of the rules here are:

Just as a random though, I tried simply not deleting any dependant jobs
as per the attached patch.

This resulted in the following results:

Before:
[    4.165800] systemd[1]: Activating default unit: default.target
[    4.165825] systemd[1]: Trying to enqueue job
graphical.target/start/replace
[    4.166048] systemd[1]: Found ordering cycle on basic.target/start
[    4.166048] systemd[1]: Walked on cycle path to sockets.target/start
[    4.166048] systemd[1]: Walked on cycle path to syslog.socket/start
[    4.166048] systemd[1]: Walked on cycle path to basic.target/start
[    4.166165] systemd[1]: Breaking ordering cycle by deleting job
syslog.socket/start
[    4.166165] systemd[1]: Found ordering cycle on prefdm.service/start
[    4.166165] systemd[1]: Walked on cycle path to
plymouth-quit.service/stop
[    4.166165] systemd[1]: Walked on cycle path to rc-local.service/start
[    4.166165] systemd[1]: Walked on cycle path to rinetd.service/start
[    4.166165] systemd[1]: Walked on cycle path to atieventsd.service/start
[    4.166165] systemd[1]: Walked on cycle path to prefdm.service/start
[    4.166165] systemd[1]: Breaking ordering cycle by deleting job
plymouth-quit.service/stop
[    4.166165] systemd[1]: Deleting job prefdm.service/start as
dependency of job plymouth-quit.service/stop
[    4.166165] systemd[1]: Found ordering cycle on prefdm.service/stop
[    4.166171] systemd[1]: Walked on cycle path to getty at tty1.service/start
[    4.166179] systemd[1]: Walked on cycle path to
plymouth-quit-wait.service/start
[    4.166195] systemd[1]: Walked on cycle path to rc-local.service/start
[    4.166198] systemd[1]: Walked on cycle path to rinetd.service/start
[    4.166201] systemd[1]: Walked on cycle path to atieventsd.service/start
[    4.166204] systemd[1]: Walked on cycle path to prefdm.service/stop
[    4.166207] systemd[1]: Breaking ordering cycle by deleting job
getty at tty1.service/start
[    4.166311] systemd[1]: Installed new job graphical.target/start as 1


After:
[    4.396671] systemd[1]: Activating default unit: default.target
[    4.396697] systemd[1]: Trying to enqueue job
graphical.target/start/replace
[    4.397007] systemd[1]: Found ordering cycle on basic.target/start
[    4.397011] systemd[1]: Walked on cycle path to sockets.target/start
[    4.397014] systemd[1]: Walked on cycle path to syslog.socket/start
[    4.397017] systemd[1]: Walked on cycle path to basic.target/start
[    4.397020] systemd[1]: Breaking ordering cycle by deleting job
syslog.socket/start
[    4.397026] systemd[1]: Found ordering cycle on prefdm.service/start
[    4.397029] systemd[1]: Walked on cycle path to
plymouth-quit.service/stop
[    4.397030] systemd[1]: Walked on cycle path to rc-local.service/start
[    4.397030] systemd[1]: Walked on cycle path to rinetd.service/start
[    4.397030] systemd[1]: Walked on cycle path to atieventsd.service/start
[    4.397030] systemd[1]: Walked on cycle path to prefdm.service/start
[    4.397030] systemd[1]: Breaking ordering cycle by deleting job
plymouth-quit.service/stop
[    4.397030] systemd[1]: Found ordering cycle on prefdm.service/start
[    4.397030] systemd[1]: Walked on cycle path to getty at tty1.service/stop
[    4.397030] systemd[1]: Walked on cycle path to
plymouth-quit-wait.service/start
[    4.397030] systemd[1]: Walked on cycle path to rc-local.service/start
[    4.397030] systemd[1]: Walked on cycle path to rinetd.service/start
[    4.397030] systemd[1]: Walked on cycle path to atieventsd.service/start
[    4.397030] systemd[1]: Walked on cycle path to prefdm.service/start
[    4.397030] systemd[1]: Breaking ordering cycle by deleting job
getty at tty1.service/stop
[    4.397030] systemd[1]: Looking at job prefdm.service/start
conflicted_by=no
[    4.397030] systemd[1]: Looking at job prefdm.service/stop
conflicted_by=no
[    4.397132] systemd[1]: Fixing conflicting jobs by deleting job
prefdm.service/stop
[    4.397132] systemd[1]: Installed new job graphical.target/start as 1


This is obviously good in this case, but I'm not sure what the knock on
effects will be.


Col




-- 

Colin Guthrie
gmane(at)colin.guthr.ie
http://colin.guthr.ie/

Day Job:
  Tribalogic Limited http://www.tribalogic.net/
Open Source:
  Mageia Contributor http://www.mageia.org/
  PulseAudio Hacker http://www.pulseaudio.org/
  Trac Hacker http://trac.edgewall.org/


More information about the systemd-devel mailing list