Question

I receive a (null) from the web portal when this check runs. However, I receive a response when I type the command in terminal. I suspect it has something to do with the "=" symbol and I tried escaping it by placing escape characters in front. What is the best way about doing this?

define command {
    command_name                    check_sql
    command_line                    $USER1$/check_sql.pl -v -s -d "DBI:Sybase:server=5.5.5.5:1433" -U TEST -P PASS
    }

define service {
    use                             generic-service
    host_name                       5.5.5.5
    service_description             SQL Check
    check_command                   check_sql
    check_interval                  1
    retry_interval                  1
    }
Was it helpful?

Solution

In particular versions of Nagios from about 2 years ago, you need to use a double escape character rather than a single escape character

ie

\\=

instead of

\=

Try that.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top