Comment 18 for bug 569757

Revision history for this message
Clint Byrum (clint-fewbar) wrote : Re: NIS upstart dependancy broken for lucid

So, a couple of points regarding this bug..

Re: Wishlist .. I have to agree that this is a regression from the previous LTS, and that it is caused by a race condition. Race conditions are hard to reproduce without introducing something synthetic to slow one of the racers down, but in this case, its clear, nis must delay the start up of a few things like gdm and autofs. I'm raising that to High since nis users really can't be sure their system will boot properly.

Re: moving everything into upstart. This should be done, and on cursory examination, the linked branch looks like it is on the right track. However, doing so in an LTS as an SRU is highly invasive. We can possibly use a similar trick as we used for statd and portmap to block at a certain point in the boot until nis is started, by removing it from /etc/rc#.d and adding two upstart jobs:

# nis

start on runlevel [2345]

pre-start exec /etc/init.d/nis start
post-stop exec /etc/init.d/nis stop
#EOF

# nis-wait

start on starting gdm or starting autofs
stop on started nis or stopped nis

task
normal exit 2
instance $JOB

script
  status nis | grep -q 'start/running' && exit 0
  start nis || true
  logger -t nis-wait -p daemon.info blocking $JOB until nis starts...
  sleep 3600
end script
#EOF

Since this only affects Ubuntu, and I think the problem is well understood, I'm setting the status to Triaged.