How do I configure bonding device on Red Hat Enterprise Linux?
Responses
The configuration for bonding with RHEL5 involves four files (for a 2 NIC bond):
1) Bonding module: /etc/modprobe.conf:
The modprobe.conf module should have the following lines added:
#bond<n> in the case of a single bonding, bond0
alias bond0 bonding
#parameter definitions - for failover, mode=1 and we set the trigger time to 100 milliseconds, miimon=100
options bond0 mode=1 miimon=100
2) Bonding NIC. The bonding NIC (bond<n>, or in our case, bond0). The bond0 NIC definition is used as the master and contains the network parameters usually associated with
a NIC that interfaces with the external network, i.e., IPADDR, NETMASK, GATEWAY etc. and the syntax is the same.
The bonding NIC resides in the same directory as the standard NICs: /etc/sysconfig/network-scripts. (parameters below left blank after '=' but would normally be filled in)
DEVICE=bond0
# If DHCP is not used
BOOTPROTO=none
ONBOOT=yes
IPADDR=
NETMASK=
GATEWAY=
NETWORK=
3) Physical NICs that will be bonded to gether into bond0: /etc/sysconfig/network-scripts in two files: ifcfg-eth0 and ifcfg-eth1
#one file each for eth0 and eth1
DEVICE=eth0
BOOTPROTO=none
ONBOOT=yes
MASTER=bond0
SLAVE=yes
USERCTL=no
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
