Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 03-30-2003, 07:25 AM   #1
LQ Newbie
Registered: Mar 2003
Distribution: slackware
Posts: 4

Rep: Reputation: 0
how to add / bind ip addresses to one box on slackware ?

I have slackware box and my ISP gave me 16 ip addresses to use for my box.

wondering how to bind multi ip addresses on the slackware

so http server can use one ip and other service can use one diff ip.


Old 03-30-2003, 07:39 AM   #2
LQ Newbie
Registered: Mar 2003
Distribution: Mandrake
Posts: 12

Rep: Reputation: 0
U can do an alias

ifconfig --help shoud give you some idea.
Old 03-30-2003, 09:25 AM   #3
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,696

Rep: Reputation: 232Reputation: 232Reputation: 232
For example:
ifconfig eth0:1
Old 03-30-2003, 12:11 PM   #4
LQ Newbie
Registered: Mar 2003
Distribution: Gentoo
Posts: 7

Rep: Reputation: 0
I have a server that I run that hosts multiple IPs and this is how I bind the IP addresses to my server. Since I only have one ethernet card, I have to create virtual hosts on eth0.

You can use ifconfig to add them to your network. In my /etc/rc.d/rc.local, I have the following (so it starts up and adds them everytime):

/sbin/ifconfig eth0:0 <ip> netmask <netmask> up
/sbin/ifconfig eth0:1 <ip> netmask <netmask> up
/sbin/ifconfig eth0:2 <ip> netmask <netmask> up
/sbin/ifconfig eth0:3 <ip> netmask <netmask> up

Where <ip> and <netmask> are the IP and netmask, respectively.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
bind 2 ip addresses to the server txm123 Linux - Newbie 2 11-08-2004 12:31 PM
Missing IP addresses BIND 9 rdavis@intdoc.c Linux - Networking 0 07-01-2004 09:18 AM
Bind Multi IP addresses to a single NIC sitg Linux - Networking 2 04-30-2004 08:59 PM
How to add IP addresses nigeledge Linux - Networking 5 04-16-2004 05:25 AM
2 IP addresses on the same Linu box Zingaro2002 Linux - Networking 11 02-26-2003 05:49 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:56 AM.

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