diff --git a/ntc_templates/templates/hp_procurve_show_system.textfsm b/ntc_templates/templates/hp_procurve_show_system.textfsm index e0170d48e4..e15c14d021 100644 --- a/ntc_templates/templates/hp_procurve_show_system.textfsm +++ b/ntc_templates/templates/hp_procurve_show_system.textfsm @@ -1,6 +1,6 @@ Value Filldown NAME (\S+) -Value Filldown CONTACT (.+) -Value Filldown LOCATION (.+) +Value Filldown CONTACT (.*) +Value Filldown LOCATION (.*) Value Filldown MAC_AGE (\d+) Value Filldown TIMEZONE (\S+) Value Filldown DAYLIGHT_RULE (\S+) @@ -24,8 +24,8 @@ Value BUFFERS_MISSED (\d+) Start ^.*Status\s+and\s+Counters ^\s*System\s+Name\s+:\s+${NAME} - ^\s*System\s+Contact\s+:\s+${CONTACT} - ^\s*System\s+Location\s+:\s+${LOCATION} + ^\s*System\s+Contact\s+:\s*${CONTACT} + ^\s*System\s+Location\s+:\s*${LOCATION} ^\s*MAC\s+Age\s+Time[^:]*:\s+${MAC_AGE} ^\s*Time\s+Zone\s+:\s+${TIMEZONE} ^\s*Daylight\s+Time\s+Rule\s+:\s+${DAYLIGHT_RULE} @@ -42,6 +42,8 @@ Start ^\s*Missed\s+:\s+${BUFFERS_MISSED} -> Record ^\s*VSF-Member\s*: -> Continue.Record ^\s*VSF-Member\s*:\s*${MEMBER_ID} -> VSF + # swallow wrap-continuation lines (long contact/location wrap at col 78) + ^\s+\S.*$$ ^. -> Error VSF diff --git a/tests/hp_procurve/show_system/hp_procurve_show_system3.raw b/tests/hp_procurve/show_system/hp_procurve_show_system3.raw new file mode 100644 index 0000000000..877dca8e74 --- /dev/null +++ b/tests/hp_procurve/show_system/hp_procurve_show_system3.raw @@ -0,0 +1,47 @@ + Status and Counters - General System Information + + System Name : SWITCH-2 + System Contact : Network Operations Center (network-operations@example.c + om) location Building-3 Datacenter-Aisle-12 Rack-04 ABC + -ACCS1 + System Location : Building-3 Datacenter-Aisle-12 + MAC Age Time (sec) : 300 + Time Zone : 0 + Daylight Time Rule : None + + Software revision : WC.16.10.0014 + Base MAC Addr : 548028-aabbd0 + + VSF-Member :1 + + ROM Version : WC.16.01.0008 + Up Time : 458 days + CPU Util (%) : 5 + MAC Addr : 548028-aabbd1 + Serial Number : SN0000003A + Memory - Total : 338,285,056 + Free : 216,978,364 + + + + VSF-Member :2 + + ROM Version : WC.16.01.0008 + Up Time : 458 days + CPU Util (%) : 25 + MAC Addr : 548028-aabbd2 + Serial Number : SN0000004A + Memory - Total : 338,285,056 + Free : 233,762,648 + + + + VSF-Member :3 + + ROM Version : WC.16.01.0008 + Up Time : 458 days + CPU Util (%) : 0 + MAC Addr : 548028-aabbd3 + Serial Number : SN0000005A + Memory - Total : 338,285,056 + Free : 247,712,468 diff --git a/tests/hp_procurve/show_system/hp_procurve_show_system3.yml b/tests/hp_procurve/show_system/hp_procurve_show_system3.yml new file mode 100644 index 0000000000..a70b239e65 --- /dev/null +++ b/tests/hp_procurve/show_system/hp_procurve_show_system3.yml @@ -0,0 +1,68 @@ +--- +parsed_sample: + - allow_mods: "" + buffers_free: "" + buffers_lowest: "" + buffers_missed: "" + contact: "Network Operations Center (network-operations@example.c" + cpu_util: "5" + daylight_rule: "None" + location: "Building-3 Datacenter-Aisle-12" + mac_address: "548028-aabbd1" + mac_age: "300" + mem_free: "216,978,364" + mem_tot: "338,285,056" + member_id: "1" + name: "SWITCH-2" + packets_rx: "" + packets_tot: "" + packets_tx: "" + rom_version: "WC.16.01.0008" + serial: "SN0000003A" + software_version: "WC.16.10.0014" + timezone: "0" + uptime: "458 days" + - allow_mods: "" + buffers_free: "" + buffers_lowest: "" + buffers_missed: "" + contact: "Network Operations Center (network-operations@example.c" + cpu_util: "25" + daylight_rule: "None" + location: "Building-3 Datacenter-Aisle-12" + mac_address: "548028-aabbd2" + mac_age: "300" + mem_free: "233,762,648" + mem_tot: "338,285,056" + member_id: "2" + name: "SWITCH-2" + packets_rx: "" + packets_tot: "" + packets_tx: "" + rom_version: "WC.16.01.0008" + serial: "SN0000004A" + software_version: "WC.16.10.0014" + timezone: "0" + uptime: "458 days" + - allow_mods: "" + buffers_free: "" + buffers_lowest: "" + buffers_missed: "" + contact: "Network Operations Center (network-operations@example.c" + cpu_util: "0" + daylight_rule: "None" + location: "Building-3 Datacenter-Aisle-12" + mac_address: "548028-aabbd3" + mac_age: "300" + mem_free: "247,712,468" + mem_tot: "338,285,056" + member_id: "3" + name: "SWITCH-2" + packets_rx: "" + packets_tot: "" + packets_tx: "" + rom_version: "WC.16.01.0008" + serial: "SN0000005A" + software_version: "WC.16.10.0014" + timezone: "0" + uptime: "458 days"