Re: Chance to release stale nfs mount from non-existent nfs server without rebooting client? (471 Views)
Reply
Honored Contributor
Ralph Grothe
Posts: 2,631
Registered: ‎04-09-2000
Message 1 of 11 (600 Views)
Accepted Solution

Chance to release stale nfs mount from non-existent nfs server without rebooting client?

Hi, I'm dispairing.

The problem is as written in the subject line.

The nfs server isn't alive anymore:


ping -t 10 $(grep nfs /etc/mnttab|cut -d: -f1) -n 1
PING 10.10.110.133: 64 byte packets

----10.10.110.133 PING Statistics----
1 packets transmitted, 0 packets received, 100% packet loss


Since the nfs mount is stale no wonder that all nfs requests hang (e.g. bdf), and an umount attempt fails.

umount $(awk '$3=="nfs"{print $2}' /etc/mnttab)
nfs umount: nfs_unmount: /tmp/bwdiwo: is busy

Ok, Itried to stop the nfs client, but since it neither can release the stale mount it shrewedly reappears.

/sbin/init.d/nfs.client stop
killing rpc.lockd
killing rpc.statd
killing nfsd
killing rpc.mountd
starting NFS SERVER networking

starting up the rpcbind daemon
rpcbind already started, using pid: 1249
starting up the mount daemon
/usr/sbin/rpc.mountd
starting up the NFS daemons
/usr/sbin/nfsd 4
starting up the Status Monitor daemon
/usr/sbin/rpc.statd
starting up the Lock Manager daemon
/usr/sbin/rpc.lockd
umountall: umount : has failed.
umountall: diagnostics from umount
nfs umount: nfs_unmount: /tmp/bwdiwo: is busy


Needless to mention that games like such also fail.


fuser -ck $(awk '$3=="nfs"{print $2}' /etc/mnttab)

or
perl -i.stale -ne 'print unless /nfs/' /etc/mnttab && rmdir /tmp/bwdiwo


Is there any hope to get rid of this nfs mount without rebooting the damned host?
Madness, thy name is system administration
Outstanding Contributor
Pete Randall
Posts: 16,205
Registered: ‎11-03-1996
Message 2 of 11 (600 Views)

Re: Chance to release stale nfs mount from non-existent nfs server without rebooting client?

Ralph,

It's been my sad experience that the only way to get rid of the stale mounts is to reboot. Sorry!


Pete

Pete
HP Expert
Ramkumar Devanathan
Posts: 1,645
Registered: ‎07-31-2002
Message 3 of 11 (600 Views)

Re: Chance to release stale nfs mount from non-existent nfs server without rebooting client?

Honored Contributor
Ravi_8
Posts: 2,824
Registered: ‎04-16-2001
Message 4 of 11 (600 Views)

Re: Chance to release stale nfs mount from non-existent nfs server without rebooting client?

Hi,

i too had expereinced stale nfs, ultimately rebooting the m/c is the solution we found
never give up
Honored Contributor
Stefan Farrelly
Posts: 3,910
Registered: ‎10-23-1996
Message 5 of 11 (600 Views)

Re: Chance to release stale nfs mount from non-existent nfs server without rebooting client?

The only thing ive found which helps is to remove /etc/mnttab. This allows you to survive for some time without errors, but in time you /etc/mnttab gets recreated and you will need to remove it again.

Only a reboot will fix it properly, sorry.
Im from Palmerston North, New Zealand, but somehow ended up in London...
Frequent Advisor
Olivier ROBERT
Posts: 70
Registered: ‎02-19-2002
Message 6 of 11 (600 Views)

Re: Chance to release stale nfs mount from non-existent nfs server without rebooting client?

Hi Ralph,

Eventually, removing NFS mount points as the NFS server is dead has been a problem for many of us I guess, not only on HP-UX systems, and I wonder why this has never been adressed. Is there any reason for that? For example, I guess we all would appreciate having the ability to remount soft and/or intr if necessary, and then remove the attached processes and the mount point. Wouldn't that be a good idea?

Regards,

Olivier
Outstanding Contributor
Pete Randall
Posts: 16,205
Registered: ‎11-03-1996
Message 7 of 11 (600 Views)

Re: Chance to release stale nfs mount from non-existent nfs server without rebooting client?

I seem to recall that, at one time, there was a patch to the umount command that was supposed to allow you to force the unmount but, if that's true, I don't know what ever happened to it because such an option doesn't seem to exist now.

Any HP'ers out there that can offer any insight?


Pete

Pete
Exalted Contributor
Steven E. Protter
Posts: 33,806
Registered: ‎08-15-2002
Message 8 of 11 (600 Views)

Re: Chance to release stale nfs mount from non-existent nfs server without rebooting client?

First I umount the fs which almost never works on the client.

Then I fuser -cuk /mount_point ...

Then I shut down the nfs client and nfs core, immediately restarting.

Then I wake up and boot the box, commenting out anything in /etc/fstab that will generate errors.



SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Honored Contributor
Paul Sperry
Posts: 1,442
Registered: ‎10-07-2002
Message 9 of 11 (600 Views)

Re: Chance to release stale nfs mount from non-existent nfs server without rebooting client?

reboot :(
Frequent Advisor
Olivier ROBERT
Posts: 70
Registered: ‎02-19-2002
Message 10 of 11 (600 Views)

Re: Chance to release stale nfs mount from non-existent nfs server without rebooting client?

Awww... considering all replies so far, this looks like a lost cause!

Pete, if such an option of umount ever existed, I suppose it was removed because its implementation was not compliant with some standard. But really, I would appreciate hearing of an HP representative on that subject...

Regards,

Olivier
Visitor
earnest_rs
Posts: 1
Registered: ‎07-14-2011
Message 11 of 11 (471 Views)

Re: Chance to release stale nfs mount from non-existent nfs server without rebooting client?

try umount -f <mount point>    v3 OS

 

 

 

The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation.