diff options
author | Stephen Hemminger <stephen.hemminger@vyatta.com> | 2009-03-31 14:05:59 -0700 |
---|---|---|
committer | Stephen Hemminger <stephen.hemminger@vyatta.com> | 2009-03-31 14:05:59 -0700 |
commit | c1f9398f095be9b82ac6077ccb792d12fe1d8c80 (patch) | |
tree | ecb997480868f4f8f63e1ad54865be871f0a2549 /templates/interfaces | |
parent | 303b4aa341d418da4c1e15a2bf7271028d6face7 (diff) | |
download | vyatta-cfg-system-c1f9398f095be9b82ac6077ccb792d12fe1d8c80.tar.gz vyatta-cfg-system-c1f9398f095be9b82ac6077ccb792d12fe1d8c80.zip |
Set forwarding-delay when STP is enabled
If using STP then apply configured forwarding-delay or 15 if none
specified.
Diffstat (limited to 'templates/interfaces')
-rw-r--r-- | templates/interfaces/bridge/node.tag/stp/node.def | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/templates/interfaces/bridge/node.tag/stp/node.def b/templates/interfaces/bridge/node.tag/stp/node.def index 4d2e31b5..6f25f0cc 100644 --- a/templates/interfaces/bridge/node.tag/stp/node.def +++ b/templates/interfaces/bridge/node.tag/stp/node.def @@ -2,6 +2,11 @@ type: bool help: Enable spanning tree protocol default: false update: if [ "$VAR(@)" == "true" ]; then + if [ -z "$VAR(../../forwarding-delay)" ]; then + sudo brctl setfd $VAR(../@) 15 + else + sudo brctl setfd $VAR(../@) $VAR(../../forwarding-delay) + fi sudo brctl stp $VAR(../@) on else sudo brctl stp $VAR(../@) off |