From bdcd55d8a3051473e523c453595da05e3ad8a74b Mon Sep 17 00:00:00 2001 From: Stephen Hemminger Date: Wed, 3 Dec 2008 10:31:32 -0800 Subject: Use new link-detect script Wrap direct calls to vyatta-vtysh to set link-detect in new script. --- .../interfaces/ethernet/node.tag/disable-link-detect/node.def | 9 ++------- .../node.tag/vif/node.tag/disable-link-detect/node.def | 10 ++-------- .../node.tag/vif/node.tag/disable-link-detect/node.def | 9 ++------- .../cisco-hdlc/vif/node.tag/disable-link-detect/node.def | 9 ++------- .../interfaces/serial/node.tag/disable-link-detect/node.def | 7 ++----- .../frame-relay/vif/node.tag/disable-link-detect/node.def | 9 ++------- .../node.tag/ppp/vif/node.tag/disable-link-detect/node.def | 9 ++------- 7 files changed, 14 insertions(+), 48 deletions(-) (limited to 'templates/interfaces') diff --git a/templates/interfaces/ethernet/node.tag/disable-link-detect/node.def b/templates/interfaces/ethernet/node.tag/disable-link-detect/node.def index d4b4ceaa..22eec7cf 100644 --- a/templates/interfaces/ethernet/node.tag/disable-link-detect/node.def +++ b/templates/interfaces/ethernet/node.tag/disable-link-detect/node.def @@ -1,8 +1,3 @@ help: Set to ignore link state changes on this interface -update:vyatta-vtysh -c "configure terminal" \ - -c "interface $VAR(../@)" \ - -c "no link-detect" -delete:vyatta-vtysh -c "configure terminal" \ - -c "interface $VAR(../@)" \ - -c "link-detect" - +update:vyatta-link-detect $VAR(../@) on +delete:vyatta-link-detect $VAR(../@) off diff --git a/templates/interfaces/ethernet/node.tag/vif/node.tag/disable-link-detect/node.def b/templates/interfaces/ethernet/node.tag/vif/node.tag/disable-link-detect/node.def index 250c9a41..97a74ccc 100644 --- a/templates/interfaces/ethernet/node.tag/vif/node.tag/disable-link-detect/node.def +++ b/templates/interfaces/ethernet/node.tag/vif/node.tag/disable-link-detect/node.def @@ -1,9 +1,3 @@ help: Set to ignore link state changes on this interface -update:vyatta-vtysh -c "configure terminal\" \ - -c "interface $VAR(../../@).$VAR(../@)" \ - -c "no link-detect" - -delete:vyatta-vtysh -c "configure terminal" \ - -c "interface $VAR(../../@).$VAR(../@)" \ - -c "link-detect" - +update:vyatta-link-detect "$VAR(../../@).$VAR(../@)" on +delete:vyatta-link-detect "$VAR(../../@).$VAR(../@)" off diff --git a/templates/interfaces/multilink/node.tag/vif/node.tag/disable-link-detect/node.def b/templates/interfaces/multilink/node.tag/vif/node.tag/disable-link-detect/node.def index ed220d3d..4cd557d9 100644 --- a/templates/interfaces/multilink/node.tag/vif/node.tag/disable-link-detect/node.def +++ b/templates/interfaces/multilink/node.tag/vif/node.tag/disable-link-detect/node.def @@ -1,8 +1,3 @@ help: ignore link state changes on this interface -update: vyatta-vtysh -c "configure terminal" \ - -c "interface $VAR(../../@).$VAR(../@)" \ - -c "no link-detect" -delete: vyatta-vtysh -c "configure terminal" \ - -c "interface $VAR(../../@).$VAR(../@)" \ - -c "link-detect" - +update:vyatta-link-detect "$VAR(../../@).$VAR(../@)" on +delete:vyatta-link-detect "$VAR(../../@).$VAR(../@)" off diff --git a/templates/interfaces/serial/node.tag/cisco-hdlc/vif/node.tag/disable-link-detect/node.def b/templates/interfaces/serial/node.tag/cisco-hdlc/vif/node.tag/disable-link-detect/node.def index 0bf660e1..7992791f 100644 --- a/templates/interfaces/serial/node.tag/cisco-hdlc/vif/node.tag/disable-link-detect/node.def +++ b/templates/interfaces/serial/node.tag/cisco-hdlc/vif/node.tag/disable-link-detect/node.def @@ -1,8 +1,3 @@ help: ignore link state changes on this interface -update: vyatta-vtysh -c "configure terminal" \ - -c "interface $VAR(../../../@).$VAR(../@)" \ - -c "no link-detect" -delete: vyatta-vtysh -c "configure terminal" \ - -c "interface $VAR(../../../@).$VAR(../@)" \ - -c "link-detect" - +update:vyatta-link-detect "$VAR(../../../@).$VAR(../@)" on +delete:vyatta-link-detect "$VAR(../../../@).$VAR(../@)" off diff --git a/templates/interfaces/serial/node.tag/disable-link-detect/node.def b/templates/interfaces/serial/node.tag/disable-link-detect/node.def index 2fc84bdd..03317ea1 100644 --- a/templates/interfaces/serial/node.tag/disable-link-detect/node.def +++ b/templates/interfaces/serial/node.tag/disable-link-detect/node.def @@ -1,6 +1,3 @@ help: ignore link state changes on this interface -update: vyatta-vtysh -c "configure terminal" -c "interface $VAR(../@)" \ - -c "no link-detect" -delete: vyatta-vtysh -c "configure terminal" -c "interface $VAR(../@)" \ - -c "link-detect " - +update: vyatta-link-detect $VAR(../@) off +delete: vyatta-link-detect $VAR(../@) on diff --git a/templates/interfaces/serial/node.tag/frame-relay/vif/node.tag/disable-link-detect/node.def b/templates/interfaces/serial/node.tag/frame-relay/vif/node.tag/disable-link-detect/node.def index 0bf660e1..7992791f 100644 --- a/templates/interfaces/serial/node.tag/frame-relay/vif/node.tag/disable-link-detect/node.def +++ b/templates/interfaces/serial/node.tag/frame-relay/vif/node.tag/disable-link-detect/node.def @@ -1,8 +1,3 @@ help: ignore link state changes on this interface -update: vyatta-vtysh -c "configure terminal" \ - -c "interface $VAR(../../../@).$VAR(../@)" \ - -c "no link-detect" -delete: vyatta-vtysh -c "configure terminal" \ - -c "interface $VAR(../../../@).$VAR(../@)" \ - -c "link-detect" - +update:vyatta-link-detect "$VAR(../../../@).$VAR(../@)" on +delete:vyatta-link-detect "$VAR(../../../@).$VAR(../@)" off diff --git a/templates/interfaces/serial/node.tag/ppp/vif/node.tag/disable-link-detect/node.def b/templates/interfaces/serial/node.tag/ppp/vif/node.tag/disable-link-detect/node.def index 0bf660e1..94c73270 100644 --- a/templates/interfaces/serial/node.tag/ppp/vif/node.tag/disable-link-detect/node.def +++ b/templates/interfaces/serial/node.tag/ppp/vif/node.tag/disable-link-detect/node.def @@ -1,8 +1,3 @@ help: ignore link state changes on this interface -update: vyatta-vtysh -c "configure terminal" \ - -c "interface $VAR(../../../@).$VAR(../@)" \ - -c "no link-detect" -delete: vyatta-vtysh -c "configure terminal" \ - -c "interface $VAR(../../../@).$VAR(../@)" \ - -c "link-detect" - +update:vyatta-link-detect "$VAR(../../../@).$VAR(../@)" on +delete:vyatta-link-detect "$VAR(../../@).$VAR(../@)" off -- cgit v1.2.3