Fedora Linux Support Community & Resources Center
  #1  
Old 28th May 2006, 07:32 PM
darkchemist Offline
Registered User
 
Join Date: May 2006
Posts: 7
multiple ip addresses + one NIC?

hello, i have a game server where there is 7 IP's total going into this box. I have one NIC, and it is only assigning the first ip (xxx.xxx.xxx.30)in my pool of addresses give to that box. I need this box to have acess to all 7 IP's
Quote:
xxx.xxx.xxx.31
xxx.xxx.xxx.32
xxx.xxx.xxx.33
xxx.xxx.xxx.34
xxx.xxx.xxx.193
xxx.xxx.xxx.194
Is there an easy command line way to do this? i only have SSH acess to this machine so the gui is of no use to me.

thankyou!
-matt
Reply With Quote
  #2  
Old 28th May 2006, 08:59 PM
Brian1 Offline
Registered User
 
Join Date: Nov 2004
Location: Seymour, Indiana
Posts: 2,509
Each addtional IP will be an Alising IP called eth0:0, eth0:1, eth0:2, and so on.
Check out this site on Alising IP setup

https://www.redhat.com/archives/fedo.../msg04163.html
http://www.faqs.org/docs/Linux-mini/IP-Alias.html

There are serval other links. Just use google and search for Alias IP

Brian1
__________________
Distribution: RHEL 5.1 with Pieces of this and that.
Kernel 2.6.23.9, KDE 3.5.8 and KDE 4.0 beta, Plus Development src.rpm, ATI fglrx64_7_1_0-8.433-1 rpm with 3D and DRI working.
Acer 5100-5840 with webcam, ati, sdcard reader, sound, atheros based wireless, all working. Only thing not working is the memory stick reader.
Reply With Quote
  #3  
Old 28th May 2006, 09:52 PM
darkchemist Offline
Registered User
 
Join Date: May 2006
Posts: 7
thankyou for your reply, and i DID figure out how to get the ip's to work with IP aliasing, however...

it said to place the script:
Quote:
#setting up IP alias interfaces
echo "Setting 69.28.221.31, 69.28.221.32, 69.28.221.33, 69.28.221.34, 69.28.221.193, 69.28.221.194 IP Aliases ..."
/sbin/ifconfig eth0:0 69.28.221.31
/sbin/ifconfig eth0:1 69.28.221.32
/sbin/ifconfig eth0:2 69.28.221.33
/sbin/ifconfig eth0:4 69.28.221.34
/sbin/ifconfig eth0:5 69.28.221.193
/sbin/ifconfig eth0:6 69.28.221.194
in the "/etc/rc.d/rc.local" file to auto config the card to work, however it will not auto start on boot.

if i just type in "/sbin/ifconfig eth0:0 69.28.221.31" it loads without problem.

How can i tell that the rc.local file is being read at boot?
Reply With Quote
  #4  
Old 28th May 2006, 10:41 PM
Brian1 Offline
Registered User
 
Join Date: Nov 2004
Location: Seymour, Indiana
Posts: 2,509
Do you see the echo line on boot?
If so does any of the virtual IP get created?
Are these IP's a simple nat1to1 or are they given to you in a segment of a class C address?
I assume eth0 works fine.

Brian1
__________________
Distribution: RHEL 5.1 with Pieces of this and that.
Kernel 2.6.23.9, KDE 3.5.8 and KDE 4.0 beta, Plus Development src.rpm, ATI fglrx64_7_1_0-8.433-1 rpm with 3D and DRI working.
Acer 5100-5840 with webcam, ati, sdcard reader, sound, atheros based wireless, all working. Only thing not working is the memory stick reader.
Reply With Quote
  #5  
Old 28th May 2006, 11:16 PM
darkchemist Offline
Registered User
 
Join Date: May 2006
Posts: 7
I do not have acess to see the machine boot, so im not sure if it echo;s the info.

They are nat1to1

really all that i need is for the server to run /sbin/ifconfig eth0:0 69.28.221.31 for each of the ip's needed on boot. but im not sure that the rc.local file is being ran on boot
Reply With Quote
  #6  
Old 29th May 2006, 12:01 AM
Brian1 Offline
Registered User
 
Join Date: Nov 2004
Location: Seymour, Indiana
Posts: 2,509
I would think your /var/log/messages would contain the info if started. I think the echo will show up in there.
Do you have anything else in rc.local that you know is running?
You can put say ' cp /etc/fstab to /home/<username>/fstab ' in your rc.local. Once booted you can see if rc.local did run.

Brian1
__________________
Distribution: RHEL 5.1 with Pieces of this and that.
Kernel 2.6.23.9, KDE 3.5.8 and KDE 4.0 beta, Plus Development src.rpm, ATI fglrx64_7_1_0-8.433-1 rpm with 3D and DRI working.
Acer 5100-5840 with webcam, ati, sdcard reader, sound, atheros based wireless, all working. Only thing not working is the memory stick reader.
Reply With Quote
Reply

Tags
addresses, multiple, nic

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Multiple ip addresses same card frharris27 Servers & Networking 2 9th May 2006 09:28 PM
Multiple MAC addresses to one NIC nosupport Servers & Networking 8 22nd April 2006 02:41 AM
shortcut for adding multiple IP addresses? tommy916 Servers & Networking 0 20th March 2006 11:40 PM
Multiple MAC addresses? Badger Servers & Networking 3 10th June 2004 04:55 AM


Current GMT-time: 15:29 (Tuesday, 22-07-2014)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat