NAS Synology VPN Bypass Plex

I’m a missing a step? Because it doesn’t work.

  1. Start the VPN
  2. Use Multiple Gateways trough Network, General, Advanced settings, check 'Enable Multiple Gateways.
  3. Lookup DNS trough https://www.dnswatch.info/dns/dnslookup?la=en&host=plex.tv&type=A&submit=Resolve.
  1. Add all the routes on Static route. I used the VPN interface

The problem is that the status of the routes are disables and I can’t enabled them. What I’m missing?

Hi. I cannot get this to work using the methods mentioned here as soon as I . Please help. This is what Ive done so far.
When I forward the 323400 internal and 32401 external port to the NAS with an active VPN (I have PIA), should it be forwarded to the NAS IP or the VPN default gateway? Because when I turn on the VPN the NAS gets a new gateway like 10.22.10…

  • Set Synology NAS to static IP outside the IP range in my Synology router RT2600
  • Set the default gateway to 192.168.1.1 router address.
  • Made a search with DNS watch and added the hits to the static route (now they have changed. It that because my ISP have given me a new external IP?)
  • Set the advanced settings to multiple gateways

What sjhould I try next?

This worked like a charm!! Thanks!!
I do have to point out that the only change I had to make was that I had to check the dns with the VPN disconnected. Once I got those, I added the routes on the gui and now it works with the VPN activated or deactivated.

So, this did work for me but if you are using DDNS there are some steps that aren’t mentioned here.

First, make sure that with VPN not running, go into Control Panel --> External Access --> Router Configuration and add TCP port 32400 as a custom port to open on your router, assuming you are using a UPnP router - otherwise manually forward that port on your router to your Synology local IP.

This port forwarding is NOT required for Plex to work remotely via app.plex.tv normally, and so I had never set it up. It IS required for this procedure to enable remote access…

Second, in Control Panel --> External Access --> DDNS, as mentioned earlier in this thread you’ll have to manually enter your external IP as it was when the VPN is not running, otherwise when you start the VPN it will put the VPN external IP here which, at least in the case of NordVPN, doesn’t allow any port forwarding.

Yes, this second requirement will be a point of failure anytime my cable modem reboots and gets a new remote IP on LAN1 - I will simply have to put the correct current IP in when that happens, but it seems to be the only solution. Synology should provide a means by which you can choose which interface (LAN1, VPN, etc) your DDNS is tied to.

These two additions allowed this process to work perfectly for me.

Also - if you modify your DDNS entry as described and then save it, you will automatically be asked about creating a new certificate and it is setup more completely for the entire system so I chose to do this step first, then the certificate work above.

I hope this helps !!

1 Like

Worked Perfectly, many thanks for sharing :slight_smile:

I have one minor problem, when I manually run the script (sudo sh routes.sh) my Plex Media Server is accessible just fine. However, it does not automatically seem to run at start up. I have succesfully copied the file, to /usr/local/etc/rc.d/, but somehow I loose my remote access after a restart of the NAS.

How can I make sure that the script is run at start up? Do I need to give extra permissions to the script?

*Edit
It seems that chmodding to 755 did the trick.

I had used your script on a previous setup with no problems. Just tried using it again after making some network changes and I am getting an error "cannot find device “ovs_eth1"” after running the script, any ideas?

Edit: Tried enabling Open vSwitch and then I get the error as “RTNETLINK answers: Network is unreachable”

Is this still working?

You probably figured this out by now, but you have to hit “save” in order for them to switch from “disabled” to “enabled”.

You should be elevated to a Plex Ninja! This was a huge help! Thank you

As you probably got to know already, it won’t survive. You could just put the generate command in a scheduled task though or even better, check out this little script: Automatically creates a new p12 certificate for Plex Media Server when Synology automatically renews its Let's Encrypt certificate · GitHub

My fork just added an extra conf setting for the domain, the real work is actually done by user ryansully.

1 Like

Wow, been looking for quite some time for a fix for this and this seems to have worked.
I have my own domain name so used that one instead of the Let’s encrypt and that also works.
The only thing is that in PMS I still see see the error “Not available outside your network” under Remote access, but it still seems to be working fine.

For me it seems to work by just setting the manual port 32400 in my Plex server settings and enable the port forwarding in my router. I didn’t have to add the static routes.

Will continue to monitor, but I can browse my entire catalogue on my phone when using 4G.

Update 5/3/20: This solution sometimes works, but half of the times I can’t reach my Plex.

Uhm, ok I tried to follow your guide but probably I miss some informations 'cause I really can’t get to your point. First, where do I tell what connection to use for each app in Synology DSM? Anyways, I’m in this condition:

  • I’d like to use Plex only within my local area since I already know two thing: my actual VPN do not allow port forwarding; my ISP do not allow port forwarding (i’m behind an LTE modem)
  • VPN works, I can access my NAS which was my only and primary goal; where do I tell Plex Server to avoid using VPN and going via the LAN?
  • I disabled the VPN, plex still can’t run; no, actually I can’t even access plex by the local ip address + 32400 port

Sorry, but could you walk me through what records go where? It doesn’t seem to be working for me (and two of the entries I tried creating just remain disabled in the static route table).

I don’t fully understand what any of these terms refer to (Network destination, Netmask, Gateway, etc) so any help would be GREATLY appreciated.

Thanks!

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.