Automount + NFS hang issues (follow-up to FreeBSD 12.3/13.1 NFS client hang thread)
Date: Sun, 14 Apr 2024 15:47:56 UTC
Hello, I'm doing a follow-up on the thread FreeBSD 12.3/13.1 NFS client hang, message ID YpEwxdGCouUUFHiE@shipon.lysator.liu.se. After having had recurring issues ever since that thread and not managing a good tcpdump of a hang, I decided to simply get rid of automount and instead mount the NFS shares via the fstab. With the mounts being done via the fstab instead of automount, the NFS server restarting causes processes using the mount to hang, but when the server comes back things recover. When using automount as the NFS server becomes unresponsive, the system log is filled with lines like 7 Apr 10 13:00:14 shipon kernel: WARNING: autofs_trigger_one: request for /home/ completed with error 60, pid 68836 (fish) 8 Apr 10 13:00:14 shipon kernel: WARNING: autofs_trigger_one: request for /home/ completed with error 60, pid 69248 (sshd) 9 Apr 10 13:00:14 shipon kernel: WARNING: autofs_trigger_one: request for /home/ completed with error 60, pid 2221 (weechat) and it seems like automount is repeatedly trying to perform mounts until the system eventually hangs. When the system has hung, all automount processes are stuck in the kernel in uninterruptable sleep in the NFS code. You can find some stack traces in the old thread. Sometimes a umount -N on all the mounts would solve the issue, but often a system reboot was the only way to recover. Best regards, Andreas Kempe