-
Notifications
You must be signed in to change notification settings - Fork 740
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
New Template: cisco_ios_show_vrrp_all/brief (#856)
- Loading branch information
Showing
11 changed files
with
541 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
Value IFACE (\S+) | ||
Value GROUP (\d+) | ||
Value ADDR_FAMILY (\S+) | ||
Value STATE (\w+) | ||
Value STATE_DURATION (.+) | ||
Value VIRTUALIP ([a-fA-F\d\.\:]+) | ||
Value VIRTUAL_MAC ([a-fA-F\d\.\:]+) | ||
Value ADV_INTERVAL (\S+) | ||
Value PREEMPT (\w+) | ||
Value PRIORITY (\d+) | ||
Value PRIORITY_CONFIGURED (\d+) | ||
Value TRACK_OBJ (\d+) | ||
Value TRACK_STATUS (\S+) | ||
Value TRACK_ACTION (\S+(\s+\S+)?) | ||
Value MASTER_IP (\S+) | ||
Value MASTER_PRIORITY (\S+) | ||
Value MASTER_ADV_INTERVAL (\S+) | ||
Value MASTER_DOWN_INTERVAL (\S+) | ||
|
||
Start | ||
^\S+\s+-\s+Group\s+\d+.*$$ -> Continue.Record | ||
^\s*${IFACE}\s+-\s+Group\s+${GROUP}(\s+-\s+Address-Family\s+${ADDR_FAMILY})?\s*$$ | ||
^\s+State is\s+${STATE}.*\s*$$ | ||
^\s*State duration\s+${STATE_DURATION}\s*$$ | ||
^\s+Virtual IP address is\s+${VIRTUALIP}\s*$$ | ||
^\s+Virtual MAC address is\s+${VIRTUAL_MAC}\s*$$ | ||
^\s+Advertisement interval is\s+${ADV_INTERVAL} | ||
^\s+Preemption\s+${PREEMPT}\s*$$ | ||
^\s+Priority is\s+${PRIORITY}(\s+\((cfgd|[cC]onfigured)\s+${PRIORITY_CONFIGURED}\))?\s*$$ | ||
^\s*Track object\s+${TRACK_OBJ}\s+state\s+${TRACK_STATUS}\s+${TRACK_ACTION}\s*$$ | ||
# ignore authentication output since later VRRP versions do not even support it | ||
^\s+Authentication\s | ||
# ignoring the "local" designation since we can use the STATE value to determine who the master is | ||
^\s+Master Router is\s+${MASTER_IP}(\s+\(local\))?, priority is\s+${MASTER_PRIORITY}\s*$$ | ||
^\s+Master Advertisement interval is\s+${MASTER_ADV_INTERVAL} | ||
^\s+Master Down interval is\s+${MASTER_DOWN_INTERVAL} | ||
# Capture time-stamp if vty line has command time-stamping turned on | ||
^Load\s+for\s+ | ||
^Time\s+source\s+is | ||
^\s*$$ | ||
^. -> Error |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
Value IFACE (\S+) | ||
Value GROUP (\d+) | ||
Value ADDR_FAMILY (\S+) | ||
Value PRIORITY (\d+) | ||
Value TIME (\d+) | ||
Value OWN (.?) | ||
Value PREEMPT (.) | ||
Value STATE (\w+) | ||
Value MASTER_IP ([a-fA-F\d\.\:]+) | ||
Value VIRTUALIP ([a-fA-F\d\.\:]+) | ||
|
||
Start | ||
^Interface\s+Grp\s+Pri\s+Time\s+Own\s+Pre\s+State\s+Master addr\s+Group addr\s*$$ -> Vrrp | ||
^\s*Interface\s+Grp\s+A-F\s+Pri\s+Time\s+Own\s+Pre\s+State\s+Master addr\/Group addr\s*$$ -> Vrrpv3 | ||
# Capture time-stamp if vty line has command time-stamping turned on | ||
^Load\s+for\s+ | ||
^Time\s+source\s+is | ||
|
||
Vrrp | ||
# VRRP Legacy (VRRPv2 for IPv4) | ||
^${IFACE}\s+${GROUP}\s*${PRIORITY}\s+${TIME}\s+${OWN}\s+${PREEMPT}\s+${STATE}\s+${MASTER_IP}\s+${VIRTUALIP} -> Record | ||
^${IFACE}\s*$$ | ||
^\s*${GROUP}\s+${PRIORITY}\s+${TIME}\s+${OWN}\s+${PREEMPT}\s+${STATE}\s+${MASTER_IP}\s+${VIRTUALIP} -> Record | ||
^\s*$$ | ||
^. -> Error | ||
|
||
Vrrpv3 | ||
# VRRP Unified (VRRPv3 for IPv4 and IPv6) | ||
# - ignoring the "local" designation since we can use the STATE value to determine who the master is | ||
^\s*${IFACE}\s+${GROUP}\s+${ADDR_FAMILY}\s+${PRIORITY}\s+${TIME}\s+${OWN}\s+${PREEMPT}\s+${STATE}\s+${MASTER_IP}\(local\)\s+${VIRTUALIP} -> Record | ||
^\s*${IFACE}\s+${GROUP}\s+${ADDR_FAMILY}\s+${PRIORITY}\s+${TIME}\s+${OWN}\s+${PREEMPT}\s+${STATE}\s+${MASTER_IP}\s+${VIRTUALIP} -> Record | ||
# rows that roll over to a second line | ||
^\s*${IFACE}\s*$$ | ||
^\s*${GROUP}\s+${ADDR_FAMILY}\s+${PRIORITY}\s+${TIME}\s+${OWN}\s+${PREEMPT}\s+${STATE}\s+${MASTER_IP}\(local\)\s+${VIRTUALIP} -> Record | ||
^\s*${IFACE}\s*$$ | ||
^\s*${GROUP}\s+${ADDR_FAMILY}\s+${PRIORITY}\s+${TIME}\s+${OWN}\s+${PREEMPT}\s+${STATE}\s+${MASTER_IP}\s+${VIRTUALIP} -> Record | ||
^\s*$$ | ||
^. -> Error |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
FastEthernet0/1 - Group 1 | ||
State is Master | ||
Virtual IP address is 192.168.88.1 | ||
Virtual MAC address is 0000.5e00.0101 | ||
Advertisement interval is 1.000 sec | ||
Preemption enabled | ||
Priority is 110 | ||
Track object 1 state Up decrement 10 | ||
Authentication MD5, key-string "highavailability" | ||
Master Router is 192.168.88.2 (local), priority is 110 | ||
Master Advertisement interval is 1.000 sec | ||
Master Down interval is 3.570 sec | ||
|
||
FastEthernet0/1.2 - Group 2 | ||
State is Master | ||
Virtual IP address is 10.0.2.1 | ||
Virtual MAC address is 0000.5e00.0102 | ||
Advertisement interval is 1.000 sec | ||
Preemption enabled | ||
Priority is 110 | ||
Track object 1 state Up decrement 10 | ||
Master Router is 10.0.2.2 (local), priority is 110 | ||
Master Advertisement interval is 1.000 sec | ||
Master Down interval is 3.570 sec | ||
|
||
FastEthernet0/1.3 - Group 3 | ||
State is Backup | ||
Virtual IP address is 10.0.3.1 | ||
Virtual MAC address is 0000.5e00.0103 | ||
Advertisement interval is 1.000 sec | ||
Preemption enabled | ||
Priority is 110 | ||
Track object 1 state Up decrement 10 | ||
Master Router is 10.0.3.3, priority is 120 | ||
Master Advertisement interval is 1.000 sec | ||
Master Down interval is 3.570 sec (expires in 2.738 sec) | ||
|
||
FastEthernet0/1.4 - Group 4 | ||
State is Init | ||
Virtual IP address is 10.0.4.1 | ||
Virtual MAC address is 0000.5e00.0104 | ||
Advertisement interval is 1.000 sec | ||
Preemption enabled | ||
Priority is 100 | ||
Master Router is 10.0.4.3, priority is 120 | ||
Master Advertisement interval is 1.000 sec | ||
Master Down interval is 3.609 sec | ||
|
||
FastEthernet0/1.5 - Group 5 | ||
State is Backup | ||
Virtual IP address is 10.0.5.1 | ||
Virtual MAC address is 0000.5e00.0105 | ||
Advertisement interval is 1.000 sec | ||
Preemption enabled | ||
Priority is 90 (cfgd 110) | ||
Track object 2 state Down decrement 20 | ||
Master Router is 10.0.5.3, priority is 105 | ||
Master Advertisement interval is 1.000 sec | ||
Master Down interval is 3.570 sec (expires in 2.706 sec) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
--- | ||
parsed_sample: | ||
- iface: "FastEthernet0/1" | ||
group: "1" | ||
addr_family: "" | ||
state: "Master" | ||
state_duration: "" | ||
virtualip: "192.168.88.1" | ||
virtual_mac: "0000.5e00.0101" | ||
adv_interval: "1.000" | ||
preempt: "enabled" | ||
priority: "110" | ||
priority_configured: "" | ||
track_obj: "1" | ||
track_status: "Up" | ||
track_action: "decrement 10" | ||
master_ip: "192.168.88.2" | ||
master_priority: "110" | ||
master_adv_interval: "1.000" | ||
master_down_interval: "3.570" | ||
- iface: "FastEthernet0/1.2" | ||
group: "2" | ||
addr_family: "" | ||
state: "Master" | ||
state_duration: "" | ||
virtualip: "10.0.2.1" | ||
virtual_mac: "0000.5e00.0102" | ||
adv_interval: "1.000" | ||
preempt: "enabled" | ||
priority: "110" | ||
priority_configured: "" | ||
track_obj: "1" | ||
track_status: "Up" | ||
track_action: "decrement 10" | ||
master_ip: "10.0.2.2" | ||
master_priority: "110" | ||
master_adv_interval: "1.000" | ||
master_down_interval: "3.570" | ||
- iface: "FastEthernet0/1.3" | ||
group: "3" | ||
addr_family: "" | ||
state: "Backup" | ||
state_duration: "" | ||
virtualip: "10.0.3.1" | ||
virtual_mac: "0000.5e00.0103" | ||
adv_interval: "1.000" | ||
preempt: "enabled" | ||
priority: "110" | ||
priority_configured: "" | ||
track_obj: "1" | ||
track_status: "Up" | ||
track_action: "decrement 10" | ||
master_ip: "10.0.3.3" | ||
master_priority: "120" | ||
master_adv_interval: "1.000" | ||
master_down_interval: "3.570" | ||
- iface: "FastEthernet0/1.4" | ||
group: "4" | ||
addr_family: "" | ||
state: "Init" | ||
state_duration: "" | ||
virtualip: "10.0.4.1" | ||
virtual_mac: "0000.5e00.0104" | ||
adv_interval: "1.000" | ||
preempt: "enabled" | ||
priority: "100" | ||
priority_configured: "" | ||
track_obj: "" | ||
track_status: "" | ||
track_action: "" | ||
master_ip: "10.0.4.3" | ||
master_priority: "120" | ||
master_adv_interval: "1.000" | ||
master_down_interval: "3.609" | ||
- iface: "FastEthernet0/1.5" | ||
group: "5" | ||
addr_family: "" | ||
state: "Backup" | ||
state_duration: "" | ||
virtualip: "10.0.5.1" | ||
virtual_mac: "0000.5e00.0105" | ||
adv_interval: "1.000" | ||
preempt: "enabled" | ||
priority: "90" | ||
priority_configured: "110" | ||
track_obj: "2" | ||
track_status: "Down" | ||
track_action: "decrement 20" | ||
master_ip: "10.0.5.3" | ||
master_priority: "105" | ||
master_adv_interval: "1.000" | ||
master_down_interval: "3.570" |
80 changes: 80 additions & 0 deletions
80
tests/cisco_ios/show_vrrp_all/cisco_ios_show_vrrpv3_all.raw
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
|
||
GigabitEthernet0/0 - Group 1 - Address-Family IPv4 | ||
State is MASTER | ||
State duration 37 mins 23.080 secs | ||
Virtual IP address is 10.0.1.1 | ||
Virtual MAC address is 0000.5E00.0101 | ||
Advertisement interval is 1000 msec | ||
Preemption enabled | ||
Priority is 110 | ||
Track object 1 state UP decrement 10 | ||
Master Router is 10.0.1.2 (local), priority is 110 | ||
Master Advertisement interval is 1000 msec (expires in 32 msec) | ||
Master Down interval is unknown | ||
|
||
GigabitEthernet0/0 - Group 6 - Address-Family IPv6 | ||
State is MASTER | ||
State duration 37 mins 22.120 secs | ||
Virtual IP address is FE80::1:1 | ||
Virtual MAC address is 0000.5E00.0206 | ||
Advertisement interval is 1000 msec | ||
Preemption enabled | ||
Priority is 110 | ||
Track object 1 state UP shutdown | ||
Master Router is FE80::1:A (local), priority is 110 | ||
Master Advertisement interval is 1000 msec (expires in 260 msec) | ||
Master Down interval is unknown | ||
|
||
|
||
GigabitEthernet0/0.4010 - Group 1 - Address-Family IPv4 | ||
State is BACKUP | ||
State duration 37 mins 14.859 secs | ||
Virtual IP address is 10.254.1.1 | ||
Virtual MAC address is 0000.5E00.0101 | ||
Advertisement interval is 1000 msec | ||
Preemption enabled | ||
Priority is 110 | ||
Master Router is 10.254.1.3, priority is 120 | ||
Master Advertisement interval is 1000 msec (learned) | ||
Master Down interval is 3570 msec (expires in 3194 msec) | ||
|
||
GigabitEthernet0/0.4010 - Group 6 - Address-Family IPv6 | ||
State is BACKUP | ||
State duration 37 mins 13.888 secs | ||
Virtual IP address is FE80::4010:1 | ||
Virtual MAC address is 0000.5E00.0206 | ||
Advertisement interval is 1000 msec | ||
Preemption enabled | ||
Priority is 110 | ||
Master Router is FE80::4010:3, priority is 120 | ||
Master Advertisement interval is 1000 msec (learned) | ||
Master Down interval is 3570 msec (expires in 3420 msec) | ||
|
||
|
||
GigabitEthernet0/0.2600 - Group 1 - Address-Family IPv4 | ||
State is BACKUP | ||
State duration 2 mins 48.646 secs | ||
Virtual IP address is 172.26.0.1 | ||
Virtual MAC address is 0000.5E00.0101 | ||
Advertisement interval is 1000 msec | ||
Preemption enabled | ||
Priority is 90 (Configured 110) | ||
Track object 2 state DOWN decrement 20 | ||
Master Router is 172.26.0.3, priority is 100 | ||
Master Advertisement interval is 1000 msec (learned) | ||
Master Down interval is 3648 msec (expires in 3427 msec) | ||
|
||
GigabitEthernet0/0.2600 - Group 6 - Address-Family IPv6 | ||
State is INIT (Group is shutdown - Tracked object down) | ||
State duration 8 mins 57.183 secs | ||
Virtual IP address is FE80::2600:1 | ||
Virtual MAC address is 0000.5E00.0206 | ||
Advertisement interval is 1000 msec | ||
Preemption enabled | ||
Priority is 110 | ||
Track object 2 state DOWN shutdown | ||
Master Router is unknown, priority is unknown | ||
Master Advertisement interval is unknown | ||
Master Down interval is unknown | ||
|
||
|
Oops, something went wrong.