Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Can one router interface have two networks / subnets?

Posted on 2002-04-23
8
Medium Priority
?
162 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 400 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
Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

 
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

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

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

Most of the applications these days are on Cloud. Cloud is ubiquitous with many service providers in the market. Since it has many benefits such as cost reduction, software updates, remote access, disaster recovery and much more.
Originally, this post was published on Monitis Blog, you can check it here . It goes without saying that technology has transformed society and the very nature of how we live, work, and communicate in ways that would’ve been incomprehensible 5 ye…
Internet Business Fax to Email Made Easy - With  eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, f…
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.
Suggested Courses

916 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