Nagios core check: Is it possible to pipe sort -u in a check command? -


is possible |sort -u in check command?

#check_active_node define command{     command_name    check_active_node_list     command_line    /usr/lib/nagios/plugins/check_active_node.sh '$arg1$' '$arg2$'|sort -u 

normally no. pipe character "|" not allowed part of line being executed nagios - there important security reasons this. there ways around it, i'd not recommend using of them. best solution modify plugin (create check_active_node_custom.sh , edit that), , add ever sorting need script itself. remember nagios system expects return codes , text plugin, , should still function expected after edits.


Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -