I installed NCPA / NRDP per the manuals available here at the links.
https://assets.nagios.com/downloads/ncp ... g-NCPA.pdf
https://assets.nagios.com/downloads/ncp ... Checks.pdf
https://support.nagios.com/kb/article/n ... s-762.html
STATUS PENDING ALL
https://i.imgur.com/AMzKxN5.jpg
Checking Nagios logs, I observed a message: Error: host check result obtained by '', but no host can be found
found it the article link https://support.nagios.com/kb/article/n ... p-795.html
There is already php-xml installed on my Nagios Server.
I also read it here https://support.nagios.com/forum/viewto ... 2&start=10, but as I understand it, it was not resolved.
Can you help me?
Details:
Machine monitored in passive mode:
/usr/local/ncpa/etc/ncpa.cfg.d/nrdp.cfg
Code: Select all
%HOSTNAME%|Disk Usage = disk/logical/C:|/used_percent --warning 80 --critical 90 --units Gi
%HOSTNAME%|CPU Usage = cpu/percent --warning 60 --critical 80 --aggregate avg
%HOSTNAME%|Swap Usage = memory/swap --warning 60 --critical 80 --units Gi
%HOSTNAME%|Memory Usage = memory/virtual --warning 80 --critical 90 --units Gi
Code: Select all
[nrdp]
parent = https://security2/nrdp/
token = 45mlafp49838afcdaaffad
hostname = host_ncpa
[passive]
handlers = nrdp
uid = nagios
gid = nagios
sleep = 150
loglevel = info
logfile = var/log/ncpa_passive.log
pidfile = var/run/ncpa_passive.pid
[nrdp]
parent = https://security2/nrdp/
token = 45mlafp49838afcdaaffad
hostname = host_ncpa
Code: Select all
Traceback (most recent call last):
File "/root/ncpa/agent/passive/nrdp.py", line 198, in submit_to_nagios
File "/root/ncpa/agent/passive/nrdp.py", line 145, in log_result
File "/usr/local/lib/python2.7/xml/dom/minidom.py", line 1928, in parseString
File "/usr/local/lib/python2.7/xml/dom/expatbuilder.py", line 940, in parseString
File "/usr/local/lib/python2.7/xml/dom/expatbuilder.py", line 223, in parseString
ExpatError: no element found: line 1, column 0
/usr/local/nrdp/server/config.inc.php
Code: Select all
$cfg['authorized_tokens'] = array( "mytoken", // <-- not a good token
);
$cfg['external_commands_deny_tokens'] = array(
);
$cfg["require_https"] = true;
$cfg["nagios_command_group"] = "nagcmd";
$cfg["command_file"] = "/usr/local/nagios/var/rw/nagios.cmd";
$cfg["check_results_dir"] = "/usr/local/nagios/var/spool/checkresults";
$cfg["disable_external_commands"] = false;
$cfg["allow_old_results"] = false;
$cfg["debug"] = false;
$cfg["debug_log"] = "/usr/local/nrdp/server/debug.log";
$cfg['product_name'] = 'nrdp';
$cfg['product_version'] = '1.5.0'