simplify the code
modified: set_bonding.sh Signed-off-by: swei <swei@linx-info.com>
This commit is contained in:
@@ -25,8 +25,7 @@ IF_CONFIG="/etc/sysconfig/network-devices"
|
||||
if [ -f ${IF_CONFIG}/ifcfg-bond0 ];then
|
||||
echo "bonding exit.."
|
||||
else
|
||||
grep "^bonding" /etc/sysconfig/modules &> /dev/null
|
||||
if [ $? -eq 0 ];then
|
||||
if ! grep -q "^bonding" /etc/sysconfig/modules;then
|
||||
echo 'bonding mode=6 max_bonds=1' >> /etc/sysconfig/modules
|
||||
fi
|
||||
|
||||
|
||||
Reference in New Issue
Block a user