Centos 6 – Set network interfaces to replication VM

Last updated on July 29th, 2018 at 08:45 am

Excemples of ifcfg-eth0

DEVICE=eth1
BOOTPROTO=none
HWADDR=30:70:56:a9:3f:5a
ONBOOT=yes
NETMASK=255.255.255.224
IPADDR=85.13.211.108
GATEWAY=85.13.211.97
TYPE=Ethernet

1. On Primary VM -> Edit Settings -> Copy outside both Ethernet MAC Addresses
Then, open Console/File Manager -> Copy outside ifcfg-eth0 + ifcfg-eth1 files
2. Go to Replica VM – Edit Settings -> Remove both Ethernet adapters -> Recreate both Ethernet adapters
3. Then, open Console -> Login to root -> Recreate two network adapters:

nano /etc/sysconfig/network-scripts/ifcfg-eth0

3a. Paste ifcfg-eth0 configuration, then change IP address, Gateway, PREFIX etc.

ifup eth0
nano /etc/sysconfig/network-scripts/ifcfg-eth1

3b. Paste ifcfg-eth1 configuration, then change IP address, Gateway, PREFIX etc.

ifup eth1

4. Remove this file:

rm /etc/udev/rules.d/70-persistent-net.rules

5. Restart Network:

service network restart

6. Ensure you can see both adapters up:

ifconfig

7. Reboot the system:

reboot