How can i add an extra ip (the server already has one ip now) to fedora 6 in command line?

Thanks!

link|improve this question

feedback

3 Answers

If you are looking for a command line version try:

 ip addr add 10.1.1.1/24 dev eth0

These setting are temporary and they will be lost on next reboot.

link|improve this answer
feedback

You can add a virtual IP address, otherwise, you'll need to add an extra NIC and assign it an IP address.

Tutorial on adding a Virtual IP address: LINK

For adding a NIC and assigning it an IP address, look under System > Network Configuration or something like that. In command line run: system-config-network. You might need to install the Administration Tools group.

link|improve this answer
Thanks, but here is my ifcfg-ech0: DEVICE=eth0 BOOTPROTO=dhcp TYPE=Ethernet ONBOOT=yes i don't see a "IPADDR=" field – Weiwei Aug 28 '09 at 2:25
You have it set to DHCP. You'll have to follow the tutorial some. It shows you want you want to put in your config. Copy it from the tutorial and use it as you need it. – Dave Rickman Aug 28 '09 at 2:50
feedback

I will have two static ips as 77.78.8.111 and 77.78.8.89

I will have this configure:

DEVICE=eth0:0
BOOTPROTO=static
IPADDR=77.78.8.111
BROADCAST = ???????
NETWORK=????
NETMASK=255.255.255.0
TYPE=Ethernet
ONBOOT=yes

and

DEVICE=eth0:1
BOOTPROTO=static
IPADDR=77.78.8.89
BROADCAST = ??????
NETWORK=????
NETMASK=255.255.255.0
TYPE=Ethernet
ONBOOT=yes

What value would for BROADCAST and NETMASK ?

this if the ifconfig output:

-------------
eth0      Link encap:Ethernet  HWaddr 00:19:99:0D:CC:14
          inet addr:77.78.8.89  Bcast:77.78.8.89  Mask:255.255.255.255
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:509 errors:0 dropped:0 overruns:0 frame:0
          TX packets:473 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:72383 (70.6 KiB)  TX bytes:195760 (191.1 KiB)
          Interrupt:23 Base address:0xe000

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

------
link|improve this answer
You have two external IP addresses, how are you plugging in the second one? Do you have two NICs as well? – Dave Rickman Aug 28 '09 at 9:48
no , only one NIC – Weiwei Aug 28 '09 at 16:27
use the 'ipcalc' utility – cstamas Sep 11 '09 at 18:53
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.