Tuesday, April 13, 2010

Set multiple IPs in single nic.

Hello guys...
Ever wondered how to set multiple IPs in a single network card? Here is the solution.

Multiple IP binded in a single network card allows you run different services in different IPs, for example you can run HTTP on one IP and SMTP on another IP or a private LAN using a local IP and the alias holding your Public IP. The major benifit here is that you do not need an additional physical adaptor, you can bind many virtual IPs to a single network card. Here I have explained the procedure for creating multiple IPs for RedHat based and Debian bases systems

Redhat based systems.

Let me assume that your NIC is bound with a static IP address. Go to the folder /etc/sysconfig/network-scripts/, there you will find your network configuration files.

# cd /etc/sysconfig/network-scripts/

Let me also guess that your machine has only one network card (can be onboard too!!!), then you will find a file ifcfg-eth0 in the folder. This file holds the IP information for the first nic. If your machine has more nics you will have ifcfg-eth1, ifcfg-eth2 and so on... Now open the ifcfg-eth0 file, you can view the network configuration as below:

# cat ./ifcfg-eth0# File: ifcfg-eth0


DEVICE=eth0
ONBOOT=yes
BOOTPROTO=static
IPADDR=192.168.1.120
NETMASK=255.255.255.0
BROADCAST=192.168.1.255
NETWORK=192.168.1.0
HWADDR=xx:xx:xx:xx:xx:xx


Now to bind another IP address to the same network card, you just have to copy the ifcfg-eth0 file to ifcfg-eth0:1.
 
# cp ./ifcfg-etho ./ifcfg-eth0:1

RHEL 5.5 Released

Yea guys, the Red Hat Inc. has launched its 5th iteration of the Red Hat Enterprise Linux 5, RHEL 5.5 on March 29, 2010. There is no doubt that it would be a great release.


Added Hardware support in RHEL 5.5
It features support for modern Intel Nehalem EX, AMD Opteron 6000 amd IBM Power 7 processor based servers. These processors above specified are the promissing releases from said vendors. Intel has just released the Nehalam EX series in the same week and the other two, AMD Opteron 6000 series and Power 7 from IBM were released in last February 2010. Opteron 6000 series processosr boasts of 12 cores and IBM has equipped their Power7 with eight cores.