Also run the following commands and show the output:
Code: Select all
uname -a
cat /etc/*release
date
file /etc/localtime
cat /etc/sysconfig/clock
grep timezone /etc/php.ini
echo 'select now();'|mysql -t -u root -pnagiosxiCode: Select all
uname -a
cat /etc/*release
date
file /etc/localtime
cat /etc/sysconfig/clock
grep timezone /etc/php.ini
echo 'select now();'|mysql -t -u root -pnagiosxiWe're using the latest 5.2.3ssax wrote:What version of XI are you using? You can grab it from the bottom left hand side of the web interface. Maybe there's a known bug, I've seen this in older versions.
The likely issue is that the DB timestamp for last_modified date/time is either not being updated or is wrong.
What is the output of this:
- Note: Change CONFIGNAME to a config name of the services that are experiencing the issue
Code: Select all
echo "SELECT DATE_FORMAT(last_modified, '%Y-%m-%d %H:%i:%s'), service_description FROM tbl_service WHERE config_name = 'CONFIGNAME' ORDER BY last_modified DESC LIMIT 1;" | mysql -pnagiosxi nagiosql
Code: Select all
SELECT DATE_FORMAT(last_modified, '%Y-%m-%d %H:%i:%s'), host_name FROM tbl_host WHERE host_name = 'host-name' ORDER BY last_modified DESC LIMIT 1;
+-------------------------------------------------+--------------+
| DATE_FORMAT(last_modified, '%Y-%m-%d %H:%i:%s') | host_name |
+-------------------------------------------------+--------------+
| 2016-01-15 00:42:08 | host-name |
+-------------------------------------------------+--------------+
1 row in set (0.00 sec)I'm a little paranoid about posting profile screenshots, but relevant section is below:lmiltchev wrote:Go to Admin->System Profile->Show Profile and post a screenshot of the page.
Also run the following commands and show the output:
Is MySQL local or offloaded to a remote server? Are you using LiveStatus or Mod Gearman?Code: Select all
uname -a cat /etc/*release date file /etc/localtime cat /etc/sysconfig/clock grep timezone /etc/php.ini echo 'select now();'|mysql -t -u root -pnagiosxi
Code: Select all
Date/Time
PHP Timezone: America/Los_Angeles
PHP Time: Thu, 14 Jan 2016 17:11:03 -0800
System Time: Fri, 15 Jan 2016 01:11:03 +0000Code: Select all
CentOS release 6.7 (Final)Code: Select all
Fri Jan 15 01:19:15 UTC 2016Code: Select all
ZONE="America/Los_Angeles"Code: Select all
date.timezone = America/Los_AngelesCode: Select all
select now();
+---------------------+
| now() |
+---------------------+
| 2016-01-15 01:10:09 |
+---------------------+
1 row in set (0.00 sec)In order to fix this issue, please follow the steps outlined in our "Nagios XI – Changing The System Time" document:PHP Time: Thu, 14 Jan 2016 17:11:03 -0800
System Time: Fri, 15 Jan 2016 01:11:03 +0000
Well, that's by design. We keep all our servers in UTC, but services that interact with users are set to our local timezone (PST.)lmiltchev wrote:There is a mismatch between your PHP & System time...In order to fix this issue, please follow the steps outlined in our "Nagios XI – Changing The System Time" document:PHP Time: Thu, 14 Jan 2016 17:11:03 -0800
System Time: Fri, 15 Jan 2016 01:11:03 +0000
https://assets.nagios.com/downloads/nag ... m_Time.pdf
That worked, but now all times in the web interface are in UTC. Is there no way to keep the server time in UTC and change the web interface to local time (PST?)rkennedy wrote:As Nagios uses processes on a front end, and system services on the backend - this causes your timing to be off and could be why the configuration isn't applying as they like to stay in sync.
I believe this is related to those two times mismatching, can you adjust your system time to PST or visa-versa to test?
No I don't. Please close the thread. Thanks for your help!rkennedy wrote:At the time, there isn't. On the bright side, I have filed a feature request for this. ID 7509.
As the FR has been filed, and your original issue resolved - do you mind if I close this thread out?