PHP Fatal Error - strtotime - Timezone database is corrupt

Post support questions that directly relate to Linux/Unix operating systems.

Moderators: Developers, Moderators

Post Reply
stageman
Posts: 5
Joined: Mon Jun 08, 2009 12:28 am

PHP Fatal Error - strtotime - Timezone database is corrupt

Post by stageman »

I'm not exactly sure when this started happening. I'm guessing it happened when I updated my server to CentOS 5.3. But whenever it started, I am now getting the following error when I try to bring up cacti:

Code: Select all

[Sun Jun 07 23:24:17 2009] [error] [client 192.168.15.141] PHP Fatal error:  strtotime() [<a href='function.strtotime'>function.strtotime</a>]: Timezone database is corrupt - this should *never* happen! in /var/www/netstats/pub-html/cacti/include/global_constants.php on line 156
I have looked high and low for an answer. I've tried to set the default timezone in php.ini as described here: Link

Basically they want you to try and install the database using pecl. This fails.

Code: Select all

pecl install timezonedb          
downloading timezonedb-2009.8.tgz ...
Starting to download timezonedb-2009.8.tgz (195,596 bytes)
.............................done: 195,596 bytes

Fatal error: strtotime(): Timezone database is corrupt - this should *never* happen! in /usr/share/pear/PEAR/Validate.php on line 486
I also tried to set a default timezone in php.ini.

Help...

Some vitals:

CentOS 5.3
cacti 0.87d
apache 2.2.3-22
php 5.1.6
mysql 5.0.45
stageman
Posts: 5
Joined: Mon Jun 08, 2009 12:28 am

Post by stageman »

Thanks to anyone that looked at this. I searched and searched and finally came across someone that installed the PHP 5.2.9 packages from here and everything is working normally now. Of note, I also discovered once I got back into the web interface that cacti had died altogether. So I lost all of my data during the time this issue was happening.
User avatar
TheWitness
Developer
Posts: 17007
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Sorry to hear that. In the future, you should always have one production system and one test system to test things out on. Servers are a dime a dozen these days, and it's worth the investment.

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests