Skip to content

Instantly share code, notes, and snippets.

@davidpoblador
Created May 4, 2023 13:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save davidpoblador/138a35437ddb43967634a6285978c52b to your computer and use it in GitHub Desktop.
Save davidpoblador/138a35437ddb43967634a6285978c52b to your computer and use it in GitHub Desktop.
Make SMB/CIFS mountpoint work on startup when you have to wait for Tailscale to be up

SMB mountpoint in your tailscale network

Since it took a while for me to figure out, I will leave this here for posterity

Use case: You want to be able to mount a networked (SMB/CIFS) filesystem on Linux on startup but that endpoint needs to wait for Tailscale to be up (for instance, in a Synology NAS).

Make sure you specify the options noauto,x-systemd.automount,_netdev in /etc/fstab.

For example:

# /etc/fstab
//[ip]/[path] /mnt/[path] cifs vers=3.0,credentials=/root/.creds,noauto,x-systemd.automount,_netdev 0 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment