Re: [NFS] Re: broken umount -f

Tim Connors (tconnors@astro.swin.edu.au)
Thu, 16 Jan 2003 20:55:55 +1100


In linux.kernel, you wrote:
>> >>For as long as I remember, umount -f has been broken. I got
>> a reminder
>> >>of this fact today when we took an older NFS server out of
>> use. I had
>> >>to reboot almost all machines that had mounts from this server. Not
>> >>nice.
>> >>
>> >>Anyone knows why -f does not work? When I try, I get:
>> >>
> "umount -f" doesn't end pending RPCs. if there are processes
> with pending RPCs, then they are stuck and you will have to
> reboot. "intr" may allow some of these processes to be killed
> before trying the "umount."
>
> however, if there are no outstanding RPCs on the client, but
> the server is not available, umount -f works as advertised.

What I have never understood, is that if you are reading a file, or
even just in a directory, and the server goes down, and won't come
back up (say, you have taken your laptop into work, and forgot to turn
off autofs first, after killing all shells that had cd'd to the nfs
directory), then you still are destined to have to reboot. You could
sever all connections to the nfs server safely, because nothing is
being written there (except maybe atime information - but not in the
case of a shell being cd'd to an nfs path). But linux won't give up on
the connection. Come on, what harm could possibly come to an
application that has only readonly files open, or cwd in an NFS path?
No data loss would occur in this situation, so just drop the
connection, and return -EIO to anything that then later wants to read
a file.

If the admin is wanting to use umount -f, then surely he will be
edumucated enough to make sure data loss will not occur first, or that
the consequences are less than if he just left the mount hang.

-- 
TimC -- http://astronomy.swin.edu.au/staff/tconnors/

You see, wire telegraph is a kind of a very, very long cat. You pull his tail in New York and his head is meowing in Los Angeles. Do you understand this? And radio operates exactly the same way: you send signals here, they receive them there. The only difference is that there is no cat. -- Albie E. on radios. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/