PHP Warning:
Strtotime (): It isn't safe to rely on the system's timezone settings. You are are *required* to use the Date.timezone setting or the Date_default_timezone_set () function. In case you are used any of those methods and your are still getting this warning, for you most likely misspelled the timezone Iden Tifier. We selected ' asia/chongqing ' for ' cst/8.0/no DST ' instead in/var/www/cacti/index.php
Looked up some information, said that the PHP version is too high, in the new version must specify timezone and so on.
The specific mode of operation is as follows:
1, in the PHP configuration file to add TimeZone configuration(Refer to Debian configuration rules, add a small configuration rule file, good maintenance, customization good)
~# Vim/etc/php/cli-php5.3/ext-active/date_timezone.ini
Date.timezone = "Asia/shanghai"
~ # Env-update
~ # Source/etc/profile
The custom files are placed in the Cli-php5.3/ext-active directory because PHP is by default CLI, and the Ext-active directory is a private directory that represents the enabled feature, which can be seen from the/etc/env.d/20php5.3 file
Manpath= "/usr/lib/php5.3/man/"
config_protect_mask= "/etc/php/cli-php5.3/ext-active//etc/php/cgi-php5.3/ext-active//etc/php/apache2-php5.3/ ext-active/"
2, in the error prompted the php file to add date_default_timezone_set (' Asia/shanghai '); location in Shanghai, China
Note:
In some references it is said that the two methods can be selected, but after my test, two methods must be used at the same time, no more error prompts.
In fact, the second method does not need to be added in each PHP file with error prompts, just add it to one of the PHP files. Additional time zones do not need to be the same as the time zone in the hint, such as the system gave me the hint is Chongqing, but I set to Shanghai is the same, of course, this time is the same as my system's time zone settings are the same.