Menu

Create a Command in NAGIOSQL 3.2.0

2019-10-14
2019-10-16
  • Sebastian Lara

    Sebastian Lara - 2019-10-14

    Hello, my name is Sebastian
    i trying to create a command which obtained information about the status of a docked container that is working on a remote server, through check_by_ssh (NAGIOS CORE)
    the command is:
    $USER1$/check_by_ssh -H $HOSTADDRESS$ -C "$ARG1" -t "$ARG2"
    ARG1=docker ps -a | grep Up | wc -l
    ARG2=50
    The question I have is because the command delivers a numerical value, which I would like to be interpreted by NAGIOS (CORE) as a state, either, OK, Critical or Unknown, according to the amount of active or inactive containers.

    How could I achieve this?
    thanks.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.