Page 1 of 1

Plex port forwarding

Posted: Wed Nov 28, 2018 10:59 pm
by VodoBaas1
Hello,

I am trying to get Plex available from outside my network, but even with my NAT rules I can't seem to get it to work.
add action=passthrough chain=unused-hs-chain comment="place hotspot rules here" disabled=yes
add action=masquerade chain=srcnat out-interface=ether1 src-address-list="Local LAN"
add action=masquerade chain=srcnat comment="masquerade hotspot network" src-address=192.168.1.0/24
add action=masquerade chain=srcnat comment="masq. vpn traffic" src-address=192.168.89.0/24
add action=dst-nat chain=dstnat comment="Plex port forwarding" dst-port=32400 in-interface=ether1 protocol=tcp \
    to-addresses=192.168.1.18 to-ports=32400
Any help would be greatly appreciated.

Re: Plex port forwarding

Posted: Thu Nov 29, 2018 7:03 am
by 2frogs
What firewall filter rules do you have? Should have an accept rule for either port 32400 or for connection-nat-state=dst (or the default drop with connection-state-nat=!dst.) Are you double NATted?

Your NAT rule should work, although you do no need to specify the to-port unless you need to change the port to one different from external.
/ip firewall nat add action=dst-nat chain=dstnat comment="Plex port forwarding" dst-port=32400 in-interface=ether1 protocol=tcp to-addresses=192.168.1.18

Re: Plex port forwarding

Posted: Thu Nov 29, 2018 7:18 am
by VodoBaas1
Thank you for the help. My filter rule I added was moved to the top.
/ip firewall filter
add action=accept chain=forward dst-port=32400 protocol=tcp
I removed the port in NAT rule, so now it looks like:
add action=dst-nat chain=dstnat comment="Plex port forwarding" in-interface=ether1 protocol=tcp to-addresses=\192.168.1.18 to-ports=32400

Re: Plex port forwarding

Posted: Thu Nov 29, 2018 8:32 am
by 2frogs
I removed the port in NAT rule, so now it looks like:
add action=dst-nat chain=dstnat comment="Plex port forwarding" in-interface=ether1 protocol=tcp to-addresses=\192.168.1.18 to-ports=32400
No, you remove the wrong port. Your rule should be what I posted for you!
If that still does not work, make sure you have the set the port manually on Plex server and check firewall on host machine.

Re: Plex port forwarding

Posted: Thu Nov 29, 2018 9:21 am
by VodoBaas1
Ok, I changed the port so it's now:
/ip firewall nat add action=dst-nat chain=dstnat comment="Plex port forwarding" dst-port=32400 in-interface=ether1 protocol=tcp to-addresses=192.168.1.18
It still isn't working when I manually select the port. I checked windows firewall and don't see anything blocking it. I can connect but shows indirect and one other thing I see that I think is kind of weird, but maybe it's normal. When I look at wire shark I see that when I try to using remote access I see Plex trying to hit my other Plex server that is connected at my brothers house. I see his public IP as source and my private as destination and visa versa. I'm not sure if Plex checks with all shared servers at that time, but I thought

Re: Plex port forwarding

Posted: Thu Jan 10, 2019 10:47 pm
by anav
Two frogs is bang on for the NAT rule.....
/ip firewall nat add action=dst-nat chain=dstnat comment="Plex port forwarding" dst-port=32400 in-interface=ether1 protocol=tcp to-addresses=192.168.1.18

You need a filter firewall rule not specific to that server but to allow DST NAT to be functional on the router in general ( so get rid of the current filter rule )
/ip firewall filter
add action=accept chain=forward comment=\
"Allow Port Forwarding - DSTNAT" connection-nat-state=dstnat

The only thing you may consider adding to the Nat rule is an address or address list of allowed external WAN IPs, for added security.

If you are having port issues or conflicts, perhaps suggest you change the default port of the plex itself OR use port translation, where users come in on port whatever 61111 and the router directs it to 32400.

Re: Plex port forwarding

Posted: Thu Aug 01, 2019 4:19 pm
by jojodim
This did the trick in 30 seconds. Not sure why all of the above responses were so overly complicated.

http://www.icafemenu.com/how-to-port-fo ... router.htm

Re: Plex port forwarding

Posted: Thu Aug 01, 2019 7:53 pm
by anav
Probably because communication is a two way street!!

There is also this thread.........
viewtopic.php?f=13&t=148425