Hello everyone maybe someone can help me on my fail-over script.
Problem: after I setup failover script from https://help.mikrotik.com/docs/pages/viewpage.action?pageId=26476608 there is no internet on lan side.
Here’s my script:
# 2023-07-05 05:21:51 by RouterOS 7.10.1
# software id =
#
# model = RB750Gr3
# serial number =
/interface bridge
add name=bridge-lan
/interface ethernet
set [ find default-name=ether1 ] name=ether1-isp
set [ find default-name=ether2 ] name=ether2-isp
set [ find default-name=ether3 ] name=ether3-lan
set [ find default-name=ether4 ] name=ether4-lan
set [ find default-name=ether5 ] name=ether5-lan
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip hotspot profile
set [ find default=yes ] html-directory=hotspot
/ip pool
add name=pool-lan ranges=192.168.97.7-192.168.97.17
/ip dhcp-server
add address-pool=pool-lan interface=bridge-lan name=dhcp-lan
/port
set 0 name=serial0
/queue type
add kind=fq-codel name=fq-codel-default
add kind=cake name=cake-default
/routing table
add fib name=to_ISP1
add fib name=to_ISP2
/interface bridge port
add bridge=bridge-lan interface=ether3-lan
add bridge=bridge-lan interface=ether4-lan
add bridge=bridge-lan interface=ether5-lan
/ip address
add address=192.168.97.1/27 interface=bridge-lan network=192.168.97.0
/ip dhcp-client
add add-default-route=no interface=ether1-isp use-peer-dns=no use-peer-ntp=no
add add-default-route=no interface=ether2-isp use-peer-dns=no use-peer-ntp=no
/ip dhcp-server network
add address=192.168.97.0/27 gateway=192.168.97.1
/ip dns
set servers=1.1.1.1,8.8.8.8
/ip firewall mangle
add action=mark-routing chain=output connection-mark=ISP1_conn \
new-routing-mark=to_ISP1 out-interface=ether1-isp passthrough=yes
add action=mark-routing chain=output connection-mark=ISP2_conn \
new-routing-mark=to_ISP2 out-interface=ether2-isp passthrough=yes
add action=mark-connection chain=output connection-mark=no-mark \
connection-state=new new-connection-mark=ISP1_conn out-interface=\
ether1-isp passthrough=yes
add action=mark-connection chain=output connection-mark=no-mark \
connection-state=new new-connection-mark=ISP2_conn out-interface=\
ether2-isp passthrough=yes
/ip firewall nat
add action=masquerade chain=srcnat out-interface=ether1-isp
add action=masquerade chain=srcnat out-interface=ether2-isp
/ip route
add dst-address=1.1.1.1 gateway=192.168.101.1 scope=10
add dst-address=8.8.8.8 gateway=192.168.1.1 scope=10
add check-gateway=ping distance=1 gateway=1.1.1.1 routing-table=to_ISP1 \
target-scope=11
add check-gateway=ping distance=2 gateway=8.8.8.8 routing-table=to_ISP1 \
target-scope=11
add check-gateway=ping distance=1 gateway=1.1.1.1 routing-table=to_ISP2 \
target-scope=11
add check-gateway=ping distance=2 gateway=8.8.8.8 routing-table=to_ISP2 \
target-scope=11
add dst-address=1.1.1.1 gateway=192.168.101.1 scope=10
add dst-address=208.67.222.222 gateway=192.168.101.1 scope=10
add dst-address=8.8.8.8 gateway=192.168.1.1 scope=10
add dst-address=208.67.220.220 gateway=192.168.1.1 scope=10
add check-gateway=ping dst-address=10.10.10.1 gateway=1.1.1.1 scope=10 \
target-scope=11
add check-gateway=ping dst-address=10.10.10.1 gateway=208.67.222.222 scope=10 \
target-scope=11
add check-gateway=ping dst-address=10.20.20.2 gateway=8.8.8.8 scope=10 \
target-scope=11
add check-gateway=ping dst-address=10.20.20.2 gateway=208.67.220.220 scope=10 \
target-scope=11
add distance=1 gateway=10.10.10.1 routing-table=to_ISP1 target-scope=12
add distance=2 gateway=10.20.20.2 routing-table=to_ISP1 target-scope=12
add distance=1 gateway=10.20.20.2 routing-table=to_ISP2 target-scope=12
add distance=2 gateway=10.10.10.1 routing-table=to_ISP2 target-scope=12
/system note
set show-at-login=no
/tool netwatch
add disabled=no down-script="" host=8.8.8.8 http-codes="" test-script="" \
type=icmp up-script=""
add disabled=no down-script="" host=1.1.1.1 http-codes="" test-script="" \
type=icmp up-script=""
add disabled=no down-script="" host=208.67.222.222 http-codes="" test-script=\
"" type=icmp up-script=""
add disabled=no down-script="" host=208.67.220.220 http-codes="" test-script=\
"" type=icmp up-script=""