How to change a dynamic address into a it’s gateway in scripting? for example, I got a dynamic address 113.68.141.5,now I want to change it into its gateway form 113.68.141.1,how to acheive it in scripting? and how about change the address into the form like this 113.68.141.0/24?
I have a cable connection and my ISP offers me dynamic IP address. I was concerned if the DHCP client automatically add the option “Routing Mark” to the added default route, but is not possible…
This script is framed on my needs(I think), but does not want to work.
RouterOS 3.29
[max@core] /system script> run script1
bad argument name else (line 20 column 3)
[max@core] /system script>
you can also use a routing filter to apply a routing-mark to ‘dynamic-in’ routes. This only doesnt work when you have the need for more than 1 dhcp client.
add a routing-filter in the “dynamic-in” chain the uses set-routing-mark=“myroutingmark”.