Quick status update/summary on this bug, because this thread is long and
tends to discourage people that could solve it.

The bug occurs on shutdown if you mount a CIFS share (using mount or
/etc/fstab). In some cases, S31umountnfs.sh tries to unmount the network
file system *after* the network has been brought down. CIFS doesn't
handle so well having the network pulled out from under it, so it stalls
the shutdown process for some time, but the shutdown finally succeeds.

The most common case appears to be those using NetworkManager to handle
the network interface (NetworkManager gets killed by S20sendsigs, before
S31umountnfs.sh). If you are not using NetworkManager at all (and have
your network defined in /etc/network/interfaces), the unmount will
succeed. That's why this bug doesn't really affect Ubuntu Server
systems. Also I would argue that you should not mount things system-wide
while having your network up/down at Gnome session start (think
wireless). Nautilus-based mounts seem like a better idea in that case.

It's *not* simple to fix. There are lots of workarounds which will solve
the problem for your use case, but which will also break it for other
folks. The fact that workaround X solves the issue for you doesn't make
it a proper update that can be applied to all other Ubuntu systems.
Cutting the network filesystem before S20sendsigs for example may result
in data corruption, which is arguably worse than an annoying delay at
shutdown.

The best way of solving this is to have CIFS (probably in kernel) better
support having the network pulled out from under it. I haven't really
found how we could do that, but I'll try to invite some CIFS specialists
here. Another way could be to exclude NetworkManager from S20sendsigs
and kill it properly at ~S35... constructive, technical comments
welcome.

It's true that the way Launchpad works doesn't help us in solving this
kind of in-between-packages bugs (and most distributions won't be better
than us). But bitching about it just makes developers turn to easier
(and more rewarding) bugs to fix.


** Bug watch added: Debian Bug tracker #477498
   http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=477498

** Also affects: sysvinit (Debian) via
   http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=477498
   Importance: Unknown
       Status: Unknown

-- 
CIFS/SMBFS shares not unmounted before network is shut down
https://bugs.launchpad.net/bugs/211631
You received this bug notification because you are a member of Ubuntu
Server Team, which is subscribed to samba in ubuntu.

-- 
Ubuntu-server-bugs mailing list
Ubuntu-server-bugs@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server-bugs

Reply via email to