/ip firewall mangle
add action=mark-connection chain=input comment=ether1_conn disabled=no in-interface=LINK1 new-connection-mark=ether1_conn passthrough=yes
add action=mark-connection chain=input comment=ether2_conn disabled=no in-interface=LINK2 new-connection-mark=ether2_conn passthrough=yes
add action=mark-routing chain=output comment=to_ether1 connection-mark=ether1_conn disabled=no new-routing-mark=to_ether1 passthrough=no
add action=mark-routing chain=output comment=to_ether2 connection-mark=ether2_conn disabled=no new-routing-mark=to_ether2 passthrough=no
add action=accept chain=prerouting comment="fora load DST" disabled=no dst-address-list=sem_balance in-interface=LOCAL
add action=mark-connection chain=prerouting comment=ether1_conn disabled=no dst-address-type=!local in-interface=LOCAL new-connection-mark=\
ether1_conn passthrough=yes per-connection-classifier=both-addresses:2/0
add action=mark-connection chain=prerouting comment=ether2_conn disabled=no dst-address-type=!local in-interface=LOCAL new-connection-mark=\
ether2_conn passthrough=yes per-connection-classifier=both-addresses:2/1
add action=mark-routing chain=prerouting comment=to_ether1 connection-mark=ether1_conn disabled=no in-interface=LOCAL new-routing-mark=to_ether1 \
passthrough=no
add action=mark-routing chain=prerouting comment=to_ether2 connection-mark=ether2_conn disabled=no in-interface=LOCAL new-routing-mark=to_ether2 \
passthrough=no
/ip firewall nat
add action=masquerade chain=srcnat comment=to_ether1 disabled=no out-interface=LINK1
add action=masquerade chain=srcnat comment=to_ether2 disabled=no out-interface=LINK2
/ip route
add comment="BALANCEAMENTO DE CARGA - LINK1" disabled=no distance=1 dst-address=0.0.0.0/0 gateway=201.90.162.161 routing-mark=to_ether1 scope=30 target-scope=\
10
add comment="BALANCEAMENTO DE CARGA - LINK2" disabled=no distance=1 dst-address=0.0.0.0/0 gateway=189.22.8.1 routing-mark=to_ether2 scope=30 target-scope=10
add comment="LINK2 - TELEFONICA" disabled=no distance=2 dst-address=0.0.0.0/0 gateway=189.22.8.1 scope=30 target-scope=10
add comment="LINK1 - EMBRATEL" disabled=no distance=1 dst-address=0.0.0.0/0 gateway=201.90.162.161 scope=30 target-scope=10