简体   繁体   中英

NFS mount hangs reboot

I have a couple of NFS mounts I am auto-mounting in fstab. Everything is fine till reboot then it hangs trying to unmount them, but I can manually umount them manually before reboot without issue. The server is still online and accessible when this happens. If it makes any difference, the workstation is Debian 8, and the server is Centos6.

//fstab //

devbox:/coding/go /nfs-mounts/go nfs auto 0 0

devbox:/usr/share/nginx/html/thriftstore

/nfs-mounts/thriftstore nfs auto 0 0

//hosts//

192.168.0.190 devbox.localdomain devbox

I have the same bug, i made a dirty workaround. I put a line in /etc/init.d/sendsigs :

do_stop () {
        invoke-rc.d umountnfs stop    # this is the new line
        OMITPIDS=

sudo umount -lf /mount_point足以解决问题。

I had the same issue when NFS was down.

I've set the bg , timeo=100 and retry=0 so the OS fails to mount, it won't try again and boot once the timeout is reached.

Edit /etc/fstab to be:
RemoteServer:/My/local/path  
/My/local/path nfs auto,defaults,soft,int,tcp,bg,timeo=100,retry=0 0 0

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM