What's new

Curious behaviour after opening ports with iptables - RTAX86U - Asus Wrt Merlin

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

juanantonio

Regular Contributor
Good afternooon everyone.

I needed opening port 8123 on my RT-AX86U. I did in the way I already have more than a dozen open ports, which I learned from @ZebMcKayhan , (Thanks mate!).

The thing is:

The port shows as open on https://www.connected.app/port-checker, as seen on image:

1734965190297.png


Also, the counters are not zero on my iptables command:

Code:
juanantonio@RT-AX86U-6C38:/jffs/scripts# iptables -nvL -t nat | grep 8123
   11   644 DNAT       tcp  --  wgc1   *       0.0.0.0/0            0.0.0.0/0            tcp dpt:51821 to:192.168.1.213:8123
juanantonio@RT-AX86U-6C38:/jffs/scripts#

So, the thing works at the beginning. But, after a while (I don't know how much time is, several minutes), the port appears to close magically and the only thing that solve the issue is restarting the firewall, as follows:

Bash:
juanantonio@RT-AX86U-6C38:/jffs/scripts# service restart_firewall

Done.
juanantonio@RT-AX86U-6C38:/jffs/scripts#

So, for making this change permanent, the only thing I could thought of was creating a cron job, so I didn't need to lauch the command every so and then, in order to make my Home Assistant accesible to the mobile app (it is called companion).

Bash:
juanantonio@RT-AX86U-6C38:/jffs/scripts# cru l
*/5 * * * * service restart_firewall>/tmp/log_firewall #rst_firewall#
juanantonio@RT-AX86U-6C38:/jffs/scripts#

My question is: Is there any other way to achieve this connectivity from the mobile app to the server which avoid this constant restarting of the firewall? I don't believe this is a normal behaviour.

Thanks in advance.
 
Last edited:
Similar threads
Thread starter Title Forum Replies Date
el_pedr0 Please harmonise killswitch behaviour Asuswrt-Merlin 1

Similar threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!

Staff online

Top