Solved

Can one router interface have two networks / subnets?

Posted on 2002-04-23
8
158 Views
Last Modified: 2013-12-07

Dear experts,

Would like to ask you guys,
is it possible to have two networks / subnets on one switch / hub connected to ONLY ONE router interface (eth0)?
The router would have routing entries for both networks / subnets.

The example is as below:

    (Network A) PC --|
                     |
                     |--- X (Router C) -- WAN -- X --- Net
                     |eth0
    (Network B) PC --|

Network A and B will need to talk to each other, as well
as outgoing to the WAN. Would the router have two IPs (1 from Network A, and 1 from Network B) for the one interface ? As I understand, normally there is only one network connected to one interface so I am wondering if more than 1 network/subnet can be put per interface.

Please advice if this can be done and why..
Thanks!

0
Comment
Question by:Haho
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
8 Comments
 
LVL 15

Accepted Solution

by:
samri earned 100 total points
ID: 6964653
Yes, it is possible.  Just assign an IP address from the 2nd network to the eth0 port on the router.

I'm not sure on the maximum number of secondary IP can be assign to an interface.  I believe it would be product specific.

In addition, I believe you need to establish proper routing in the router, so that it knows where to forward the packet to depending on the target network.

0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 6964989
Router C needs an IP from each network, then a network route using this IP, that's all
All PC on network A and B use Router C as default gateway.
0
 
LVL 16

Expert Comment

by:SteveJ
ID: 6965636
samri has given you the correct answer. In the Cisco world you'd simply add a secondary IP address, so the config would look like:

int e0/0
ip address 10.1.1.1 255.255.255.0
ip address 50.1.1.1 255.255.255.0 secondary


Steve
0
Why Off-Site Backups Are The Only Way To Go

You are probably backing up your data—but how and where? Ransomware is on the rise and there are variants that specifically target backups. Read on to discover why off-site is the way to go.

 
LVL 15

Expert Comment

by:samri
ID: 6966313
SteveJ:
Just q quick question; I remember somebody told me that there is a limit on Cisco on the number of secondary Ip that you could assign to an interface.

and.  you sounds like somebody I knew...

cheers.
0
 
LVL 16

Expert Comment

by:SteveJ
ID: 6966449
samri;

I've got 5 in addition to the primary on one router interface -- a VXR 7206 running 12.2(5). I run EIGRP and OSPF and I haven't had any problems that I could trace to the multiple IP address setup.

I would guess that the upper limit on IP addresses per interface would have something to do with how buffer space is allocated . . .


Haho;

I didn't include any routing config info because I dont know what routing protocols you are running. If you need more detail, post the router model/maker and which routing protocols you are using.

Good luck.
Steve
0
 
LVL 1

Author Comment

by:Haho
ID: 6970238
steve,

it is basically going to run static routing ...
the other interface is basically a WAN point-to-point link.
no problems is it?

Thanxs
0
 
LVL 1

Expert Comment

by:cheechew
ID: 6971166
Router normally allow you to put many ip on an interface. That seldom people come this limitation that affecting the implementation. Even can have many logical interfaces as well. That is what people doing on the colocation business. The limitation most likely will be the bandwitdh usage available on the interface itself.
0
 
LVL 16

Expert Comment

by:SteveJ
ID: 6971317
Haho,

You'll have no problems.

Good luck.
Steve
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

#Citrix #Citrix Netscaler #HTTP Compression #Load Balance
When it comes to security, there are always trade-offs between security and convenience/ease of administration. This article examines some of the main pros and cons of using key authentication vs password authentication for hosting an SFTP server.
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question