* umount -f stalls forever
@ 2014-07-09 20:15 Nathan Shearer
2014-07-10 5:11 ` NeilBrown
0 siblings, 1 reply; 3+ messages in thread
From: Nathan Shearer @ 2014-07-09 20:15 UTC (permalink / raw)
To: linux-nfs
When I have an nfs share that is mounted with the hard option (either
explicitly or implicitly since hard is on by default), and the nfs
server becomes unresponsive for any reason, it often causes the entire
OS to hang on many operations. In some cases I cannot even reboot a
server depending on what the nfs share was used for.
I relaize that this was probably done intentionally to prevent data
loss. However, when I am cleaning up a disaster and I actually do want
to "umount -f" a stalled nfs share and data loss es acceptable, then I
expect that command to return and the share to be unmounted. From a
usability perspective, stalling forever when I am explicitly forcing an
action is not right.
There is a workaround: and that is to assign the IP of the nfs server to
my system then issue umount -f, however that hardly the best way since I
am changing my network topology to unmount an offline filesystem. In
some situations adding an IP to an interface is not possilble, and if
the system is a remote system it could lead to more problems since it is
mostly unresponsive.
It would be greatly appreciated if a patch could be introduced that
allows "umount -f" to actually work without making any other changes to
a running system. The man page for umount even states that the -f
argument can be used to unmount an unreachable nfs share -- but it
almost never works.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: umount -f stalls forever
2014-07-09 20:15 umount -f stalls forever Nathan Shearer
@ 2014-07-10 5:11 ` NeilBrown
2014-07-14 17:29 ` Nathan Shearer
0 siblings, 1 reply; 3+ messages in thread
From: NeilBrown @ 2014-07-10 5:11 UTC (permalink / raw)
To: Nathan Shearer; +Cc: linux-nfs
[-- Attachment #1: Type: text/plain, Size: 2235 bytes --]
On Wed, 09 Jul 2014 14:15:03 -0600 Nathan Shearer <mail@nathanshearer.ca>
wrote:
> When I have an nfs share that is mounted with the hard option (either
> explicitly or implicitly since hard is on by default), and the nfs
> server becomes unresponsive for any reason, it often causes the entire
> OS to hang on many operations. In some cases I cannot even reboot a
> server depending on what the nfs share was used for.
>
> I relaize that this was probably done intentionally to prevent data
> loss. However, when I am cleaning up a disaster and I actually do want
> to "umount -f" a stalled nfs share and data loss es acceptable, then I
> expect that command to return and the share to be unmounted. From a
> usability perspective, stalling forever when I am explicitly forcing an
> action is not right.
>
> There is a workaround: and that is to assign the IP of the nfs server to
> my system then issue umount -f, however that hardly the best way since I
> am changing my network topology to unmount an offline filesystem. In
> some situations adding an IP to an interface is not possilble, and if
> the system is a remote system it could lead to more problems since it is
> mostly unresponsive.
>
> It would be greatly appreciated if a patch could be introduced that
> allows "umount -f" to actually work without making any other changes to
> a running system. The man page for umount even states that the -f
> argument can be used to unmount an unreachable nfs share -- but it
> almost never works.
> --
> To unsubscribe from this list: send the line "unsubscribe linux-nfs" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
Hi Nathan,
you don't say what kernel you are running....
A change was made in Linux 3.12 (8033426e6bdb2690d302872ac1e1fadaec1a5581)
which may address the problem you have.
So if you are using a kernel older than that, try a newer kernel.
This may not make "umount -f" work, but it should stop it from hanging.
To make it work you might need to kill all the processes using the mount
point first.
Also, "umount -l" might be a suitable answer to your problems.
NeilBrown
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 828 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: umount -f stalls forever
2014-07-10 5:11 ` NeilBrown
@ 2014-07-14 17:29 ` Nathan Shearer
0 siblings, 0 replies; 3+ messages in thread
From: Nathan Shearer @ 2014-07-14 17:29 UTC (permalink / raw)
To: NeilBrown; +Cc: linux-nfs
On 09/07/2014 11:11 PM, NeilBrown wrote:
> Hi Nathan, you don't say what kernel you are running.... A change was
> made in Linux 3.12 (8033426e6bdb2690d302872ac1e1fadaec1a5581) which
> may address the problem you have. So if you are using a kernel older
> than that, try a newer kernel. This may not make "umount -f" work, but
> it should stop it from hanging. To make it work you might need to kill
> all the processes using the mount point first. Also, "umount -l" might
> be a suitable answer to your problems. NeilBrown
Hi Neil,
Thanks for the quick reply. The fileserver I ran into this issue on is
running a relatively old kernel:
Linux version 3.0.0-12-server (buildd@crested) (gcc version 4.6.1
(Ubuntu/Linaro 4.6.1-9ubuntu3) ) #20-Ubuntu SMP Fri Oct 7 16:36:30 UTC 2011
I haven't tried umount -f on a recent kernel with a stalled hard mounted
nfs share yet, but it's great to know that the issue is resolved :)
I was mostly reporting the issue in case it wasn't resolved, and also
creating some documentation in the mailing list in case anybody needed
to unmount a stalled nfs share in the future and needed a way to do it.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-07-14 17:29 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-07-09 20:15 umount -f stalls forever Nathan Shearer
2014-07-10 5:11 ` NeilBrown
2014-07-14 17:29 ` Nathan Shearer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox