Hello Mikrtoik Community, I need your help.
I already have Mikrotik experience, but this is the first time I face this configuration, and so far, I’ve been unsuccessful.
Connection Diagram:
ISP->RB1200->Switch->N Customers
What I want to do:
I want to give each of my customers a /29.
My ISP gives me the following parameters:
WAN: 201.158.16.76/30
Gateway: 201.158.16.77
And I am configuring 201.158.16.78 for the RB1200.
They are also giving me the following IP segment to distribute between my customers:
201.158.19.0/24
How can I do this?
Customer 1: 201.158.19.16/29
Customer 2: 201.158.19.24/29
Ignore the switch for the moment; assume I am connecting my customers directly to the RB1200.
Use your own IP invalid ranges to do a peer to peer with your clients, for example:
p2p network for customer 1: 10.0.0.0/30
p2p network for customer 1: 10.0.0.4/30
So, you can do:
ISP<—>RB1200<—10.0.0.1/30---------10.0.0.2/30—> Customer 1
ISP<—>RB1200<—10.0.0.5/30---------10.0.0.6/30—> Customer 2
Settings for Customer 1:
ether1: 10.0.0.2/30
Default Gateway: 10.0.0.1
ether2:201.158.19.17/29
Settings for Customer 2:
ether1: 10.0.0.6/30
Default Gateway: 10.0.0.5
ether2: 201.158.19.25/29
Finally, you must to create the 2 routes on RB1200:
For Customer 1:
/ip route
add disabled=no distance=1 dst-address=201.158.19.16/29 gateway=10.0.0.2 scope=30 target-scope=10
For Customer 2:
/ip route
add disabled=no distance=1 dst-address=201.158.19.24/29 gateway=10.0.0.6 scope=30 target-scope=10
This will surely works for you.
it depends on what you are doing
if you are just routing between your customer and the ISP then you can just:
if there is no switch:
connect customer1 to ether1
ether1 address 201.158.19.17 and you tell your customer1 they have ip range 201.158.19.16/29 and gateway 201.158.19.17
the same goes for customer2 but with different ip addresses
just like your ISP did for you
if you have switch:
use VLANs on the switch