Bonding ethernet is nothing but Linux kernel feature that allows to agregate multiple like interface, such as (eth0 & eth1) into single virtual link such as bond0
The idea is pretty simple get higher data rates and as well as link failover

this is step to configure ethernet bonding

step 1

create virtual interface bond0

# vi /etc/sysconfig/network-script/ifcfg-bond0

add this line bellow

DEVICE=bond0
BOOTPROTO=none
BONDING_OPTS="mode=1 primary=eth0 miimon=100 updelay=5000"
IPADDR=192.168.10.26
NETMASK=255.255.255.0
GATEWAY=192.168.10.1
NM_CONTROLLED=none
ONBOOT=yes

step 2

edit configuration interface eth0 and eth1, as follow

# vi /etc/sysconfig/network-script/ifcfg-eth0

DEVICE=eth0
HWADDR=40:F2:E9:F0:5D:C3
TYPE=Ethernet
UUID=12d3532a-ad5f-4228-8814-42f72a5ac44c
ONBOOT=yes
NM_CONTROLLED=yes
BOOTPROTO=none
MASTER=bond0
SLAVE=yes
# vi /etc/sysconfig/network-script/ifcfg-eth1

DEVICE=eth1
HWADDR=40:F2:E9:F0:5D:C4
TYPE=Ethernet
UUID=48c24676-1944-4a09-bc1d-b504a2382578
ONBOOT=yes
NM_CONTROLLED=yes
BOOTPROTO=none
MASTER=bond0
SLAVE=yes

save al configuration and than restart service network on the server

# service network restart

check the result

# ifconfig

bond0 Link encap:Ethernet HWaddr 40:F2:E9:F0:5D:C3
inet addr:192.168.10.26 Bcast:192.168.10.255 Mask:255.255.255.0
UP BROADCAST RUNNING MASTER MULTICAST MTU:1500 Metric:1
RX packets:268332 errors:0 dropped:0 overruns:0 frame:0
TX packets:195536 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:101448438 (96.7 MiB) TX bytes:47405931 (45.2 MiB)

eth0 Link encap:Ethernet HWaddr 40:F2:E9:F0:5D:C3
UP BROADCAST RUNNING SLAVE MULTICAST MTU:1500 Metric:1
RX packets:304692 errors:0 dropped:0 overruns:0 frame:0
TX packets:222413 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:115311758 (109.9 MiB) TX bytes:53337160 (50.8 MiB)
Memory:bc5a0000-bc5bffff

eth1 Link encap:Ethernet HWaddr 40:F2:E9:F0:5D:C3
UP BROADCAST RUNNING SLAVE MULTICAST MTU:1500 Metric:1
RX packets:335 errors:0 dropped:0 overruns:0 frame:0
TX packets:7 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:20484 (20.0 KiB) TX bytes:1893 (1.8 KiB)
Memory:bc5c0000-bc5dffff

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:4718 errors:0 dropped:0 overruns:0 frame:0
TX packets:4718 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:323788 (316.1 KiB) TX bytes:323788 (316.1 KiB)
Advertisements