summaryrefslogtreecommitdiff
path: root/templates/interfaces/bridge
diff options
context:
space:
mode:
authorStephen Hemminger <stephen.hemminger@vyatta.com>2009-03-31 11:06:57 -0700
committerStephen Hemminger <stephen.hemminger@vyatta.com>2009-03-31 11:06:57 -0700
commit303b4aa341d418da4c1e15a2bf7271028d6face7 (patch)
tree6703605cfdedbe7626570cf756f63edce6edfd65 /templates/interfaces/bridge
parent691677e3d6e2ac4a610ccd4433a723b1977689c7 (diff)
downloadvyatta-cfg-system-303b4aa341d418da4c1e15a2bf7271028d6face7.tar.gz
vyatta-cfg-system-303b4aa341d418da4c1e15a2bf7271028d6face7.zip
Turn off forwarding delay if STP is off
Bug 4226 There is no need for forwarding delay unless doing spanning tree.
Diffstat (limited to 'templates/interfaces/bridge')
-rw-r--r--templates/interfaces/bridge/node.tag/forwarding-delay/node.def4
-rw-r--r--templates/interfaces/bridge/node.tag/stp/node.def13
2 files changed, 8 insertions, 9 deletions
diff --git a/templates/interfaces/bridge/node.tag/forwarding-delay/node.def b/templates/interfaces/bridge/node.tag/forwarding-delay/node.def
index 528fdb02..458eb320 100644
--- a/templates/interfaces/bridge/node.tag/forwarding-delay/node.def
+++ b/templates/interfaces/bridge/node.tag/forwarding-delay/node.def
@@ -1,7 +1,5 @@
type: u32
help: Set the forwarding delay
-default: 15
-update:expression: "sudo brctl setfd $VAR(../@) $VAR(@)"
-delete:expression: "sudo brctl setfd $VAR(../@) 15"
+update: sudo brctl setfd $VAR(../@) $VAR(@)
comp_help: possible completions:
<number> Set the folwarding delay (default 15)
diff --git a/templates/interfaces/bridge/node.tag/stp/node.def b/templates/interfaces/bridge/node.tag/stp/node.def
index bcad194a..4d2e31b5 100644
--- a/templates/interfaces/bridge/node.tag/stp/node.def
+++ b/templates/interfaces/bridge/node.tag/stp/node.def
@@ -1,12 +1,13 @@
type: bool
help: Enable spanning tree protocol
default: false
-update:expression: "if [ x$VAR(@) == xtrue ]; then \
- sudo brctl stp $VAR(../@) on; \
- else \
- sudo brctl stp $VAR(../@) off; \
- fi; "
-delete:expression: "sudo brctl stp $VAR(../@) off"
+update: if [ "$VAR(@)" == "true" ]; then
+ sudo brctl stp $VAR(../@) on
+ else
+ sudo brctl stp $VAR(../@) off
+ sudo brctl setfd $VAR(../@) 0
+ fi
+delete:sudo brctl stp $VAR(../@) off
comp_help: possible completions:
true Enable Spanning Tree Protocol
false Disable Spanning Tree Protocol (default false)