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?)
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 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”
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.
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).