Page 1 of 1

Can the nagios server be a client machine

Posted: Wed Feb 26, 2020 1:47 am
by Pratapa
Hi,

We have a backup script placed in the crontab of cisco user on nagios server itself. We need to monitor the output of the backup script.

It is configured as a passive check in Nagios. Can the Nagios server be a client machine.

[root@nagiosserver ]# crontab -u cisco -l
0 6 * * * /usr/local/backup/cisco/awsm_config_backup.sh host1 2>&1 > /dev/null


Following are the service defintion and check command.

define service {
use network-service-passive-template
service_description AWSM Configuration Backup: Admin
host_name host1
freshness_threshold 657500 ; Service is deemed stale after 7 days
check_command check_passive_warning!"Nagios has not received an update from $HOSTNAME$ for at least 25 hours"
}


define command {
command_name check_passive_warning
command_line $USER1$/check_dummy 1 $ARG1$
}

Re: Can the nagios server be a client machine

Posted: Thu Feb 27, 2020 5:08 pm
by Box293
Yes it can.

Basically use something like NRDP to submit check results to the Nagios server.

https://assets.nagios.com/downloads/nag ... erview.pdf

The usage examples here can explain how you can submit the check result from the command line:

https://github.com/NagiosEnterprises/nrdp