From 2127df1eab2c78f2b224dd2002bd76eded15c31b Mon Sep 17 00:00:00 2001 From: Mike Reeves Date: Tue, 10 Apr 2018 11:32:34 -0400 Subject: [PATCH] Setup Script - Bond Ubuntu testing --- so-setup-network.sh | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/so-setup-network.sh b/so-setup-network.sh index 32b8259e7..b25906d29 100644 --- a/so-setup-network.sh +++ b/so-setup-network.sh @@ -143,14 +143,15 @@ create_bond() { modprobe bonding # Backup and create a new interface file cp /etc/network/interfaces /etc/network/interfaces.sosetup - local LBACK=$(awk '/auto lo/,/^$/' /etc/network/interfaces) - echo $MNIC - local MINT=$(awk '/auto $MNIC/,/^$/' /etc/network/interfaces) - echo $MINT - # Let's set up the new interface file - echo $LBACK > /etc/network/interfaces - echo $MINT >> /etc/network/interfaces + local LBACK=$(awk '/auto lo/,/^$/' /etc/network/interfaces) + local MINT=$(awk '/auto $MNIC/,/^$/' /etc/network/interfaces) + + # Let's set up the new interface file + echo $LBACK > /tmp/interfaces + echo $MINT >> /tmp/interfaces + cp /tmp/interfaces /etc/network/interfaces + # Create a for loop here for BNIC in ${BNICS[@]}; do echo "auto $BNIC" >> /etc/network/interfaces