Page 1 of 1

script for simple failover

Posted: Sat Jan 18, 2025 8:22 am
by rajendrar2
is it possible to write a script in routeros that ether 1 will ping to 192.168.1.1 if ping is successful ether 2 will be disabled if ping fails then only ether 2 will be enabled if ether 1 succeeds to ping 192.168.1.1 then ether 2 disables again ether 3 will be lan port and all 3 will be in bridge mode.

Re: script for simple failover

Posted: Sat Jan 18, 2025 10:53 am
by panisk0
use
/tool/netwatch set up-script=.... down-script=.....
&
/ping interface=ether......

Re: script for simple failover

Posted: Sat Jan 18, 2025 12:23 pm
by FRANKMUNOZAPURE
It is impossible for the "WAN and LAN" ports to be on a single bridge sir.

Re: script for simple failover

Posted: Sat Jan 18, 2025 10:28 pm
by Liiina
It is impossible for the "WAN and LAN" ports to be on a single bridge sir.
why not, if, for example, the provider provides pppoe, then you can easily add the entire port to the bridge.

Re: script for simple failover

Posted: Sat Jan 18, 2025 10:52 pm
by BartoszP
You can easily add it. Yes, however your LAN starts to leak data to the physical WAN port (not the ppoe) so your LAN traffic would be visible to the ISP infrastructure unless they block it.