[Bug 567865] New: Shutdown hangs on stopping smbfs after NetworkManager was killed
http://bugzilla.novell.com/show_bug.cgi?id=567865 http://bugzilla.novell.com/show_bug.cgi?id=567865#c0 Summary: Shutdown hangs on stopping smbfs after NetworkManager was killed Classification: openSUSE Product: openSUSE 11.2 Version: Final Platform: i686 OS/Version: openSUSE 11.2 Status: NEW Severity: Normal Priority: P5 - None Component: Basesystem AssignedTo: bnc-team-screening@forge.provo.novell.com ReportedBy: vdboor-fora@codingdomain.com QAContact: qa@suse.de Found By: --- Blocker: --- User-Agent: Mozilla/5.0 (X11; U; Linux i686; nl; rv:1.9.1.6) Gecko/20091201 SUSE/3.5.6-1.1.1 Firefox/3.5.6 The shutdown of openSUSE 11.2 is delayed by a few minutes when SMB shares are mounted. Reproducible: Always Steps to Reproduce: - Have a wifi connection with NetworkManager. - Have shares in /etc/samba/smbfstab. - /etc/init.d/smbfs start - /etc/init.d/network stop Actual Results: NetworkManager is killed first (so the wlan connection is lost), and next it tries to unmount the shares of /etc/samba/smbfstab with the script from /etc/sysconfig/network/if-down.d/21-smbfs script. This hangs for a few minutes. Expected Results: - The smbfs script to run first for normal situations. - The smbfs script to quickly unmount when the network is unreachable. -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c
yang xiaoyu
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c
Lars Müller
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c1
Lars Müller
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c2
Christian Wittmer
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c3
Christian Wittmer
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c4
Lars Müller
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c6
--- Comment #6 from Marius Tomaschewski
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c7
Rainer Klier
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c8
Diederik van der Boor
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c9
Lars Müller
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c10
Lars Müller
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c
Suresh Jayaraman
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c11
Suresh Jayaraman
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c12
--- Comment #12 from Suresh Jayaraman
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c13
--- Comment #13 from Diederik van der Boor
Ping!
Sorry, been away for a while. I don't really get the solution of comment #5, and reading it does not make it sound related to my situation, which is: - When I boot: * once the network is up, /mnt/nas/SomeShare is mounted using /etc/init.d/smbfs - When I shutdown: * KDE exits, the NM applet is killed. * Connection is lost, /etc/init.d/smbfs stop does not run yet however. * At shutdown, the init scripts try to tear down the smbfs connections. * The shutdown procedure waits 2 minutes for a timeout.. -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c14
--- Comment #14 from Rainer Klier
(In reply to comment #12)
Ping!
Sorry, been away for a while. I don't really get the solution of comment #5, and reading it does not make it sound related to my situation, which is:
- When I boot: * once the network is up, /mnt/nas/SomeShare is mounted using /etc/init.d/smbfs - When I shutdown: * KDE exits, the NM applet is killed. * Connection is lost, /etc/init.d/smbfs stop does not run yet however. * At shutdown, the init scripts try to tear down the smbfs connections. * The shutdown procedure waits 2 minutes for a timeout..
the solution from comment #5 is described in bug 487190#c7. you should NOT use /etc/init.d/smbfs! disable it using: insserv -r smbfs and instead use networkmanager dispatcher script /etc/NetworkManager/dispatcher.d/smbfs. this script can be made by copying /etc/NetworkManager/dispatcher.d/nfs and changing it. here it is ready-to-use as attachment from bug 487190: https://bugzilla.novell.com/attachment.cgi?id=336364 but this only works when: 1. /usr is on local disc. 2. NetworkManger is used but i assume this is the case for you, Diederik, right? -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c15
Diederik van der Boor
the solution from comment #5 is described in bug 487190#c7. you should NOT use /etc/init.d/smbfs! disable it using: insserv -r smbfs
and instead use networkmanager dispatcher script /etc/NetworkManager/dispatcher.d/smbfs. this script can be made by copying /etc/NetworkManager/dispatcher.d/nfs and changing it. here it is ready-to-use as attachment from bug 487190: https://bugzilla.novell.com/attachment.cgi?id=336364
I've tried this solution, it merely moves the problem. Mounting works properly after being connected. Unmounting happens too late. Unmounting happens when the connection is already closed. For example * When selecting a different network to connect to * When closing/killing the network manager applet. So there is a umount.cifs being stale for each of my connected shares. After ~1 minute it's timed out, and the mount is removed. Then it continues with the next mounted share, up till all 5 I have..
but this only works when: 1. /usr is on local disc. 2. NetworkManger is used
but i assume this is the case for you, Diederik, right?
Yes, I'm using a pretty standard openSUSE install on a laptop. Hence the NetworkManager stuff, because I'm mostly connected with WiFi, even at home. Here, I auto-mount my NAS network shares via smbfs/cifs. -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c16
--- Comment #16 from Rainer Klier
(In reply to comment #14)
here it is ready-to-use as attachment from bug 487190: https://bugzilla.novell.com/attachment.cgi?id=336364
I've tried this solution, it merely moves the problem.
Mounting works properly after being connected. Unmounting happens too late.
Unmounting happens when the connection is already closed. For example * When selecting a different network to connect to * When closing/killing the network manager applet.
yes, but these situations are not happening as often as a shutdown. so it is better to have the timeouts happen in these situations than in a shutdown. i never noticed the timeouts or too late unmountings since i use the networkmanager-dispatcher-script. but i usually also don't kill networkmanager during work, nor do i switch networks. but, of course, the umounts should be done correctly, even if network is switched or networkmanager applet gets killed.
NetworkManager stuff, because I'm mostly connected with WiFi, even at home. Here, I auto-mount my NAS network shares via smbfs/cifs.
and you switch networks at home also? -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c17
--- Comment #17 from Suresh Jayaraman
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c19
--- Comment #19 from Diederik van der Boor
(In reply to comment #15)
Unmounting happens when the connection is already closed. For example * When selecting a different network to connect to * When closing/killing the network manager applet.
yes, but these situations are not happening as often as a shutdown. so it is better to have the timeouts happen in these situations than in a shutdown.
When a shutdown is initiated, the network manager applet is closed once KDE (or GNOME) exists. So for every shutdown, the connection is closed before any init.d script runs.
NetworkManager stuff, because I'm mostly connected with WiFi, even at home. Here, I auto-mount my NAS network shares via smbfs/cifs.
and you switch networks at home also?
Only plugging in an ethernet cable every now and then. I was mainly listing all possible scenario's where the connection is dropped before any unmount script runs. -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=567865
http://bugzilla.novell.com/show_bug.cgi?id=567865#c20
--- Comment #20 from Rainer Klier
(In reply to comment #16)
(In reply to comment #15)
Unmounting happens when the connection is already closed. For example * When selecting a different network to connect to * When closing/killing the network manager applet.
yes, but these situations are not happening as often as a shutdown. so it is better to have the timeouts happen in these situations than in a shutdown.
When a shutdown is initiated, the network manager applet is closed once KDE (or GNOME) exists. So for every shutdown, the connection is closed before any init.d script runs.
yes. but that is not a problem any more. there is no init.d script anymore dealing with smbfs. because i disabled /etc/init.d/smbfs in rc5.d. so the only umounting of all the smb/cifs-shares happens, when networkmanager is quit. and at this time the shares are there and can be umounted. so no hang or timeout anymore and shares become umounted without any problems. -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=567865
https://bugzilla.novell.com/show_bug.cgi?id=567865#c21
Xinli Niu
https://bugzilla.novell.com/show_bug.cgi?id=567865
https://bugzilla.novell.com/show_bug.cgi?id=567865#c22
--- Comment #22 from Rainer Klier
https://bugzilla.novell.com/show_bug.cgi?id=567865
https://bugzilla.novell.com/show_bug.cgi?id=567865#c23
Andreas Jaeger
participants (1)
-
bugzilla_noreply@novell.com