Community discussions

 
lok
just joined
Topic Author
Posts: 4
Joined: Mon Jun 24, 2019 11:32 pm

Two IPs each on separate port

Mon Jun 24, 2019 11:37 pm

Hey guys.

I have a question. I bought a MikroTik router for home and I have got two IP address from my internet provider. DHCP
Both IPs are in the same subnet.
My needs are to assign each IP address to separate Ethernet port. Could someone shed some light on this, please?
 
lok
just joined
Topic Author
Posts: 4
Joined: Mon Jun 24, 2019 11:32 pm

Re: Two IPs each on separate port

Wed Jun 26, 2019 7:13 pm

Seems like a not very active community. :(
 
User avatar
sebastia
Forum Guru
Forum Guru
Posts: 1795
Joined: Tue Oct 12, 2010 3:23 am
Location: Antwerp, BE

Re: Two IPs each on separate port

Wed Jun 26, 2019 11:59 pm

Hi

These ip's are from two different modems? what is the wiring / network configuration?
 
lok
just joined
Topic Author
Posts: 4
Joined: Mon Jun 24, 2019 11:32 pm

Re: Two IPs each on separate port

Sat Jul 06, 2019 3:08 am

Hi

These ip's are from two different modems? what is the wiring / network configuration?
Hi. thank You for input.
No its just one and that same internet provider.
Photo 06-07-2019, 03 02 46.jpg
In 1 port I have In cable from Internet provider.
In Second port I have my workstation PC. I would like to leave it as it is now, DHCP address - Same I would like to leave wireless connection as well what currently gets DHCP IP.

But in third port I have Connected my server. So I would like to get separate IP address working on this port.

I have got two IPs

136.169.26.41
136.169.26.42

41 IP would work as main IP for DHCP server therefore for port 2 port 4 and 5 + wireless connection.
And 42 IP address would work directly from port 3. No need DHCP there.

Is that something possible ?

Thanks
You do not have the required permissions to view the files attached to this post.
 
User avatar
sebastia
Forum Guru
Forum Guru
Posts: 1795
Joined: Tue Oct 12, 2010 3:23 am
Location: Antwerp, BE

Re: Two IPs each on separate port

Sat Jul 06, 2019 10:47 pm

Hey, there is no easy software solution to this, see viewtopic.php?f=2&t=149920 with same question.
 
Sob
Forum Guru
Forum Guru
Posts: 4812
Joined: Mon Apr 20, 2009 9:11 pm

Re: Two IPs each on separate port

Sat Jul 06, 2019 11:58 pm

It doesn't look like same thing. The problem in other thread is when router itself should get multiple addresses from ISP's DHCP server.

In this case, if server should get the other address, simply bridging ether1 and ether3 should do the trick. Newly created bridge will serve as new WAN interface for router.
People who quote full posts should be spanked with ethernet cable. Some exceptions for multi-topic threads may apply.
 
User avatar
sebastia
Forum Guru
Forum Guru
Posts: 1795
Joined: Tue Oct 12, 2010 3:23 am
Location: Antwerp, BE

Re: Two IPs each on separate port

Sun Jul 07, 2019 12:50 am

Possible, not sure if server should be shielded / natted... If not then indeed, that will suffice.
 
mkx
Forum Guru
Forum Guru
Posts: 3214
Joined: Thu Mar 03, 2016 10:23 pm

Re: Two IPs each on separate port

Sun Jul 07, 2019 11:06 am

Server can be shielded by configuring use-ip-firewall=yes on WAN bridge. It will affect the LAN<->server connections though (at least performance-wise).
BR,
Metod
 
craigreilly
newbie
Posts: 42
Joined: Mon Jan 26, 2015 7:04 pm

Re: Two IPs each on separate port

Tue Jul 09, 2019 11:24 pm

viewtopic.php?f=13&t=149603&p=738962#p738500 is the way to go...

Or - protect the server by using NAT and only allow the ports that should be passed thru (ie: 80)
 
lok
just joined
Topic Author
Posts: 4
Joined: Mon Jun 24, 2019 11:32 pm

Re: Two IPs each on separate port

Wed Jul 17, 2019 1:35 am

It doesn't look like same thing. The problem in other thread is when router itself should get multiple addresses from ISP's DHCP server.

In this case, if server should get the other address, simply bridging ether1 and ether3 should do the trick. Newly created bridge will serve as new WAN interface for router.
Well I guess I have same way. ISPs have DHCP server and Instead of one IP address I have two available. Only problem is to how to get them to work on my one Mikrotik router.
I have tried Your suggestions but failed, as it seems ETH1 can not be added in bridge. And It already is added in some kind of bridge. But it was default, nothing is configured yet.

Image

Thank you for input
 
Sob
Forum Guru
Forum Guru
Posts: 4812
Joined: Mon Apr 20, 2009 9:11 pm

Re: Two IPs each on separate port

Wed Jul 17, 2019 2:26 am

If it's default config, then ether1 (WAN) should be separate port and the rest should be in bridge (as LAN).

If the solution with server getting public address directly would work for you, you need to remove server port (ether3) from LAN bridge and add it together with current WAN (ether1) to new bridge which will become your new WAN port. But it will also mean that server won't be part of your LAN anymore. Unless you add another connection using either second network adapter or VLAN.

If you'd rather have the second public address on router too and use NAT, then it's same problem as in thread linked by sebastia. In that case it's possible to use VRRP hack, which may not be the prettiest solution but should work.
People who quote full posts should be spanked with ethernet cable. Some exceptions for multi-topic threads may apply.

Who is online

Users browsing this forum: No registered users and 40 guests