/etc/sysconfig/network-scripts/
directory called ifcfg-bondN
, replacing N with the number for the interface, such as 0
.
DEVICE
directive is bondN
, replacing N with the number for the interface, and TYPE=Bond. The NM_CONTROLLED
directive can be added to prevent NetworkManager from configuring this device.
Example 4.1. Example ifcfg-bond0 Interface Configuration File
DEVICE=bond0 NAME=bond0 TYPE=Bond IPADDR=192.168.1.1 NETMASK=255.255.255.0 ONBOOT=yes BOOTPROTO=none BONDING_OPTS="bonding parameters separated by spaces"
Put all Bonding Module Parameters in ifcfg-bondN Files
BONDING_OPTS="bonding parameters"
directive in the ifcfg-bondN
interface file. Do not specify options for the bonding device in /etc/modprobe.d/bonding.conf
, or in the deprecated /etc/modprobe.conf
file.
max_bonds
parameter is not interface specific and should not be set when using ifcfg-bondN
files with the BONDING_OPTS
directive as this directive will cause the network scripts to create the bond interfaces as required.