Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sros, new template - sh router interface, -vrf # optional #898

Merged
merged 1 commit into from
Mar 17, 2021
Merged
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
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
Value Required INTERFACE (\S+)
Value Required ADMIN_STATE (Up|Down)
Value Required OPER_STATE_V4 (Up|Down)
Value Required OPER_STATE_V6 (Up|Down)
Value Required MODE (\S+)
Value Required PORT_SAP_ID (\S+)
Value List ADDRESS (\S+)
Value List PFX_STATE (\S+)

Start
^=+
^Interface\s+Table
^Interface-Name\s+Adm\s+Opr\(v4\/v6\)\s+Mode\s+Port/SapId\s*$$ -> Interface
^\s*$$
^. -> Error

Interface
^\s+IP-Address\s+PfxState
^-+
^.*?\s+(Up|Down) -> Continue.Record
^${INTERFACE}\s+${ADMIN_STATE}\s+${OPER_STATE_V4}\/${OPER_STATE_V6}\s+${MODE}\s+${PORT_SAP_ID}
^\s+${ADDRESS}\s+${PFX_STATE}
^Interfaces -> Done
^=+
^\s*$$
^. -> Error

Done
1 change: 1 addition & 0 deletions ntc_templates/templates/index
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ alcatel_sros_show_router_ldp_interface.textfsm, .*, alcatel_sros, sh[[ow]] route
alcatel_sros_show_router_pim_interface.textfsm, .*, alcatel_sros, sh[[ow]] router pim int[[erface]]
alcatel_sros_show_service_sap-using.textfsm, .*, alcatel_sros, sh[[ow]] service sap-u[[sing]]
alcatel_sros_show_service_sdp-using.textfsm, .*, alcatel_sros, sh[[ow]] service sdp-using
alcatel_sros_show_router_interface.textfsm, .*, alcatel_sros, sh[[ow]] router (\d+ int[[erface]]|int[[erface]])
alcatel_sros_show_router_mpls_lsp.textfsm, .*, alcatel_sros, sh[[ow]] router mpls lsp
alcatel_sros_show_service_id_base.textfsm, .*, alcatel_sros, sh[[ow]] serv[[ice]] id ba[[se]]
alcatel_sros_show_service_sdp.textfsm, .*, alcatel_sros, sh[[ow]] service sdp
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
===============================================================================
Interface Table (Router: Base)
===============================================================================
Interface-Name Adm Opr(v4/v6) Mode Port/SapId
IP-Address PfxState
-------------------------------------------------------------------------------
L3-Telecom-IXR01-1 Up Down/Up IES lag-21:300
2001:4888:2062:357a:645:400:0:2/64 PREFERRED
fe80::645:400:0:2/64 PREFERRED
L3-Telecom-IXR02-1 Up Down/Up IES lag-22:300
2001:4888:2062:3591:645:400:0:2/64 PREFERRED
fe80::645:400:0:2/64 PREFERRED
TO_EDGE_IXR01 Up Down/Down Network n/a
192.168.28.1/24 n/a
192.168.47.1/24 n/a
system Up Up/Up Network system
10.115.43.64/32 n/a
2001:4888:2062:3000:645:400:0:1a0/128 PREFERRED
to-7750-02 Up Up/Up Network 1/1/c4/1:2415
172.25.214.121/31 n/a
2001:4888:206a:335c:645:400:0:1/64 PREFERRED
fe80::c9:ffff:fe00:0/64 PREFERRED
to-BTS0415-7750-H1 Up Down/Down Network lag-11:4094
172.25.198.123/31 n/a
2001:4888:206a:335f:645:400:0:1/64 INACCESSIBLE
fe80::c9:ffff:fe00:14b/64 INACCESSIBLE
-------------------------------------------------------------------------------
Interfaces : 6
===============================================================================
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
---
parsed_sample:
- address:
- "2001:4888:2062:357a:645:400:0:2/64"
- "fe80::645:400:0:2/64"
admin_state: "Up"
interface: "L3-Telecom-IXR01-1"
mode: "IES"
oper_state_v4: "Down"
oper_state_v6: "Up"
pfx_state:
- "PREFERRED"
- "PREFERRED"
port_sap_id: "lag-21:300"
- address:
- "2001:4888:2062:3591:645:400:0:2/64"
- "fe80::645:400:0:2/64"
admin_state: "Up"
interface: "L3-Telecom-IXR02-1"
mode: "IES"
oper_state_v4: "Down"
oper_state_v6: "Up"
pfx_state:
- "PREFERRED"
- "PREFERRED"
port_sap_id: "lag-22:300"
- address:
- "192.168.28.1/24"
- "192.168.47.1/24"
admin_state: "Up"
interface: "TO_EDGE_IXR01"
mode: "Network"
oper_state_v4: "Down"
oper_state_v6: "Down"
pfx_state:
- "n/a"
- "n/a"
port_sap_id: "n/a"
- address:
- "10.115.43.64/32"
- "2001:4888:2062:3000:645:400:0:1a0/128"
admin_state: "Up"
interface: "system"
mode: "Network"
oper_state_v4: "Up"
oper_state_v6: "Up"
pfx_state:
- "n/a"
- "PREFERRED"
port_sap_id: "system"
- address:
- "172.25.214.121/31"
- "2001:4888:206a:335c:645:400:0:1/64"
- "fe80::c9:ffff:fe00:0/64"
admin_state: "Up"
interface: "to-7750-02"
mode: "Network"
oper_state_v4: "Up"
oper_state_v6: "Up"
pfx_state:
- "n/a"
- "PREFERRED"
- "PREFERRED"
port_sap_id: "1/1/c4/1:2415"
- address:
- "172.25.198.123/31"
- "2001:4888:206a:335f:645:400:0:1/64"
- "fe80::c9:ffff:fe00:14b/64"
admin_state: "Up"
interface: "to-BTS0415-7750-H1"
mode: "Network"
oper_state_v4: "Down"
oper_state_v6: "Down"
pfx_state:
- "n/a"
- "INACCESSIBLE"
- "INACCESSIBLE"
port_sap_id: "lag-11:4094"