Jump to content

NAS VPN - changing IP

I have a NAS set up using openmediavault (http://www.openmediavault.org/). This runs debian, headless, and everything works fine.

 

The NAS also runs an openVPN server. I have laptop clients connecting to the public IP of my router (which then forwards the traffic to the NAS) to connect to the VPN server hosted on my NAS. Everything here works fine too.

 

The problem, is that I recently signed up for a VPN service to anonymize my traffic. So now, on the NAS I have a VPN client set up (in addition to the previously mentioned VPN server) which connects me to the service I signed up for. OK, this is not a problem so far. 

 

However, by connecting to that VPN service on my NAS, it's going through a different public IP address (which is changing all the time). Although the NAS traffic to the outside world is not a problem, my laptop clients can now no longer connect to the VPN server hosted on NAS. I found out that this is because the public IP is constantly changing, so my laptops keep trying to connect to an old IP.

 

What options do I have to ensure my laptops can still connect to the NAS vpn server if my NAS itself is connecting to a different VPN service with a changing IP?

 

I would have thought that if my laptops connect to the public IP of my router, that traffic will still get forwarded internally to the NAS and everything will be fine but that does not seem to be the case

 

It all works if my laptops connect to the most recent IP that the NAS connects to (via the VPN service), but the problem is that I can never know if there has been an IP change (or what the new IP is) if I'm away from home.

 

Thoughts?

Link to comment
https://linustechtips.com/topic/262809-nas-vpn-changing-ip/
Share on other sites

Link to post
Share on other sites

So presumably I would need 2 internal IPs, and 2 external (one provided by ISP, and one provided by VPN)? How does one set this up on debian?

Yes, ultimately you would have that. As long as you have two connected network adapters, it will assign IPs accordingly. I am not 100 % sure this will work because I am simply not able to recreate your setup, but it is wort a try.

All though, is the VPN service hosted on Debian or your Router?

Tux is a lie.

Link to comment
https://linustechtips.com/topic/262809-nas-vpn-changing-ip/#findComment-3584969
Share on other sites

Link to post
Share on other sites

my own vpn server is on debian. For the service that my NAS is connecting to I'm not sure what they run

 

Is there an alternative to having to buy another NIC? I'd rather not have to spend any money on this

 

Im currently looking into setting up a ddns updater to solve the problem. will see if that works

Link to comment
https://linustechtips.com/topic/262809-nas-vpn-changing-ip/#findComment-3588774
Share on other sites

Link to post
Share on other sites

I would recommend using no-ip for your DDNS. I currently use them and I've had a pretty good experience so far (I have a dynamic IP on my home internet, so I use it to track my IP so I can connect to my server).

15" MBP TB

AMD 5800X | Gigabyte Aorus Master | EVGA 2060 KO Ultra | Define 7 || Blade Server: Intel 3570k | GD65 | Corsair C70 | 13TB

Link to comment
https://linustechtips.com/topic/262809-nas-vpn-changing-ip/#findComment-3589969
Share on other sites

Link to post
Share on other sites

I would recommend using no-ip for your DDNS. I currently use them and I've had a pretty good experience so far (I have a dynamic IP on my home internet, so I use it to track my IP so I can connect to my server).

 

I'll give noip a go. Got the updater set up on debian now

 

What happens to your noip account at the end of every month? Is it just an email they send you for confirmation/reactivation? Or do you need to set up a new host every single month?

Link to comment
https://linustechtips.com/topic/262809-nas-vpn-changing-ip/#findComment-3590044
Share on other sites

Link to post
Share on other sites

I'll give noip a go. Got the updater set up on debian now

 

What happens to your noip account at the end of every month? Is it just an email they send you for confirmation/reactivation? Or do you need to set up a new host every single month?

Yeah, if you have a free account they send you an email every month with a link you need to click. It's not too bad.

15" MBP TB

AMD 5800X | Gigabyte Aorus Master | EVGA 2060 KO Ultra | Define 7 || Blade Server: Intel 3570k | GD65 | Corsair C70 | 13TB

Link to comment
https://linustechtips.com/topic/262809-nas-vpn-changing-ip/#findComment-3590058
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×