-
Notifications
You must be signed in to change notification settings - Fork 734
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
Added support for broadcom_icos command show_mac-address-table #736
Merged
Merged
Changes from 1 commit
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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,14 @@ | ||
Value VLAN (\S+) | ||
Value MAC (\S+) | ||
Value INTERFACE (\S+) | ||
Value INDEX (\S+) | ||
Value STATUS (\S+) | ||
|
||
Start | ||
# Captures show mac-address-table for: | ||
# Accton AS4610-54P, Accton AS5610-52X, Quanta LY2R, Quanta LB9, DNI AG3448P-R | ||
# Raw data is the same in the case of all those devices | ||
^\s*VLAN\s+ID\s+MAC\s+Address\s+Interface\s+IfIndex\s+Status | ||
^-+ -+ -+ -+ | ||
^\s*${VLAN}\s+${MAC}\s+${INTERFACE}\s+${INDEX}\s+${STATUS} -> Record | ||
^. -> 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
22 changes: 22 additions & 0 deletions
22
tests/broadcom_icos/show_mac-address-table/broadcom_show_mac-address-table.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,22 @@ | ||
|
||
VLAN ID MAC Address Interface IfIndex Status | ||
------- ------------------ --------------------- ------- ------------ | ||
1 CC:37:AB:18:5F:01 5/1 55 Management | ||
100 CC:37:AB:18:AF:03 4/100 219 Management | ||
150 00:04:F2:B3:AD:CA 0/4 4 Learned | ||
150 00:30:D1:00:A2:F6 0/5 5 Learned | ||
150 00:30:F1:00:AC:36 0/1 1 Learned | ||
150 1C:C1:FE:24:00:C0 0/47 47 Learned | ||
150 1C:C1:FE:24:F7:C2 0/48 48 Learned | ||
150 40:00:34:25:03:A1 0/20 20 Learned | ||
150 64:06:0F:47:0F:A1 0/31 31 Learned | ||
150 64:16:0F:81:B6:BC 0/18 18 Learned | ||
150 04:16:0F:21:E6:3A 0/17 17 Learned | ||
150 14:16:0F:21:F8:24 0/30 30 Learned | ||
150 24:16:0F:34:57:24 0/10 10 Learned | ||
150 34:16:0F:89:28:4E 0/16 16 Learned | ||
150 44:16:0F:49:28:55 0/19 19 Learned | ||
150 AC:3F:DB:09:0D:8F 0/8 8 Learned | ||
112 00:40:58:0E:A6:36 0/14 14 Learned | ||
112 00:40:58:0E:A8:08 0/6 6 Learned | ||
112 00:00:58:13:E4:67 0/13 13 Learned |
97 changes: 97 additions & 0 deletions
97
tests/broadcom_icos/show_mac-address-table/broadcom_show_mac-address-table.yml
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,97 @@ | ||
--- | ||
parsed_sample: | ||
- vlan: "1" | ||
mac: "CC:37:AB:18:5F:01" | ||
interface: "5/1" | ||
index: "55" | ||
status: "Management" | ||
- vlan: "100" | ||
mac: "CC:37:AB:18:AF:03" | ||
interface: "4/100" | ||
index: "219" | ||
status: "Management" | ||
- vlan: "150" | ||
mac: "00:04:F2:B3:AD:CA" | ||
interface: "0/4" | ||
index: "4" | ||
status: "Learned" | ||
- vlan: "150" | ||
mac: "00:30:D1:00:A2:F6" | ||
interface: "0/5" | ||
index: "5" | ||
status: "Learned" | ||
- vlan: "150" | ||
mac: "00:30:F1:00:AC:36" | ||
interface: "0/1" | ||
index: "1" | ||
status: "Learned" | ||
- vlan: "150" | ||
mac: "1C:C1:FE:24:00:C0" | ||
interface: "0/47" | ||
index: "47" | ||
status: "Learned" | ||
- vlan: "150" | ||
mac: "1C:C1:FE:24:F7:C2" | ||
interface: "0/48" | ||
index: "48" | ||
status: "Learned" | ||
- vlan: "150" | ||
mac: "40:00:34:25:03:A1" | ||
interface: "0/20" | ||
index: "20" | ||
status: "Learned" | ||
- vlan: "150" | ||
mac: "64:06:0F:47:0F:A1" | ||
interface: "0/31" | ||
index: "31" | ||
status: "Learned" | ||
- vlan: "150" | ||
mac: "64:16:0F:81:B6:BC" | ||
interface: "0/18" | ||
index: "18" | ||
status: "Learned" | ||
- vlan: "150" | ||
mac: "04:16:0F:21:E6:3A" | ||
interface: "0/17" | ||
index: "17" | ||
status: "Learned" | ||
- vlan: "150" | ||
mac: "14:16:0F:21:F8:24" | ||
interface: "0/30" | ||
index: "30" | ||
status: "Learned" | ||
- vlan: "150" | ||
mac: "24:16:0F:34:57:24" | ||
interface: "0/10" | ||
index: "10" | ||
status: "Learned" | ||
- vlan: "150" | ||
mac: "34:16:0F:89:28:4E" | ||
interface: "0/16" | ||
index: "16" | ||
status: "Learned" | ||
- vlan: "150" | ||
mac: "44:16:0F:49:28:55" | ||
interface: "0/19" | ||
index: "19" | ||
status: "Learned" | ||
- vlan: "150" | ||
mac: "AC:3F:DB:09:0D:8F" | ||
interface: "0/8" | ||
index: "8" | ||
status: "Learned" | ||
- vlan: "112" | ||
mac: "00:40:58:0E:A6:36" | ||
interface: "0/14" | ||
index: "14" | ||
status: "Learned" | ||
- vlan: "112" | ||
mac: "00:40:58:0E:A8:08" | ||
interface: "0/6" | ||
index: "6" | ||
status: "Learned" | ||
- vlan: "112" | ||
mac: "00:00:58:13:E4:67" | ||
interface: "0/13" | ||
index: "13" | ||
status: "Learned" |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would remove the extra ones as they mark the headers as you have already made sure they exist.
Do you mind also adding the following right above the error line:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Corrected as requested