I am testing zabbix 3.4 to monitor old PSTN switch. It only has telnet login. so I used External check with "expect" script. the output gives the list of current alarms in the system. but the problem is the text item contain blank lines. so the regex exit on the first match.
Output,
Header line
Header line 2
Alarm xxxxxx11
Alarm xxxxxx22
Alarm xxxxxx33
END
I am using Dependent Item from this and doing a pre-processing..
^Alarm (.+)
Capture group only contain Alarm xxxxxx11.
I am sure this is due to blank line, next to the mach.
Unable to find a method to remove those blank spaces.
Or is there better way to monitor this node ?
Please help ..
Output,
Header line
Header line 2
Alarm xxxxxx11
Alarm xxxxxx22
Alarm xxxxxx33
END
I am using Dependent Item from this and doing a pre-processing..
^Alarm (.+)
Capture group only contain Alarm xxxxxx11.
I am sure this is due to blank line, next to the mach.
Unable to find a method to remove those blank spaces.
Or is there better way to monitor this node ?
Please help ..

Comment