New services not showing up in XI

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
amybrown
Posts: 22
Joined: Tue Oct 25, 2011 3:59 pm

New services not showing up in XI

Post by amybrown »

Relevant info: NagiosXI 2012R2.4 on a RHEL 5.9 x64 physical server. (I will include the system profile info at the end)

The weekend before last (Sept 21st) I patched my RHEL server and PHP was updated. A few days later (the 25th) my Nagios site completely died. I downloaded the update to Nagios and that appears to have corrected the problem. I'm concerned there is still a problem with PHP and Nagios, though. I've added a handful of new services over the past week and they show up in the Core Config manager as active, but they do not show up on the NagiosXI site under the normal lists of hosts/services. I was getting countless php messages about deprecated code, so I've got logging disabled currently in the php.ini file. I've restarted the NagiosXI process on the host, and the monitoring enginer and db through the NagiosXI website.

Any idea on how to get all my services to show up?

------------------------------------------
System Profile
------------------------------------------
Nagios XI Installation Profile

Download Profile
System:

Nagios XI Version : 2012R2.4
<servername redacted> 2.6.18-348.4.1.el5 x86_64
Red Hat Enterprise Linux Server release 5.9 (Tikanga)
Gnome Installed
Apache Information

PHP Version: 5.4.19
Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/29.0.1547.76 Safari/537.36
Server Name: <redacted>
Server Address: <redacted>
Server Port: 80
Date/Time

PHP Timezone: UTC
PHP Time: Mon, 30 Sep 2013 18:48:09 +0000
System Time: Mon, 30 Sep 2013 13:48:09 -0500
Nagios XI Data

nagios (pid 22538) is running...
NPCD running (pid 6123).
ndo2db (pid 22290) is running...
CPU Load 15: 0.08
Total Hosts: 29
Total Services: 420
Function 'get_base_uri' returns: http://hostname/nagiosxi/
Function 'get_base_url' returns: http://hostname/nagiosxi/
Function 'get_backend_url(internal_call=false)' returns: http://hostname/nagiosxi/includes/compo ... rofile.php
Function 'get_backend_url(internal_call=true)' returns: http://localhost/nagiosxi/backend/
Ping Test localhost

Running:
/bin/ping -c 3 localhost 2>&1
PING hostname (127.0.0.1) 56(84) bytes of data.
64 bytes from hostname (127.0.0.1): icmp_seq=1 ttl=64 time=0.035 ms
64 bytes from hostname (127.0.0.1): icmp_seq=2 ttl=64 time=0.013 ms
64 bytes from hostname (127.0.0.1): icmp_seq=3 ttl=64 time=0.034 ms

--- hostname ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2000ms
rtt min/avg/max/mdev = 0.013/0.027/0.035/0.011 ms
Test wget To locahost

WGET From URL: http://localhost/nagiosql/index.php
Running:
/usr/bin/wget http://localhost/nagiosql/index.php
--2013-09-30 13:48:11-- http://localhost/nagiosql/index.php
Resolving localhost... 127.0.0.1
Connecting to localhost|127.0.0.1|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 5259 (5.1K) [text/html]
Saving to: `/tmp/nagiosql_index.tmp'

0K ..... 100% 334M=0s

2013-09-30 13:48:11 (334 MB/s) - `/tmp/nagiosql_index.tmp' saved [5259/5259]
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: New services not showing up in XI

Post by slansing »

Can you navigate to Admin > System Profile > download and PM the zip file to me? Do your apply configurations go through clean? And have you followed the repairing the xi database.documentation found at library.nagios.com?
amybrown
Posts: 22
Joined: Tue Oct 25, 2011 3:59 pm

Re: New services not showing up in XI

Post by amybrown »

Will do on the zip file.

Config updates go through cleanly, no errors. I have not done the db repair stuff. I will go look at that.

ETA: I'll need to schedule some downtime to do the db repair. I'll try and do that this evening.

~amy
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: New services not showing up in XI

Post by sreinhardt »

Great, let us know how it goes and issues still persist.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
amybrown
Posts: 22
Joined: Tue Oct 25, 2011 3:59 pm

Re: New services not showing up in XI

Post by amybrown »

