I have two ISPs connects
I want if isp one failed that isp2 take over.
ISP = 1 ip = dhcp client 192.168.0.5/24 ether1
ISP 2 = dhcp client ip = 10.98.247.144 ether2
Lan connection = 192.168.100.1/24 ether3
dhcp range = 192.168.100.2 to 192,168,100,254
Both nat actions settings to masquerade
I load here one picture from nat settings but isp1 is the same settings of isp2
I dont now how to set distance to 1 to isp2



Screenshots are not good for this, they leave stuff out.
Post the output of “/ip address print detail”, “/ip route print detail”, “/interface print”, “/ip firewall export”, and an accurate network diagram.
[admin@MikroTik] > ip firewall export
jan/02/1970 00:37:27 by RouterOS 5.4
software id = 5BDA-Q24F
/ip firewall connection tracking
set enabled=yes generic-timeout=10m icmp-timeout=10s tcp-close-timeout=10s
tcp-close-wait-timeout=10s tcp-established-timeout=1d tcp-fin-wait-timeout=
10s tcp-last-ack-timeout=10s tcp-syn-received-timeout=5s
tcp-syn-sent-timeout=5s tcp-syncookie=no tcp-time-wait-timeout=10s
udp-stream-timeout=3m udp-timeout=10s
/ip firewall nat
add action=masquerade chain=srcnat disabled=no out-interface=ether1____ISP1
add action=masquerade chain=srcnat disabled=no out-interface=ether2____ISP2
/ip firewall service-port
set ftp disabled=no ports=21
set tftp disabled=no ports=69
set irc disabled=no ports=6667
set h323 disabled=no
set sip disabled=no ports=5060,5061
set pptp disabled=no
[admin@MikroTik] > ip address print detail
Flags: X - disabled, I - invalid, D - dynamic
0 address=192.168.100.1/24 network=192.168.100.0 interface=ether3____Lan actual-interface=ether3____Lan
1 D address=10.98.247.150/28 network=10.98.247.144 interface=ether2____ISP2 actual-interface=ether2____ISP2
2 D address=192.168.0.5/24 network=192.168.0.0 interface=ether1____ISP1 actual-interface=ether1____ISP1
[admin@MikroTik] > ip route print detail
Flags: X - disabled, A - active, D - dynamic, C - connect, S - static, r - rip, b - bgp, o - ospf, m - mme, B - blackhole, U - unreachable, P - prohibit
0 ADS dst-address=0.0.0.0/0 gateway=10.98.247.145 gateway-status=10.98.247.145 reachable ether2____ISP2 distance=0 scope=30 target-scope=10 vrf-interface=ether2____ISP2
1 DS dst-address=0.0.0.0/0 gateway=192.168.0.1 gateway-status=192.168.0.1 reachable ether1____ISP1 distance=0 scope=30 target-scope=10 vrf-interface=ether1____ISP1
2 ADC dst-address=10.98.247.144/28 pref-src=10.98.247.150 gateway=ether2____ISP2 gateway-status=ether2____ISP2 reachable distance=0 scope=10
3 ADC dst-address=192.168.0.0/24 pref-src=192.168.0.5 gateway=ether1____ISP1 gateway-status=ether1____ISP1 reachable distance=0 scope=10
4 ADC dst-address=192.168.100.0/24 pref-src=192.168.100.1 gateway=ether3____Lan gateway-status=ether3____Lan reachable distance=0 scope=10
[admin@MikroTik] > interface print
Flags: D - dynamic, X - disabled, R - running, S - slave
NAME TYPE MTU L2MTU MAX-L2MTU
0 R ether1____ISP1 ether 1500 1526
1 R ether2____ISP2 ether 1500 1524 1524
2 R ether3____Lan ether 1500 1524 1524
3 ether4 ether 1500 1524 1524
4 ether5 ether 1500 1524 1524
[admin@MikroTik] >

Because they are both DHCP you can’t set the distance. The routes are dynamic, and there is no way to influence the administrative distance.
Thanks for your quick answer.
there is a possibility if I ip’s of the two ISPs make static?
Yes. Then you are able to set the distance manually.

Whoops.
Ok, thanks, i try it out.
you are a great help to me.