Hi! i would like to know, if n1 already done a script to add a lot of private /30 subnets gateway for exemplo
10.0.0.1/30
10.1.0.1/30
10.2.0.1/30
10.x.x.1/30
and then add a dhcp network and pool for each subnet automaticaly?
thanks!
Hi! i would like to know, if n1 already done a script to add a lot of private /30 subnets gateway for exemplo
10.0.0.1/30
10.1.0.1/30
10.2.0.1/30
10.x.x.1/30
and then add a dhcp network and pool for each subnet automaticaly?
thanks!
Just use two for loops to generate that:
Something like this:
:for i from=0 to=255 do={
:for j from=0 to=255 do={
:put (“IP: 10.” . $i . “.” . $j . “.1/30”);
}
}
thanks !!!
thats the code i used to do here!
now i’m working on to create automaticaly dhcp pools for each subnet!
:for i from=0 to=255 do={/ip address add address=(“10.” . $i
. “.” . 1 . “.1/30”) interface=lan}