Well, I backed up everything, then did the mysql repair tool and restarted mysql... the issue still persists. :( Any other ideas? I am going to go ahead and reboot the system, while I have this downtime window.

ETA: A reboot did not magically fix anything, sadly. I have an open change window for the next 2 hours...
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: New services not showing up in XI

Post by sreinhardt »

Could you send us a sample of the deprecated code complaints? We have run through some of the php 5.4 changes before, but that was well before 2.4 and should not be impacting anything at this point. It is certainly possible. Once I get a sample of your log, I can look through the revision history and take a look.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
amybrown
Posts: 22
Joined: Tue Oct 25, 2011 3:59 pm

Re: New services not showing up in XI

Post by amybrown »

Here's a small snippet.. this will just roll non-stop until I turn logging back off in php.ini:

===================================================
[Tue Oct 01 09:06:01 2013] [error] [client #.#.#.#] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260, referer: http://hostname/nagiosxi/index.php?
[Tue Oct 01 09:06:01 2013] [error] [client #.#.#.#] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260, referer: http://hostname/nagiosxi/index.php?
[Tue Oct 01 09:06:01 2013] [error] [client #.#.#.#] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260, referer: http://hostname/nagiosxi/index.php?
[Tue Oct 01 09:06:01 2013] [error] [client #.#.#.#] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260, referer: http://hostname/nagiosxi/index.php?
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Deprecated: mysql_escape_string(): This function is deprecated; use mysql_real_escape_string() instead. in /usr/local/nagiosxi/html/includes/db.inc.php on line 326
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Deprecated: mysql_escape_string(): This function is deprecated; use mysql_real_escape_string() instead. in /usr/local/nagiosxi/html/includes/db.inc.php on line 326
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Strict Standards: Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/db.inc.php on line 260
[Tue Oct 01 09:06:01 2013] [error] [client #.#.#.#] PHP Deprecated: mysql_escape_string(): This function is deprecated; use mysql_real_escape_string() instead. in /usr/local/nagiosxi/html/includes/db.inc.php on line 326, referer: http://hostname/nagiosxi/index.php?
[Tue Oct 01 09:06:01 2013] [error] [client #.#.#.#] PHP Deprecated: mysql_escape_string(): This function is deprecated; use mysql_real_escape_string() instead. in /usr/local/nagiosxi/html/includes/db.inc.php on line 326, referer: http://hostname/nagiosxi/index.php?
[Tue Oct 01 09:06:01 2013] [error] [client #.#.#.#] PHP Deprecated: mysql_escape_string(): This function is deprecated; use mysql_real_escape_string() instead. in /usr/local/nagiosxi/html/includes/db.inc.php on line 326, referer: http://hostname/nagiosxi/index.php?
[Tue Oct 01 09:06:01 2013] [error] [client #.#.#.#] PHP Deprecated: mysql_escape_string(): This function is deprecated; use mysql_real_escape_string() instead. in /usr/local/nagiosxi/html/includes/db.inc.php on line 326, referer: http://hostname/nagiosxi/index.php?
[Tue Oct 01 09:06:01 2013] [error] [client #.#.#.#] PHP Deprecated: mysql_escape_string(): This function is deprecated; use mysql_real_escape_string() instead. in /usr/local/nagiosxi/html/includes/db.inc.php on line 326, referer: http://hostname/nagiosxi/index.php?
[Tue Oct 01 09:06:01 2013] [error] [client #.#.#.#] PHP Deprecated: mysql_escape_string(): This function is deprecated; use mysql_real_escape_string() instead. in /usr/local/nagiosxi/html/includes/db.inc.php on line 326, referer: http://hostname/nagiosxi/index.php?
[Tue Oct 01 09:06:01 2013] [error] [client 127.0.0.1] PHP Deprecated: mysql_escape_string(): This function is deprecated; use mysql_real_escape_string() instead. in /usr/local/nagiosxi/html/includes/db.inc.php on line 326

ETA: I can PM you a larger log if you'd like.
User avatar
lmiltchev
Former Nagios Staff
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: New services not showing up in XI

Post by lmiltchev »

When you say
...the issue still persists.
do you mean that new services are still not showing up in the Web interface, or you mean that you are still getting the php errors in the logs?
This may be completely unrelated, but have you made sure that your php and system time is synced? According to the system profile, there is 5 hours difference:
PHP Time: Mon, 30 Sep 2013 18:48:09 +0000
System Time: Mon, 30 Sep 2013 13:48:09 -0500
You will need to fix that.
Be sure to check out our Knowledgebase for helpful articles and solutions!
amybrown
Posts: 22
Joined: Tue Oct 25, 2011 3:59 pm

Re: New services not showing up in XI

Post by amybrown »

New services/hosts still do not show up in NagiosXI. They do show (and show as active) in the Core config manager.

As for PHP time...
PHP Timezone: UTC
PHP Time: Tue, 01 Oct 2013 21:08:35 +0000
System Time: Tue, 01 Oct 2013 16:08:35 -0500
PHP is using UTC, while my box is using CDT... if that is a problem, how would I change it? That's not something I ever altered.
amybrown
Posts: 22
Joined: Tue Oct 25, 2011 3:59 pm

Re: New services not showing up in XI

Post by amybrown »

I did go ahead and alter the php.ini file to use the appropriate timezone... the system profile now shows:
PHP Timezone: America/Chicago
PHP Time: Tue, 01 Oct 2013 16:11:22 -0500
System Time: Tue, 01 Oct 2013 16:11:22 -0500
Locked