nbd-client doesn't stop on reboot or halt
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
nbd (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
OS: Ubuntu Natty (Ubuntu 11.04) 32+64 Bit
Affected versions: 1:2.9.16-7.1ubuntu2 1:2.9.23-3ubuntu1 perhaps some others.
When rebooting or shutdown a system with nbd-client active, then the clients doesn't close the connection properly to the server -> postrun can not be used. Server-log shows entries like this: "Read failed: Inappropriate ioctl for device", "Child exited with 1".
By manual disconnect the share (nbd-client -d share) there is no problem.
The problem is, that in /etc/rc0.d and /etc/rc6.d are faulty links: "S34nbd-client -> ../init.
The correct links should look like this: "K59nbd-client -> ../init.
The solution is very easy:
"update-rc.d -f nbd-client remove"
"update-rc.d nbd-client start 41 S . stop 59 0 6 ."
The package-maintainer should correct it.
On Sun, Aug 07, 2011 at 03:01:43PM -0000, Schöner, Axel wrote:
> The solution is very easy:
> "update-rc.d -f nbd-client remove"
> "update-rc.d nbd-client start 41 S . stop 59 0 6 ."
The problem is this:
override_ dh_installinit:
dh_installinit -p nbd-client --no-start -- start 41 S . start 34 0 6 .
dh_installinit -p nbd-server
in debian/rules. That should, of course, be 'stop 34 0 6' at the end.
This bug was most likely introduced when I modified nbd to use a
debhelper 7 'dh' style debian/rules file, which happened at a time when
Debian had already migrated to using insstyle by default to create the
links. In that mode, the symlinks aren't chosen from the update-rc.d
command line, but from special comments in the init script instead; this
is why the bug wasn't found earlier. I suppose this also means that the
manually-specified symlink order in Debian isn't being maintained
anymore.
I've committed a change to my local copy of the debian/rules file so
that with my next upload, this problem should not occur anymore. It
might be prudent for Ubuntu to do an update to fix this as well, but I
don't know what Ubuntu's release policies are.
--
The volume of a pizza of thickness a and radius z can be described by
the following formula:
pi zz a