As Mikrotik to change Distance?

There are two WAN. For static I know how to set rules and by changing the Distance to make walking traffic from specific IP to specific WAN.

But as one of WANов we get the IP address via DHCP, the route in the IP Route List is generated automatically and there is written record with a Distance 0, respectively, the traffic goes through this route.

If I give them static for all WANов, then everything works. But I can't leave the statics as provider may change the settings and to start issuing a different IP via DHCP.

How can I change the Distance for dynamic route?

p.s. With scripts in Mikrotik I did not understand and they do not understand.
June 14th 19 at 20:17
2 answers
June 14th 19 at 20:19
Solution
/ip dhcp-client add add-default-route=yes default-route-distance=<1..255>
not only 255 and 1-254. 255 is a special type of distance, which indicates that the route is dead - Katlyn_Fritsch37 commented on June 14th 19 at 20:22
June 14th 19 at 20:21
Configure DHCP client in such a way that he hadn't added the default route and add a default route manually, and then change his Distance as you want.

Find more questions by tags Mikrotik