How to deal with freezes caused by autofs after network disconnect
14
votes
2
answers
13781
views
I mount four servers (3 via
cifs
, 1 via sshfs
) using autofs
.
auto.master
/- /etc/auto.all --timeout=60 --ghost
auto.all
/mnt \
/server1 -fstype=cifs,rw,credentials=/etc/.smbcredentials.txt,uid=1000,file_mode=0775,dir_mode=0775,users ://server1/ \
/server2/ -fstype=cifs,rw,credentials=/etc/.smbcredentials.txt,uid=1000,file_mode=0775,dir_mode=0775,users ://server2/ \
/server3 -fstype=cifs,rw,credentials=/etc/.smbcredentials.txt,uid=1000,file_mode=0775,dir_mode=0775,users ://server3/ \
/server4 -fstype=fuse,rw,allow_other,uid=1000,users,reconnect,cache=yes,kernel_cache,compression=no,large_read,Ciphers=arcfour :sshfs\#user@server\:/home
```
Everything is fine when I make a clean boot.
I connect to my network (using a VPN) and autofs
mounts everything.
# Problem
When there is a network disconnect, e.g. when I hibernate my laptop or connect to a different network, autofs
causes my explorer (dolphin) to freeze because it tries to load the remote share infinitely.
It becomes unresponsive and does not even react to SIGTERM commands.
Sometimes I am lucky and calling sudo service autofs stop
and sudo automount
helps to resolve the issue.
However, often it still stays freezed.
Sometimes even, my whole dock freezes due to this making all applications unselectable. Then I have to make a full reboot..
I've searched for weeks now for solution how to deal with autofs
in such situations. Before using autofs
, I had everything mounted via /etc/fstab
but that also required a manual remount after every network interruption.
I thought autofs
would help me here but it causes me even more trouble.
# Questions
1. Is there any point I overlooked that could solve the freezing problem?
2. Is there a completely different approach that may be better suited for my situation than autofs
?
PS: I'm on Kubuntu 16.04
Asked by pat-s
(348 rep)
Jan 9, 2018, 11:27 PM
Last activity: Jul 12, 2025, 11:09 AM
Last activity: Jul 12, 2025, 11:09 AM