Systemd NFS automount hangs some GTK programs
Steps to reproduce
I have a systemd automount for some network shares on my laptop. When I'm on a network where the share is not available. Some GTK programs 'hang' during startup. An example is Glade. But also my own software. When I remove the gtkFileChooserButton from my application (which glade also displays in its main screen) the problem goes away. It is also no problem when I "systemctl stop mnt-*.automount". Glade then starts fine.
My mnt-xxx.mount service file looks like this.
[Unit] Description=Mount Share at boot [Mount] What=10.0.0.8:/export/xxx Where=/mnt/xxx Options=noatime,noauto,user Type=nfs TimeoutSec=3 TimeoutIdleSec=10 ForceUnmount=true [Install] WantedBy=multi-user.target
In the systemd logs I see that the application tries to access /mnt/xxx at startup. I would expect it to list mounts when I actually opened a file dialog, not on startup. And even when the file dialog shows a 'hang' isn't acceptable unless the user tries to open the problematic directory.
libgtk 3.24.23 Debian Unstable Wayland / Sway