Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion ntc_templates/templates/cisco_ios_show_vlan.textfsm
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Value Required VLAN_ID (\d+)
Value VLAN_NAME (\S+)
Value STATUS (\S+)
Value STATUS ((act|sus)\S+)
Value List INTERFACES ([\w\./]+)

Start
Expand All @@ -14,6 +14,8 @@ VLANS
^\d+ -> Continue.Record
^${VLAN_ID}\s+${VLAN_NAME}\s+${STATUS}\s*$$
^${VLAN_ID}\s+${VLAN_NAME}\s+${STATUS}\s+${INTERFACES},* -> Continue
^${VLAN_ID}\s+${VLAN_NAME}$$
^\s+${STATUS}\s+${INTERFACES},* -> Continue
^\d+\s+(?:\S+\s+){3}${INTERFACES},* -> Continue
^\d+\s+(?:\S+\s+){4}${INTERFACES},* -> Continue
^\d+\s+(?:\S+\s+){5}${INTERFACES},* -> Continue
Expand Down
36 changes: 36 additions & 0 deletions tests/cisco_ios/show_vlan/cisco_ios_show_vlan_long-names.raw
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
VLAN Name Status Ports
---- -------------------------------- --------- -------------------------------
1 default active
331 VLAN0331 suspended
332 test332 act/ishut Tw2/0/3
333 Parking act/lshut Tw2/0/4
334 test334 sus/ishut Tw2/0/5
335 test335 sus/lshut Tw2/0/6
915 VLAN0915 active Tw3/0/2
1000 REDACTED-REDACTED-REDACTED-REDACTED-REDACTED
active Tw1/0/1, Tw3/0/16
1001 CONFIDENTIAL-CONFIDENTIAL-CONFIDENTIAL-CONFIDENTIAL
active Tw1/0/10, Tw1/0/24, Tw2/0/15, Tw2/0/17, Tw2/0/29, Te2/0/45, Tw3/0/7, Te3/0/40, Te3/0/41, Te3/0/42, Te3/0/43, Te3/0/46
Te3/0/47, Te3/0/48, Tw4/0/27
1002 fddi-default act/unsup
1003 token-ring-default act/unsup
1004 fddinet-default act/unsup
1005 trnet-default act/unsup

VLAN Type SAID MTU Parent RingNo BridgeNo Stp BrdgMode Trans1 Trans2
---- ----- ---------- ----- ------ ------ -------- ---- -------- ------ ------
1 enet 100001 1500 - - - - - 0 0
10 enet 100010 1500 - - - - - 0 0
50 enet 100050 1500 - - - - - 0 0
60 enet 100060 1500 - - - - - 0 0
1002 fddi 101002 1500 - - - - - 0 0
1003 tr 101003 1500 - - - - srb 0 0
1004 fdnet 101004 1500 - - - ieee - 0 0
1005 trnet 101005 1500 - - - ibm - 0 0

Remote SPAN VLANs
------------------------------------------------------------------------------


Primary Secondary Type Ports
------- --------- ----------------- ------------------------------------------
80 changes: 80 additions & 0 deletions tests/cisco_ios/show_vlan/cisco_ios_show_vlan_long-names.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
---
parsed_sample:
- interfaces: []
status: "active"
vlan_id: "1"
vlan_name: "default"
- interfaces: []
status: "suspended"
vlan_id: "331"
vlan_name: "VLAN0331"
- interfaces:
- "Tw2/0/3"
status: "act/ishut"
vlan_id: "332"
vlan_name: "test332"
- interfaces:
- "Tw2/0/4"
status: "act/lshut"
vlan_id: "333"
vlan_name: "Parking"
- interfaces:
- "Tw2/0/5"
status: "sus/ishut"
vlan_id: "334"
vlan_name: "test334"
- interfaces:
- "Tw2/0/6"
status: "sus/lshut"
vlan_id: "335"
vlan_name: "test335"
- interfaces:
- "Tw3/0/2"
status: "active"
vlan_id: "915"
vlan_name: "VLAN0915"
- interfaces:
- "Tw1/0/1"
- "active"
- "Tw1/0/1"
- "Tw3/0/16"
status: "active"
vlan_id: "1000"
vlan_name: "REDACTED-REDACTED-REDACTED-REDACTED-REDACTED"
- interfaces:
- "Tw1/0/10"
- "active"
- "Tw1/0/10"
- "Tw1/0/24"
- "Tw2/0/15"
- "Tw2/0/17"
- "Tw2/0/29"
- "Te2/0/45"
- "Tw3/0/7"
- "Te3/0/40"
- "Te3/0/41"
- "Te3/0/42"
- "Te3/0/43"
- "Te3/0/46"
- "Te3/0/47"
- "Te3/0/48"
- "Tw4/0/27"
status: "active"
vlan_id: "1001"
vlan_name: "CONFIDENTIAL-CONFIDENTIAL-CONFIDENTIAL-CONFIDENTIAL"
- interfaces: []
status: "act/unsup"
vlan_id: "1002"
vlan_name: "fddi-default"
- interfaces: []
status: "act/unsup"
vlan_id: "1003"
vlan_name: "token-ring-default"
- interfaces: []
status: "act/unsup"
vlan_id: "1004"
vlan_name: "fddinet-default"
- interfaces: []
status: "act/unsup"
vlan_id: "1005"
vlan_name: "trnet-default"
Loading