Hey guys! So I have a simple dilemma. The computer i use for video/movies is on a vpn. Sometimes I want to move those videos to my nas.
Now I am just using the mulvad program on the local pc (linux). I dont have it installed on my router (and im not sure if I will yet, since with slowdowns and some sites and applications not working on a VPN, I dont really need it network wide at this point)
But my problem is, my nas isn’t accessible from the pc, unless I shut off the VPN, which I dont want to do when in the middle of a big download. Also, it would be nice sometimes to download right to my nas so I dont need to move files.
Is there a somewhat easy solution? Im decently savvy but networking still confuses me sometimes.
I believe in mullvad there’s a setting to “allow local traffic”,
Navigate: to the Preferences or Settings menu. Find: the option for “Local network sharing” and enable it by turning the switch on
or if you are using CLI
mullvad lan set allow
in short, most vpn clients have an option to not override local traffic. while still directing everything outside of your LAN through the VPN.
Generally it’s called “split tunneling” but they might call it something else
i JUST saw that setting! that helps. though i’m trying to keep this pc mostly isolated from my home network, i think checking that option just to move files over and then rechecking it would be fine with me.
You could add your NAS local address to not go through your VPN using advanced split tunneling on Linux.
Look at the docs from Mullvad it might help you do what you want : https://mullvad.net/en/help/split-tunneling-with-linux-advancedYou should be able to add a route just for your nas without enabling lan sharing, something like
sudo ip r a 192.168.1.123/32 via 192.168.1.1 dev eth0
Where .123 is your nas, .1 is your router, eth0 is your physical network interface.
But it’s probably better to just toggle lan sharing.
I don’t typically use a VPN so take my advice with a grain of salt, but I’m pretty sure what you’re looking for is split tunneling. Set it so that all traffic goes through your VPN except the IP of your NAS.
I don’t know how ya’ll get away with not using a VPN. I’d get instantly hosed
Well that depends: is your NAS on the local network?
If yes, then personally I just use SMB.
If no, then fuck if I know. Lol.
I’ve used
rsync
in the past, it’s quite nice, very fast. I don’t know that it will work for you, but I was surprised to learn it existed.You can run a WebDAV server and bind to the interface on your local network.
There’s also an ad hoc version if you don’t want it running all the time.
I think tailscale would fit your use case perfectly.
You can install tailscale on your computer and your NAS. This way, there is a tunnel between your computer and your NAS. In practice you will have a separate IP address for your NAS that you can use from your computer.
It also means that you will have secure access to your NAS from wherever in the world as long as you have internet access.
Then, Mullvad and tailscale are integrated together. It means that from tailscale you get the Mullvad add-on that allows you to use Mullvad as exit-point. Meaning that all your traffic that is not in your tailscale network will go through Mullvad (so in your case everything except your NAS)
It’s been two years that I am using that and it’s working great for me.
Depending on which VPN you’re using, you might be able to put the NAS on the VPN too. If for example you use Nord, they have a feature called Meshnet that gives each computer a unique hostname that you can access via the VPN.
Update: Meshnet is going away in December. Fuck. I need to find an alternative.
A better option, use a container that connects whatever torrent program to the VPN. Only that will be on the PN, and depending how it’s setup it will only connect to the VPN, making it unable to leak your IP address if the connection fails. You can just sftp into the NAS that way and is by far the easiest solution.