1833780 Members
2238 Online
110063 Solutions
New Discussion

Re: Stale NFS mounts

 
mike adams_4
Occasional Contributor

Stale NFS mounts

What is the best way to resolve stale NFS mounts? This occured when rebiulding the NFS server and now the client is reporting stale mounts.
8 REPLIES 8
Pete Randall
Outstanding Contributor

Re: Stale NFS mounts

Mike,

The only way to really resolve stale mounts is to reboot. With the latest versions of HP-UX and NFS, this problem seems to happen less frequently - you might want to consider updating and/or patching NFS.


Pete

Pete
RAC_1
Honored Contributor

Re: Stale NFS mounts

With new NFS version, there is a provision to forcibly unmount stale NFS moounts. If you not have that, your only option is reboot.

You should be moutning the NFS mounts with soft option, so that you atleast get to work.

By default they are mounted with hard option.

Anil
There is no substitute to HARDWORK
Chris Wilshaw
Honored Contributor

Re: Stale NFS mounts

To refresh the mounts, you'll need to unmount each one from the client, then re-mount them (mount -a will do this as long as they have been defined in /etc/fstab.

Ideally, you should unmount them from the client before working on the server (of course, if the server crashed, you wouldn't have a chance to do this).
V. Nyga
Honored Contributor

Re: Stale NFS mounts

Hi,

umount -a
and then
mount -a
should work
If not, then you have to look for the process which still accesses the directory.

Volkmar
*** Say 'Thanks' with Kudos ***
Govind_3
Regular Advisor

Re: Stale NFS mounts

The best and the easiest way is to reboot the NFS clients, after the NFS server is rebuilt, to remove the stale NFS file handles.
The harder way is to however unmount the file system on the client and remount it.
Cheers,
Govind
Bill Hassell
Honored Contributor

Re: Stale NFS mounts

NFS is very difficult to handle when server or network problems exist. In essence, when the NFS server(s) went down, it was as if you yanked out a physical disk. There may be processes with open files, directory searches from the filesystems, user shells cd'ed into these directories, etc. So a lot of code needs special handling for loss of files and directories.

With the next release of HP-UX, an NFS forced umount may be available. But for now, NFS servers can never be shutdown until all clients have umounted their NFS mountpoints. This is one of the reasons to use NFS with caution on production servers.


Bill Hassell, sysadmin
Muthukumar_5
Honored Contributor

Re: Stale NFS mounts

Some human checks or automated scripting there.

Check particular Stale mount and unmount that with umount

Another key one is, if some user is on Staled directory then that will be a more problem. We have to tell the logged users to come out of that directory to unmount that FS there.

Simply removing entry from /etc/mnttab may be also used there.
Easy to suggest when don't know about the problem!