Page 2 of 6

Re: Freshness check chg my service checks fr passive to acti

Posted: Mon Nov 26, 2018 10:33 pm
by charmainequek
hi cdienger,

i think the agent used is nrdp 1.0.5 in our customized plugin. Is there any way to verify this? i will check on the auto start-up portion.
May i also ask, our environment is currently setup to monitor 200 over hosts and more than a thousand service checks. What is the max no of hosts and service checks Nagios XI is able to support up to? Is there additional configuration to be done in order to support more hosts and services? And just wondering if the issue is caused by the large number of service checks.
Any advice please. Thanks! :)

Re: Freshness check chg my service checks fr passive to acti

Posted: Tue Nov 27, 2018 2:32 pm
by cdienger
The number of checks shouldn't be a problem.

Are you using one of the send_nrdp scripts described in https://support.nagios.com/kb/article/n ... t-599.html ?

Re: Freshness check chg my service checks fr passive to acti

Posted: Wed Nov 28, 2018 3:06 am
by charmainequek
hi cdienger,
its a partial yes. Our customized plug-in use send_nrdp but not the way stated in the website. Our customized plug-in handle the send_nrdp by using C++ to call the nagios function.

Re: Freshness check chg my service checks fr passive to acti

Posted: Thu Nov 29, 2018 10:06 am
by cdienger
I would double check the custom plugin then and make sure that it is in fact running and sending the data. The service is up and listening on the XI server, the client has access to the ndrp interface, so the next logical step is to verify the client side plugin is behaving as expected.

Re: Freshness check chg my service checks fr passive to acti

Posted: Tue Dec 04, 2018 10:49 pm
by charmainequek
hi cdienger,

would you be able to point me specifically to the syntax of a common nrdp agent for the "restart agent service" after host restart and other critical lines that will hinder the agent to work?
i would need to seek my developer's help on this as i am not familiar with coding.
Thanks! :)

Re: Freshness check chg my service checks fr passive to acti

Posted: Wed Dec 05, 2018 9:39 am
by scottwilkerson
charmainequek wrote:hi cdienger,

would you be able to point me specifically to the syntax of a common nrdp agent for the "restart agent service" after host restart and other critical lines that will hinder the agent to work?
i would need to seek my developer's help on this as i am not familiar with coding.
Thanks! :)
We have several implementations available for send_nrdp but here is the documentation for the shell version

https://exchange.nagios.org/directory/A ... nt/details

Re: Freshness check chg my service checks fr passive to acti

Posted: Wed Dec 05, 2018 8:28 pm
by charmainequek
hi scottwilkerson,

Thanks for the reply! May i know which line in the code will tell the host to restart the nrdp agent after the host is restarted?

Also, i encountered quite a few issues when i tried to do the config import. May i know if this is also related to the script? Below is one of the errors i see when i try to run the import.

Reading Configuration data...
Read main config file okay...
Error : Could not find any hostgroup matching 'hostgroup1' (Config file '/usr/local/nagios/etc/hosts/server1.cfg', starting on line 16)
Error : Failed to process hostgroup names for host 'server1' (config file '/usr/local/nagios/etc/hosts/server1.cfg', starting on line 16)
Error processing object config files!

Thanks!

Re: Freshness check chg my service checks fr passive to acti

Posted: Thu Dec 06, 2018 8:34 am
by scottwilkerson
charmainequek wrote:Thanks for the reply! May i know which line in the code will tell the host to restart the nrdp agent after the host is restarted?
The send_nrpd script isn't an agent, that runs by itself, this would need to be added to something to kick it off, such as a cron job.
charmainequek wrote:Also, i encountered quite a few issues when i tried to do the config import. May i know if this is also related to the script? Below is one of the errors i see when i try to run the import.

Reading Configuration data...
Read main config file okay...
Error : Could not find any hostgroup matching 'hostgroup1' (Config file '/usr/local/nagios/etc/hosts/server1.cfg', starting on line 16)
Error : Failed to process hostgroup names for host 'server1' (config file '/usr/local/nagios/etc/hosts/server1.cfg', starting on line 16)
Error processing object config files!

Thanks!
This looks like you have a host that has a hostgroup in it that is not configured, do you have a hostgroup1 hostgroup?

Re: Freshness check chg my service checks fr passive to acti

Posted: Thu Dec 06, 2018 11:40 pm
by charmainequek
hi scottwilkerson,

so do you mean use cron job to restart the agent?

And yes, i do have a host group called "hostgroup1".

Also, can you advise if it is normal to see a lot of this log lines in /var/log/httpd/error_log
[Fri Dec 07 09:59:26.604574 2018] [:error] [pid 187130] [client x.x.x.x:52021] PHP warning : mysqli_real_connect():(HY000/1040) : Too many connections in /usr/local/nagiosxi/html/db/adodb/drivers/adodb-mysqli.inc.php on line 125, referer : http://y.y.y.y/

x.x.x.x = client ip accessing NagiosXI
y.y.y.y = Nagios XI server ip

I am not sure if this is an issue as i see from my Nagios XI server 2 directories residing in /var/ were full and the nagios service was not running. I had to run a database repair and after the repair, the Nagios XI monitoring engine refused to start up.
I did a reboot on the Nagios XI server and could not log in to it anymore. It is bouncing back to the login gui page and does not accept my root credentials. the Centos 7 login gnome desktop shows "not listed" and when i click on the desktop the log in box appears but not able to login at all.

Please help..

Re: Freshness check chg my service checks fr passive to acti

Posted: Fri Dec 07, 2018 3:25 pm
by scottwilkerson
charmainequek wrote:so do you mean use cron job to restart the agent?
Which agent are you referring to?
charmainequek wrote:Also, can you advise if it is normal to see a lot of this log lines in /var/log/httpd/error_log
[Fri Dec 07 09:59:26.604574 2018] [:error] [pid 187130] [client x.x.x.x:52021] PHP warning : mysqli_real_connect():(HY000/1040) : Too many connections in /usr/local/nagiosxi/html/db/adodb/drivers/adodb-mysqli.inc.php on line 125, referer : http://y.y.y.y/
This can happen if your max+connections setting in /etc/my.cnf is too low or not present. Edit that file and under [mysqld] add

Code: Select all

max_connections=500
then restart mysqld

Code: Select all

service mysqld restart
charmainequek wrote:I did a reboot on the Nagios XI server and could not log in to it anymore. It is bouncing back to the login gui page and does not accept my root credentials. the Centos 7 login gnome desktop shows "not listed" and when i click on the desktop the log in box appears but not able to login at all.
This is a more concerning problem, if you cannot login to the Centos server I don't have a solution readily available for that as it is not related to Nagios XI directly, but to the OS, can you ssh to your server IP and login?