[HOW TO] Use Tailscale and Samba

Share your awesome tips and tricks here.
rmorris
Posts: 4
youtube meble na wymiar Warszawa
Joined: Wed Apr 03, 2024 12:44 pm

[HOW TO] Use Tailscale and Samba

Post by rmorris »

Hello,

Tailscale and Samba - if you are unable to connect.

If you are using Tailscale on your NAS and finding that SAMBA shares are not accessible via the tailnet, you may need to adjust your smb.conf file.
This is because, by default, Samba only listens on the physical interfaces, and not the dynamicaly named virtual tailscale interface.
For me, I found that I had to add the following line to my smb.conf file.

1) SSH to your NAS
2) Navigate to :

Code: Select all

cd /volume0/usr/builtin/etc/samba/
3) Take a backup of the config file:

Code: Select all

cp smb.conf smb.orig
4) Edit smb.conf with vi:

Code: Select all

vi smb.conf
5) Add the follwing line at the bottom of the [GLOBAL] section:

Code: Select all

bind interfaces only = no
6) Save and exit.
7) Restart Samba (you can do this via command line or via ADM - turning SMB off then back on again).

You should now be able to connect to the Samba shares from a remote device on your tailnet.

Caveat: Using Samba shares over slow links is not recommended.

Sharing all the above based on various suggestions found via google. Tested on AS1004T v2. Your mileage may vary.

Good luck.