Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Add a 2nd IP to an interface 1

Status
Not open for further replies.

TNGPicard

Technical User
Joined
Jun 23, 2003
Messages
153
Location
US
Howdy All,

I'd like to know if there is a way to assign a 2nd IP to an interface. In one of my sites, the consultant who setup the router made the router address 192.168.16.16/24. Ok, thats all fine and dandy except every other router in my network is 192.168.x.1/24. Unfortunately, I have some devices on my network which I can't easily change their IP properties on so if I just change the IP address of the ethernet side of the router, those devices won't work properly. I would like to slowly start migrating this site to use the same numbering scheme as my other sites (i.e. the router is .1) which will help me keep my sanity and makes training the non-techie folks on basic connectivity troubleshooting easier without the exceptions. I know I can create sub interfaces but if I do this don't I need to create two sub interfaces? one for the .1 and one for the .16 as when I create the sub interface, the IP on the "physical" interface goes away?


TNGPicard
 
I'm not following you...192.168.what.1???
router>en
router#conf t
router(config)#int fa0/0
router(config-if)#ip add 192.168.2.1 255.255.255.0 secondary

or

router(config-if)#no ip add
router(config-if)#no shut
router(config-if)#int fa0/0.1
router(config-subif)#ip add 192.168.1.1 255.255.255.0
router(config-subif)#exit
router(config)#int fa0/0.2
router(config-subif)#ip add 192.168.2.1 255.255.255.0

Burt
 
I think he would really like to change his router Ip to 192.168.16.1/24, but probably has a bunch of client devices with static configs and doesn't want to mess with them.

The easiest way is as burtsbees suggested:
[blue]router#conf t
router(config)#int fa0/0
router(config-if)#ip add 192.168.16.1 255.255.255.0 secondary
router(config-subif)#exit[/blue]


MCSE CCNA CCDA
 
That would make sense, but he says something about "192.168.x.1/24. ", and then he calls it the ".1"---the .1 in that address is the 4th octet, which is the host address, not the network. So it is a bit confusing...but what you say makes sense now.

Burt
 
Burt -


Sorry didn't mean to confuse you. What I was tryign to say is this

Site 1's Router: 192.168.4.1
Site 2's router: 192.168.5.1
....
Site 12's Router: 192.168.16.10

....where the number in the 4th octect just doesn't fit what would otherwise be a standard numbering pattern.

DearingKr: You're right about why I want to do this. Eventually I will have the static configuration changed but I need to call various vendors out to update the IP info in their equipment, so rather than pay a service call just for that, the next tiem I have them out for whatever I'll have it done then.


Thanks a bunch guys, I'll try the "secondary" word and see if that works!

TNGPicard
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top