-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #21 from loverend/luke/add_oc_output
Add code to map variables from the message to open config output
- Loading branch information
Showing
4 changed files
with
91 additions
and
19 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
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 |
---|---|---|
@@ -1,23 +1,27 @@ | ||
# You should not use special characture in the value keys | ||
prefix: | ||
time_format: "%b %d %H:%M:%S" | ||
values: | ||
date: (\w+ \d\d) | ||
time: (\d\d:\d\d:\d\d) | ||
host: ([^ ]+) | ||
processName: (\w+) | ||
processId: (\d+) | ||
error: (\w+) | ||
line: '{date} {time} {host} {processName}[{processId}]: {error}:' | ||
line: '{date} {time} {host} {processName}[{processId}]: {error}: ' | ||
|
||
messages: | ||
BGP_PREFIX_THRESH_EXCEEDED: | ||
values: | ||
peer: (\d+\.\d+\.\d+\.\d+) | ||
asn: (\d+) | ||
limit: (\d+) | ||
line: '{peer} (External AS {asn}): Configured maximum prefix-limit threshold({limit}) exceeded for inet-unicast nlri: 137 (instance master)' | ||
model: oc-bgp | ||
current: (\d+) | ||
table: (\w+) | ||
type: (\w+) | ||
line: '{peer} (External AS {asn}): Configured maximum prefix-limit threshold({limit}) exceeded for {table}-{type} nlri: {current} (instance master)' | ||
model: openconfig_bgp | ||
mapping: | ||
peer: xxxx | ||
asn: xxxx | ||
limit: xxxx | ||
asn: bgp/neighbors/neighbor/{peer}/state/peer_as | ||
current: bgp/neighbors/neighbor/{peer}/afi_safis/afi_safi/{table}/state/prefixes/received | ||
limit: bgp/neighbors/neighbor/{peer}/afi_safis/afi_safi/{table}/ipv4_{type}/prefix_limit/state/max_prefixes |
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