I want to have two IPs sharing the same interface and it's just working fine by creating a virtual interface using the following command (
eth0 is my original interface):
ifconfig eth0:0 <someip> netmask <somenetmask>
It works fine and I can see it using
ifconfig until I restart the system.
So, I did create
/etc/sysconfig/network-scripts/ with this content:
DEVICE=eth0:0 IPADDR=<some ip> NETMASK=<some netmask> ONBOOT=yes
However, when I put this virtual interface up, it overwrites the original interface and when I put original interface up, it overwrites the virtual interface. I just can't use both at the same time when I'm using the permanent way.
P.S.: I use the following commands to put interface up:
# To make up ifup eth0 ifup eth0:0
I'm using cent-OS