Setup:
FTTH Optical Network Unit (ONU) is set to bridge mode with IP address 192.168.0.1
Asus Router has IP address: 192.168.1.1
OBJECTIVE: I need to access the ONU from my computers connected to the Asus router.
I've had a Linksys router flashed with Tomato. I can always access the ONU by adding this script in the firewall setting of Tomato for years now:
iptables -I POSTROUTING -t nat -o vlan1 -d 192.168.0.0/30 -j MASQUERADE
ip addr add 192.168.0.2/30 dev vlan1 brd +
But when I add the same script in 'firewall-start' in RMerlin, it won't work:
#!/bin/sh
iptables -I POSTROUTING -t nat -o vlan1 -d 192.168.0.0/30 -j MASQUERADE
ip addr add 192.168.0.2/30 dev vlan1 brd +
I can replicate this by switching from my Linksys router and my current Asus router.
Can someone help, with the correct way to do it, please? Thanks!
FTTH Optical Network Unit (ONU) is set to bridge mode with IP address 192.168.0.1
Asus Router has IP address: 192.168.1.1
OBJECTIVE: I need to access the ONU from my computers connected to the Asus router.
I've had a Linksys router flashed with Tomato. I can always access the ONU by adding this script in the firewall setting of Tomato for years now:
iptables -I POSTROUTING -t nat -o vlan1 -d 192.168.0.0/30 -j MASQUERADE
ip addr add 192.168.0.2/30 dev vlan1 brd +
But when I add the same script in 'firewall-start' in RMerlin, it won't work:
#!/bin/sh
iptables -I POSTROUTING -t nat -o vlan1 -d 192.168.0.0/30 -j MASQUERADE
ip addr add 192.168.0.2/30 dev vlan1 brd +
I can replicate this by switching from my Linksys router and my current Asus router.
Can someone help, with the correct way to do it, please? Thanks!
Last edited: