Bug 352882

Summary: shutdown hangs trying to unmount nfs mount
Product: [openSUSE] openSUSE 10.3 Reporter: Tejun Heo <teheo>
Component: NetworkAssignee: E-mail List <bnc-team-screening>
Status: RESOLVED DUPLICATE QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None CC: chrubis, mt, nfbrown, samopal
Version: Final   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Tejun Heo 2008-01-10 12:59:42 UTC
On my laptop, I mount a directory from my workstation using autofs w/ soft,intr opts.  The network is managed by NetworkManager.  When I try to shutdown with the nfs filesystem mounted, the network goes down first when NetworkManager shuts down on log out, so when the system tries to unmount the nfs mount, it has no network access and it hangs with no way to finish the hang other than forcefully shutting down the machine by holding down the power button.  There gotta be a better solution.
Comment 1 Neil Brown 2008-01-18 21:18:47 UTC
If the network is managed by NetworkManager, it seems to me that NetworkManager
should be told what needs to be done before shutting it down.... however I
have no idea if that is possible.

I just tried to unmount an NFS filesystem after disabling the network and it worked perfectly, so something much be different in your situation.  I don't
suppose it is possible to get an 'strace' of umount when it is hanging?

Or maybe even a sysrq-T and find out exactly which process is blocking where?

With tcp soft mounts, each operation takes about 3 minutes to time out.  If there are several being done, that could easily add to over 10 minutes.... How long have you left it for to see if it sorts itself out?
Comment 2 Tejun Heo 2008-01-18 23:21:51 UTC
About a minute.  It's not a hard hang (shuts down eventually) and not a NFS bug but I think there shouldn't be any long delays during shutdown.  I have no idea how this can be orchestrated tho.  Maybe forcibly or lazily unmounting from nfs shutdown script if no network interface is up should do the job.  We know that a network interface won't be brought up no matter how long we wait.

Thanks.
Comment 3 Samuel Kroslak 2008-04-02 18:13:47 UTC
I'm using KNetworkManager to manage my network connection to local LAN. On this LAN 1 samba share is present and I have it mounted on my system. I experience extraordinary long shutdowns too (about 3 mins, maybe more). It doesn't matter if I connect to LAN through wifi or by wire. 

For further info check my description at http://www.suseforums.net/index.php?showtopic=46762&st=0&gopid=233224&#entry233224 but now I know this shutdown only happens, when I'm connected to LAN and have something samba mounted from there. If I'm connected to any different LAN, everything is ok. 
Comment 4 Neil Brown 2008-07-15 06:28:02 UTC
I should have reassigned this long ago - sorry.

The problem is really with network manager turning off the network
before stopping all the resources that use it (nfs/smbfs).

So I think it should be assigned to someone who understand the
configuration of networkmanager.
Comment 5 Cyril Hrubis 2008-07-15 10:32:49 UTC
So this bug is most likely a duplicate of bug #348318.

*** This bug has been marked as a duplicate of bug 348318 ***