ChrisTitusTech / website

My HUGO Website that I use for Videos, Blogs, and Redirects
82 stars 43 forks source link

auto-mount-systemd/ #46

Open utterances-bot opened 2 years ago

utterances-bot commented 2 years ago

Auto Mount with SystemD

Having Fun with Technology

https://christitus.com/auto-mount-systemd/

Jeff-WuYo commented 2 years ago

Hi, I have multiple nic, not all of them are always connected, this cause systemd-networkd-wait-online.service to fail and mount slowly. Adding --any to the service solve the issue. I don't know if using NetworkManager will face the same issue, but it's worth mentioning.

Another thing is that using x-systemd.automount, neither "auto" nor "noauto" will have any effect.

Hope it helps.

Findarato commented 1 year ago

Is there a benefit to doing this vs systemd unit files?

dayvid3 commented 1 year ago

I've (and apparently many others) had issues with fstab after a kernel update over a year ago. I didn't have much luck with systemd, but maybe I didn't spend enough time on it. I switched to using a script triggered by an @reboot sudo crontab to be rock-solid.