LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 07-15-2004, 02:55 PM   #1
mephitic
Member
 
Registered: Aug 2003
Distribution: SuSE 9.0
Posts: 45

Rep: Reputation: 15
Question 2 IPs on 1 NIC


Hi,

I've a got a network here that was configured to have 12.110.x.x and 172.16.x.x on the same network. Don't asked just trust me ... Anyways I'm going into a linux box with this to route traffic to 2 additional networks 10.62.x.x and 192.168.x.x. Since 12.110.x.x and 172.16.x.x are on the same network is it possible to setup one NIC to do the job? There is no reason to have 2 cat5 cables plugged into the switch. The 12.110.x.x is our internet connection and the 172.16.x.x is an internal corporate network. I want to block incoming traffic on both of these with the firewalll which I can do. I just need to figure out how to add both IPs to one NIC!

Is it possible? If so how do I go about configing this?

Thanks!

** EDITIED 07/15/2004 @ 13:15 PST **
- I found I can do 'ifconfig eth0:1 172.16.x.x' and assign that to the already existing eth0 which is 12.110.x.x. However I can not ping this address. Although if the ip is on it's own NIC I can ping it. What gives?

** EDITIED 07/15/2004 @ 13:30 PST **
I get the following message in my firewall logs:

Jul 15 13:24:10 sunset kernel: SuSE-FW-ILLEGAL-TARGET IN=eth2 OUT= MAC=00:00:d1:f0:1c:cd:00:40:ca:70:29:83:08:00 SRC=x.x.x.x DST=x.x.x.x LEN=60 TOS=0x00 PREC=0x00 TTL=128 ID=24749 PROTO=ICMP TYPE=8 CODE=0 ID=512 SEQ=10240

I can however ping this virtual ip on the linux box and get a reply!?!?!

** EDITIED 07/15/2004 @ 13:51 PST **
DUH! forgot to edit the firewall! Doing some testing now to see if this works.

Last edited by mephitic; 07-15-2004 at 03:48 PM.
 
Old 07-16-2004, 03:51 PM   #2
mephitic
Member
 
Registered: Aug 2003
Distribution: SuSE 9.0
Posts: 45

Original Poster
Rep: Reputation: 15
This seems to work except on a reboot the changes are lost. Where do I add this so it starts back up on reboot?

Thanks!
 
Old 07-16-2004, 04:11 PM   #3
schoeppchen
LQ Newbie
 
Registered: Jul 2004
Posts: 29

Rep: Reputation: 15
What distro are you using?
 
Old 07-19-2004, 12:26 PM   #4
mephitic
Member
 
Registered: Aug 2003
Distribution: SuSE 9.0
Posts: 45

Original Poster
Rep: Reputation: 15
SuSE Pro 9.0
 
Old 07-19-2004, 12:53 PM   #5
nafsnipe685
LQ Newbie
 
Registered: Jan 2004
Location: Texas, USA
Distribution: Slackware 9
Posts: 19

Rep: Reputation: 0
the only way i can think of is to copy the config file and add a .bk at the end of the name, then when you reboot copy the .bk to the original file to replace the one just created by the bootup.
 
Old 07-19-2004, 01:11 PM   #6
Pete M
Member
 
Registered: Aug 2003
Location: UK
Distribution: Redhat 9 FC 3 SUSE 9.2 SUSE 9.3 Gentoo 2005.0 Debian Sid
Posts: 657

Rep: Reputation: 32
mephitic

This may help it's not specifically Suse, just general Linux

How-To

Pete
 
Old 07-19-2004, 02:39 PM   #7
mephitic
Member
 
Registered: Aug 2003
Distribution: SuSE 9.0
Posts: 45

Original Poster
Rep: Reputation: 15
Thanks Pete M that helped out alot!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
2 DHCP IPs, one NIC? lil_drummaboy Linux - Networking 1 10-24-2005 03:36 PM
Multiple IPs on one NIC - How to use them all? MG-Cloud Linux - Networking 4 10-03-2005 02:28 AM
multiple IPs, one NIC, different networks branden_burger Linux - Networking 3 03-15-2005 07:24 AM
multiple IPs, one nic v4lu3s Linux - Networking 4 02-07-2004 10:52 AM
multi ips on one nic EVIL_ted Linux - Networking 2 06-27-2003 03:49 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 02:35 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration