Skip to content

Commit

Permalink
new_template: cisco_ios_show_environment_temperature.template
Browse files Browse the repository at this point in the history
  • Loading branch information
bobbytayar authored and FragmentedPacket committed Nov 12, 2019
1 parent 53f638d commit 84519d3
Show file tree
Hide file tree
Showing 4 changed files with 75 additions and 0 deletions.
32 changes: 32 additions & 0 deletions templates/cisco_ios_show_environment_temperature.template
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
Value SWITCH (\d+)
Value SWITCH_TEMPERATURE (\w+)
Value INLET_TEMPERATURE_VALUE (\d+)
Value INLET_TEMPERATURE_STATE (\S+)
Value INLET_YELLOW_THRESHOLD (\d+)
Value INLET_RED_THRESHOLD (\d+)
Value HOTSPOT_TEMPERATURE_VALUE (\d+)
Value HOTSPOT_TEMPERATURE_STATE (\S+)
Value HOTSPOT_YELLOW_THRESHOLD (\d+)
Value HOTSPOT_RED_THRESHOLD (\d+)

Start
^Switch\s+\d -> Continue.Record
^Switch\s+${SWITCH}:\s+SYSTEM\s+TEMPERATURE\s+is\s+${SWITCH_TEMPERATURE}\s*$$ -> Inlet
^\s*$$
^. -> Error

Inlet
^Inlet\s+Temperature\s+Value:\s+${INLET_TEMPERATURE_VALUE}\s+Degree\s+Celsius\s*$$
^Temperature\s+State:\s+${INLET_TEMPERATURE_STATE}\s*$$
^Yellow\s+Threshold\s+:\s+${INLET_YELLOW_THRESHOLD}\s+Degree\s+Celsius\s*$$
^Red\s+Threshold\s+:\s+${INLET_RED_THRESHOLD}\s+Degree\s+Celsius\s*$$ -> Hotspot
^\s*$$
^. -> Error

Hotspot
^Hotspot\s+Temperature\s+Value:\s+${HOTSPOT_TEMPERATURE_VALUE}\s+Degree\s+Celsius\s*$$
^Temperature\s+State:\s+${HOTSPOT_TEMPERATURE_STATE}\s*$$
^Yellow\s+Threshold\s+:\s+${HOTSPOT_YELLOW_THRESHOLD}\s+Degree\s+Celsius\s*$$
^Red\s+Threshold\s+:\s+${HOTSPOT_RED_THRESHOLD}\s+Degree\s+Celsius\s*$$ -> Start
^\s*$$
^. -> Error
1 change: 1 addition & 0 deletions templates/index
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@ cisco_ios_show_running-config_partition_access-list.template, .*, cisco_ios, sh[
cisco_ios_show_running-config_partition_route-map.template, .*, cisco_ios, sh[[ow]] ru[[nning-config]] p[[artition]] route-[[map]]
cisco_ios_show_capability_feature_routing.template, .*, cisco_ios, sh[[ow]] cap[[ability]] f[[eature]] r[[outing]]
cisco_ios_show_authentication_sessions.template, .*, cisco_ios, show authen[[tication]] ses[[sions]]
cisco_ios_show_environment_temperature.template, .*, cisco_ios, sh[[ow]] envi[[ronment]] t[[emperature]]
cisco_ios_show_ip_ospf_interface_brief.template, .*, cisco_ios, sh[[ow]] ip ospf int[[erface]]
cisco_ios_show_processes_memory_sorted.template, .*, cisco_ios, sh[[ow]] pro[[cesses]] mem[[ory]] so[[rted]]
cisco_ios_show_interfaces_description.template, .*, cisco_ios, sh[[ow]] int[[erfaces]] des[[cription]]
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
parsed_sample:
- hotspot_red_threshold: '125'
hotspot_temperature_state: GREEN
hotspot_temperature_value: '67'
hotspot_yellow_threshold: '105'
inlet_red_threshold: '56'
inlet_temperature_state: GREEN
inlet_temperature_value: '29'
inlet_yellow_threshold: '46'
switch: '1'
switch_temperature: OK
- hotspot_red_threshold: '125'
hotspot_temperature_state: GREEN
hotspot_temperature_value: '69'
hotspot_yellow_threshold: '105'
inlet_red_threshold: '56'
inlet_temperature_state: GREEN
inlet_temperature_value: '28'
inlet_yellow_threshold: '46'
switch: '2'
switch_temperature: OK
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
Switch 1: SYSTEM TEMPERATURE is OK
Inlet Temperature Value: 29 Degree Celsius
Temperature State: GREEN
Yellow Threshold : 46 Degree Celsius
Red Threshold : 56 Degree Celsius

Hotspot Temperature Value: 67 Degree Celsius
Temperature State: GREEN
Yellow Threshold : 105 Degree Celsius
Red Threshold : 125 Degree Celsius
Switch 2: SYSTEM TEMPERATURE is OK
Inlet Temperature Value: 28 Degree Celsius
Temperature State: GREEN
Yellow Threshold : 46 Degree Celsius
Red Threshold : 56 Degree Celsius

Hotspot Temperature Value: 69 Degree Celsius
Temperature State: GREEN
Yellow Threshold : 105 Degree Celsius
Red Threshold : 125 Degree Celsius

0 comments on commit 84519d3

Please sign in to comment.