Ad Widget

Collapse

How to handle a string that contains multiple bits of status

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • troffasky
    Senior Member
    • Jul 2008
    • 565

    #1

    How to handle a string that contains multiple bits of status

    I am referring to the NUT 'upsc' command and how this template handles the ups.status output:
    Zabbix Template for NUT(Network UPS Tools). Contribute to delin/Zabbix-NUT-Template development by creating an account on GitHub.


    I think that it can return many combinations in there; I have seen three so far and have added a few of them but this is pretty tedious stuff.
    Ideally the agent-side manipulation of this string would be eliminated completely but value maps can't handle strings, only numeric or single-character, hence that element of the script.

    What would be a better way to handle this data format?
Working...