Page 1 of 1

Make external IP address accessible on secondary port

Posted: Thu Apr 18, 2019 12:16 pm
by moorenproductief
Hello,

I want to put two mikrotik routers in a chain. My ISP provides me an ip block and I need that each router has his OWN EXTERNAL IP. The reason that I want to chain the routers is that I need to control and monitor the bandwidth of the secondary router. Is such a thing possible on routerOS? And if yes... How? I have been googeling and experimenting for quit some time now. Thanks for any response!

I added a diagram so my situation becomes more clear.
Marco
chained routers.png

Re: Make external IP address accessible on secondary port

Posted: Thu Apr 18, 2019 5:00 pm
by McSee
I can't verify myself if it works this way but you may want to try -

on first mikrotik
- set up "bandwidth controlled port" as a separate interface
- then execute "/ip address add address=xx.xx.xx.98/32 interface="bandwidth controlled port" network=xx.xx.xx.99"

on the second
- set up xx.xx.xx.99/29 address
- add default route using xx.xx.xx.98 as a gateway

Re: Make external IP address accessible on secondary port

Posted: Thu Apr 18, 2019 10:09 pm
by Sob
^^^^ This works, but:

1) Use the same /32 addressing on second router too, only with swapped addresses. Because the whole /29 won't be available at that port.

2) You also need on first router:
/ip arp
add address=xx.xx.xx.99 interface=<WAN> published=yes
3) Make sure that you will allow forwarding to/from xx.xx.xx.99 on first router.

Re: Make external IP address accessible on secondary port

Posted: Fri Apr 19, 2019 2:51 pm
by gotsprings
Put a dumb switch infront of the two Mikrotiks. $30 or less.

Re: Make external IP address accessible on secondary port

Posted: Fri Apr 19, 2019 5:43 pm
by Sob
Dumb switch and both routers being independent won't go well with the requirement to control other router's bandwidth (on first router, as I undertand it).

Re: Make external IP address accessible on secondary port

Posted: Fri Apr 19, 2019 10:19 pm
by gotsprings
Dumb switch and both routers being independent won't go well with the requirement to control other router's bandwidth (on first router, as I undertand it).
Which should be done per router.

But let's face it... This could / should all be done on one router.

Re: Make external IP address accessible on secondary port

Posted: Sun Apr 21, 2019 2:14 am
by excession
You could bridge two ports together and feed your WAN into one of these. Then set one of your external IPs on this bridge, plug your next router into the other port and set another of your external IPs on that routers interface.

You can then enable the IP firewall in Bridge Settings on the first router which will allow you to use simple queues on this router to shape traffic on the next router. I think this setup is called something like transparent traffic shaping in the wiki if you want to search for it.

Finally setup a simple queue to shape the traffic of the next router by targeting it’s external IP.

Re: Make external IP address accessible on secondary port

Posted: Thu May 30, 2019 3:56 pm
by moorenproductief
Thank you all for relying! For some reason I dit not receive any updates on this post by email so I was thinking there were no replies at all.
Next week I'm gonna try all suggestions and will reply which one works best for me.

Re: Make external IP address accessible on secondary port

Posted: Thu May 30, 2019 4:30 pm
by anav
I'm with got springs on this one. Could and should be done on one router. Anything else is overly complex.