Value SYSTEM_UPTIME_YEARS (\d+)
Value SYSTEM_UPTIME_WEEKS (\d+)
Value SYSTEM_UPTIME_DAYS (\d+)
Value SYSTEM_UPTIME_HOURS (\d+)
Value SYSTEM_UPTIME_MINUTES (\d+)
Value SWITCHOVERS (\d+)
Value STANDBY_FAILURES (\d+)
Value LAST_SWITCHOVER_REASON (.+?)
Value HARDWARE_MODE (.+?)
Value CONFIGURED_REDUNDANCY_MODE (.+?)
Value OPERATING_REDUNDANCY_MODE (.+?)
Value MAINTENANCE_MODE (.+?)
Value COMMUNICATION_STATUS (.+?)
Value ACTIVE_SLOT (\S+)
Value ACTIVE_SOFTWARE_STATE (.+?)
Value ACTIVE_UPTIME_YEARS (\d+)
Value ACTIVE_UPTIME_WEEKS (\d+)
Value ACTIVE_UPTIME_DAYS (\d+)
Value ACTIVE_UPTIME_HOURS (\d+)
Value ACTIVE_UPTIME_MINUTES (\d+)
Value ACTIVE_MAJOR_RELEASE (\d+)
Value ACTIVE_MINOR_RELEASE (\d+)
Value ACTIVE_MAINTENANCE_RELEASE (\S+)
Value ACTIVE_BOOT_DIRECTORY (\S+)
Value ACTIVE_BOOT_FILE (\S+)
Value FAST_SWITCHOVER (\S+)
Value INITIAL_GARP (\S+)
Value ACTIVE_CONFIG_REGISTER (\S+)
Value STANDBY_SLOT (\S+)
Value STANDBY_SOFTWARE_STATE (.+?)
Value STANDBY_UPTIME_YEARS (\d+)
Value STANDBY_UPTIME_WEEKS (\d+)
Value STANDBY_UPTIME_DAYS (\d+)
Value STANDBY_UPTIME_HOURS (\d+)
Value STANDBY_UPTIME_MINUTES (\d+)
Value STANDBY_MAJOR_RELEASE (\d+)
Value STANDBY_MINOR_RELEASE (\d+)
Value STANDBY_MAINTENANCE_RELEASE (\S+)
Value STANDBY_BOOT_DIRECTORY (\S+)
Value STANDBY_BOOT_FILE (\S+)
Value STANDBY_CONFIG_REGISTER (\S+)
Value STANDBY_STATUS (.+?)


Start
  ^Redundant\s+System\s+Information
  ^\s*-+\s*$$
  ^\s*Available\s+system\s+uptime\s*=\s*(${SYSTEM_UPTIME_YEARS}\s*year(s)?,)?\s*(${SYSTEM_UPTIME_WEEKS}\s*week(s)?,)?\s*(${SYSTEM_UPTIME_DAYS}\s*day(s)?,)?\s*(${SYSTEM_UPTIME_HOURS}\s*hour(s)?,)?\s*${SYSTEM_UPTIME_MINUTES}\s*minute(s)?\s*$$
  ^\s*Switchovers\s+system\s+experienced\s*=\s*${SWITCHOVERS}\s*$$
  ^\s*Standby\s+failures\s*=\s*${STANDBY_FAILURES}\s*$$
  ^\s*Last\s+switchover\s+reason\s*=\s*${LAST_SWITCHOVER_REASON}\s*$$
  ^\s*Hardware\s+Mode\s*=\s*${HARDWARE_MODE}\s*$$
  ^\s*Configured\s+Redundancy\s+Mode\s*=\s*${CONFIGURED_REDUNDANCY_MODE}\s*$$
  ^\s*Operating\s+Redundancy\s+Mode\s*=\s*${OPERATING_REDUNDANCY_MODE}\s*$$
  ^\s*Maintenance\s+Mode\s*=\s*${MAINTENANCE_MODE}\s*$$
  ^\s*Communications\s*=\s*${COMMUNICATION_STATUS}\s*$$
  ^\s*Current\s+Processor -> Current
  # Capture time-stamp if vty line has command time-stamping turned on
  ^Load\s+for\s+
  ^Time\s+source\s+is
  ^\s*$$
  ^. -> Error

