You know how it goes... you roll up on a subscribers site to quickly install and find they are running a customized network with a bunch of equipment with static IP assignments.
Well, this is the article you need to address this, update the network settings and get the subscriber online quickly.
Let's assume for the purpose of this exercise, the subscriber is running a network of 172.16.1.0/24 with the gateway needing to be 172.16.1.254. The gateway you just put in defaults to 192.168.88.1. Here's how you'd go about updating this.
Firstly, login to the MikroTik using SSH, you can do this right from the Minim Care Portal.
First run: /ip address print
This will yield a result like this:
/ip address print
Flags: X - disabled, I - invalid, D - dynamic
# ADDRESS NETWORK INTERFACE
0 ;;; defconf
192.168.88.1/24 192.168.88.0 bridge
1 D 220.127.116.11/29 18.104.22.168 ether1
2 D 10.3.40.182/32 10.3.255.254 Minim-Speedtest
3 D 10.3.40.183/32 10.3.0.1 Minim-VPN
From here we need to identify the Number of the address that we want to change, in this case, it's 0 and we need to update the address and network settings.
To do this we run the following command to update the network details.
/ip address set address=NEWGATEWAY/24 network=NEWNETWORK numbers=NUMBER
So, in this case, to change 192.168.88.x to 172.16.1.x we would do this:
/ip address set address=172.16.1.254/24 network=172.16.1.254 numbers=0
Our network is now changed, so everything internally will now be broken as it's operating on the wrong network. To fix this, we need to update the DHCP-Server to give out the right addresses.
Running the following will show you current DHCP network settings
/ip dhcp-server network print
The result will look something like this:
Flags: D - dynamic
# ADDRESS GATEWAY DNS-SERVER WINS-SERVER DOMAIN
0 ;;; defconf
We will change this to our new network and gateway by running the following:
/ip dhcp-server network set address=NEWNETWORK/24 gateway=NEWGATEWAY numbers=IDENTITYOFDHCP
For our example, we're updating DHCP-Server with the identity of 0 so we would run this:
/ip dhcp-server network set address=172.16.1.0/24 gateway=172.16.1.254 numbers=0
The final setting we need to change is the pool of IPs our DHCP server will give out.
We can review what this is by running the following:
/ip pool print
And you'll see something like this:
# NAME RANGES
0 default-dhcp 192.168.88.10-192.168.88.200
Let's change this to give out addresses from 172.16.1.100 to 172.16.1.200.
Again, we need to have identified the number of the server we are changing, in this example above, it's 0.
/ip pool set ranges=172.16.1.100-172.16.1.200 numbers=0
And that's it!
Our gateway is now 172.16.1.254.
Our gateway gives out DHCP addresses between 172.16.1.100 and 172.16.1.200.
Our subscribers equipment will now work and their static assignments will all come online within a few seconds.