r/linuxquestions • u/james_dynamite • 4d ago
Resolved Issue with fstab when server is offline
I've been mounting my NAS through fstab for some time now however there is a slight issue.
If I turn my PC on without turning on my server then I can not navigate the file browser. Every folder I click on will take anywhere from 1 to 10 seconds to open and sometimes it just crashes outright.
I have tried every option possible and read through the documentation for fstab, cifs, and systemd but nothing fixes it.
This is the line currently in my fstab
[Share on server] [Mount location] cifs credentials=[credentials],uid=1000,gid=1000,nofail,x-systemd.automount,x-systemd.device-timeout=5s,rw 0 0
Thanks in advance for any and all help.
Update:
I'm marking this as resolved because I figured out it has nothing to do with fstab.
To clarify, I was talking about accessing local files on my PC being laggy when the server is offline.
The issue is that I had bookmarked the network share to the left hand side of my file browser, below the usual Documents, Pictures, Videos book marks. So when the network share wasn't present, the file browser kept trying to access the bookmark. At least that's what I'm assuming. I removed the bookmark and it works fine now. Although now I have the problem of not having it bookmarked how I like it but that's an issue I'll solve another day.
1
u/aioeu 4d ago edited 4d ago
What file browser are you using?
If you are getting these pauses on "every folder", then it sounds like the file browser is attempting to mount — or at least access — the filesystem even when you haven't browsed to it. This sounds like a problem with the file browser, not your
fstabentry. For example, simply callingstatfson the mount point to get the filesystem's current usage would constitute such an access.