Current
  ^\s*-+\s*$$
  ^\s*Active\s+Location\s*=\s*(slot|Switch)\s+${ACTIVE_SLOT}\s*$$
  ^\s*Current\s+Software\s+state\s*=\s*${ACTIVE_SOFTWARE_STATE}\s*$$
  ^\s*Uptime\s+in\s+current\s+state\s*=\s*(${ACTIVE_UPTIME_YEARS}\s*year(s)?,)?\s*(${ACTIVE_UPTIME_WEEKS}\s*week(s)?,)?\s*(${ACTIVE_UPTIME_DAYS}\s*day(s)?,)?\s*(${ACTIVE_UPTIME_HOURS}\s*hour(s)?,)?\s*${ACTIVE_UPTIME_MINUTES}\s*minute(s)?\s*$$
  ^\s*Image\s+Version
  ^.+Version\s+${ACTIVE_MAJOR_RELEASE}\.${ACTIVE_MINOR_RELEASE}\(${ACTIVE_MAINTENANCE_RELEASE}\)
  ^.+[Cc][Ii][Ss][Cc][Oo]
  ^.*(?:Copyright|Compiled|CONFIG_FILE|BOOTLDR)
  ^\s*BOOT\s*=\s*${ACTIVE_BOOT_DIRECTORY}:${ACTIVE_BOOT_FILE}\s*$$
  ^\s*Fast\s+Switchover\s+=\s+${FAST_SWITCHOVER}
  ^\s*Initial\s+Garp\s+=\s+${INITIAL_GARP}
  ^\s*Configuration\s+register\s*=\s*${ACTIVE_CONFIG_REGISTER}\s*$$
  ^Peer\s*\(slot:\s*unavailable\)\s*\w*\s*\w*\s*\w*\s*\w*\s*\w\s*\w*\s*\w*\s*\w*\s*\w*\s*\'${STANDBY_STATUS}\'\s*state$$ -> EOF
  ^\s*Peer\s+Processor -> Peer
  ^\s*$$
  ^. -> Error

Peer
  ^\s*-+\s*$$
  ^\s*Standby\s+Location\s*=\s*(slot|Switch)\s+${STANDBY_SLOT}\s*$$
  ^\s*Current\s+Software\s+state\s*=\s*${STANDBY_SOFTWARE_STATE}\s*$$
  ^\s*Uptime\s+in\s+current\s+state\s*=\s*(${STANDBY_UPTIME_YEARS}\s*year(s)?,)?\s*(${STANDBY_UPTIME_WEEKS}\s*week(s)?,)?\s*(${STANDBY_UPTIME_DAYS}\s*day(s)?,)?\s*(${STANDBY_UPTIME_HOURS}\s*hour(s)?,)?\s*${STANDBY_UPTIME_MINUTES}\s*minute(s)?\s*$$
  ^\s*Image\s+Version
  ^.+Version\s+${STANDBY_MAJOR_RELEASE}\.${STANDBY_MINOR_RELEASE}\(${STANDBY_MAINTENANCE_RELEASE}\)
  ^.+[Cc][Ii][Ss][Cc][Oo]
  ^.*(?:Copyright|Compiled|CONFIG_FILE|BOOTLDR)
  ^\s*BOOT\s*=\s*${STANDBY_BOOT_DIRECTORY}:${STANDBY_BOOT_FILE}\s*$$
  ^\s*Configuration\s+register\s*=\s*${STANDBY_CONFIG_REGISTER}\s*$$
  ^\s*$$
  ^\s*Compiled\s*
  ^. -> Error
