Solved

Can one router interface have two networks / subnets?

Posted on 2002-04-23
8
154 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
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
 
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
Zoho SalesIQ

Hassle-free live chat software re-imagined for business growth. 2 users, always free.

 
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

Scale it in WD Gold

With up to ten times the workload capacity of desktop drives, WD Gold hard drives employ advanced technology to deliver among the best in reliability, capacity, power efficiency and performance.

Question has a verified solution.

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

#Citrix #Citrix Netscaler #HTTP Compression #Load Balance
ADCs have gained traction within the last decade, largely due to increased demand for legacy load balancing appliances to handle more advanced application delivery requirements and improve application performance.
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.
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

910 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

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now