summaryrefslogtreecommitdiff
path: root/templates/interfaces/bonding
diff options
context:
space:
mode:
Diffstat (limited to 'templates/interfaces/bonding')
-rw-r--r--templates/interfaces/bonding/node.tag/bridge-group/node.def16
-rw-r--r--templates/interfaces/bonding/node.tag/vif/node.tag/bridge-group/node.def16
2 files changed, 16 insertions, 16 deletions
diff --git a/templates/interfaces/bonding/node.tag/bridge-group/node.def b/templates/interfaces/bonding/node.tag/bridge-group/node.def
index 940295fa..9ce97b1b 100644
--- a/templates/interfaces/bonding/node.tag/bridge-group/node.def
+++ b/templates/interfaces/bonding/node.tag/bridge-group/node.def
@@ -12,13 +12,13 @@ end:
exit 1
else
echo "Adding interface $bondif to bridge $newbridge."
- sudo brctl addif $newbridge $bondif;
+ /usr/sbin/brctl addif $newbridge $bondif;
if [ -n "$VAR(./cost/@)" ]; then
- sudo brctl setpathcost $newbridge $bondif $VAR(./cost/@);
+ /usr/sbin/brctl setpathcost $newbridge $bondif $VAR(./cost/@);
fi;
if [ -n "$VAR(./priority/@)" ]; then
- sudo brctl setportprio $newbridge $bondif $VAR(./priority/@);
+ /usr/sbin/brctl setportprio $newbridge $bondif $VAR(./priority/@);
fi
fi
elif [ ${COMMIT_ACTION} = 'DELETE' ]; then
@@ -32,7 +32,7 @@ end:
# it gets deleted before the removal of bridge-groups under interfaces
exit 0
else
- sudo brctl delif $oldbridge $bondif
+ /usr/sbin/brctl delif $oldbridge $bondif
fi
else
if [ -z "$newbridge" ]; then
@@ -46,15 +46,15 @@ end:
if ! /opt/vyatta/sbin/vyatta-bridgegroup-depedency.pl \
--bridge-notin-proposedcfg \
--bridge-interface="$oldbridge"; then \
- sudo brctl delif $oldbridge $bondif
+ /usr/sbin/brctl delif $oldbridge $bondif
fi
- sudo brctl addif $newbridge $bondif
+ /usr/sbin/brctl addif $newbridge $bondif
fi
if [ -n "$VAR(./cost/@)" ]; then
- sudo brctl setpathcost $newbridge $bondif $VAR(./cost/@)
+ /usr/sbin/brctl setpathcost $newbridge $bondif $VAR(./cost/@)
fi
if [ -n "$VAR(./priority/@)" ]; then
- sudo brctl setportprio $newbridge $bondif $VAR(./priority/@)
+ /usr/sbin/brctl setportprio $newbridge $bondif $VAR(./priority/@)
fi
fi
fi
diff --git a/templates/interfaces/bonding/node.tag/vif/node.tag/bridge-group/node.def b/templates/interfaces/bonding/node.tag/vif/node.tag/bridge-group/node.def
index 04dc957b..42234106 100644
--- a/templates/interfaces/bonding/node.tag/vif/node.tag/bridge-group/node.def
+++ b/templates/interfaces/bonding/node.tag/vif/node.tag/bridge-group/node.def
@@ -13,13 +13,13 @@ end:
exit 1
else
echo "Adding interface $bondif to bridge $newbridge."
- sudo brctl addif $newbridge $bondif;
+ /usr/sbin/brctl addif $newbridge $bondif;
if [ -n "$VAR(./cost/@)" ]; then
- sudo brctl setpathcost $newbridge $bondif $VAR(./cost/@);
+ /usr/sbin/brctl setpathcost $newbridge $bondif $VAR(./cost/@);
fi;
if [ -n "$VAR(./priority/@)" ]; then
- sudo brctl setportprio $newbridge $bondif $VAR(./priority/@);
+ /usr/sbin/brctl setportprio $newbridge $bondif $VAR(./priority/@);
fi
fi
elif [ ${COMMIT_ACTION} = 'DELETE' ]; then
@@ -33,7 +33,7 @@ end:
# it gets deleted before the removal of bridge-groups under interfaces
exit 0
else
- sudo brctl delif $oldbridge $bondif
+ /usr/sbin/brctl delif $oldbridge $bondif
fi
else
if [ -z "$newbridge" ]; then
@@ -47,15 +47,15 @@ end:
if ! /opt/vyatta/sbin/vyatta-bridgegroup-depedency.pl \
--bridge-notin-proposedcfg \
--bridge-interface="$oldbridge"; then \
- sudo brctl delif $oldbridge $bondif
+ /usr/sbin/brctl delif $oldbridge $bondif
fi
- sudo brctl addif $newbridge $bondif
+ /usr/sbin/brctl addif $newbridge $bondif
fi
if [ -n "$VAR(./cost/@)" ]; then
- sudo brctl setpathcost $newbridge $bondif $VAR(./cost/@)
+ /usr/sbin/brctl setpathcost $newbridge $bondif $VAR(./cost/@)
fi
if [ -n "$VAR(./priority/@)" ]; then
- sudo brctl setportprio $newbridge $bondif $VAR(./priority/@)
+ /usr/sbin/brctl setportprio $newbridge $bondif $VAR(./priority/@)
fi
fi
fi