Page 1 of 1

ZoneMinder is not installed properly: php's date.timezone is not set to a valid timezone

Posted: Wed Feb 01, 2017 1:07 am
by tedukes
Hello,

Been using zoneminder for years.

I did a fresh install of CentOS 7.3 last Wednesday and installed zoneminder 1.30 from the centos repo.

Has been running fine until today.

Around 12:15 today, I began getting the error: ZoneMinder is not installed properly: php's date.timezone is not set to a valid timezone

The timezone is correctly set in php.ini

[Date]
; Defines the default timezone used by the date functions
; http://php.net/date.timezone
date.timezone = America/New_York

ll /etc/localtime

lrwxrwxrwx. 1 root root 38 Jan 25 19:05 /etc/localtime -> ../usr/share/zoneinfo/America/New_York

Here's where it started:

Jan 31 12:15:19 ts130 zmc_dvideo0[13838]: INF [Den: 57000 - Capturing at 29.41 fps]
Jan 31 12:15:19 ts130 zmc_dvideo1[13864]: INF [Deck: 57000 - Capturing at 30.30 fps]
Jan 31 12:15:19 ts130 zmc_dvideo2[13890]: INF [Front: 57000 - Capturing at 30.30 fps]
Jan 31 12:15:19 ts130 zma_m1[13847]: INF [Den: 57000 - Analysing at 30.30 fps]
Jan 31 12:15:20 ts130 zmc_dvideo3[13917]: INF [Street: 57000 - Capturing at 29.41 fps]
Jan 31 12:15:20 ts130 zma_m2[13873]: INF [Deck: 57000 - Analysing at 29.41 fps]
Jan 31 12:15:20 ts130 zma_m3[13899]: INF [Front: 57000 - Analysing at 29.41 fps]
Jan 31 12:15:20 ts130 zma_m4[13925]: INF [Street: 57000 - Analysing at 30.30 fps]
Jan 31 12:15:41 ts130 web_php[15770]: FAT [ZoneMinder is not installed properly: php's date.timezone is not set to a valid timezone]
Jan 31 12:15:46 ts130 web_php[15770]: FAT [ZoneMinder is not installed properly: php's date.timezone is not set to a valid timezone]
Jan 31 12:15:47 ts130 web_php[15770]: FAT [ZoneMinder is not installed properly: php's date.timezone is not set to a valid timezone]
Jan 31 12:15:52 ts130 zmc_dvideo0[13838]: INF [Den: 58000 - Capturing at 30.30 fps]
Jan 31 12:15:52 ts130 zmc_dvideo1[13864]: INF [Deck: 58000 - Capturing at 30.30 fps]
Jan 31 12:15:53 ts130 zmc_dvideo2[13890]: INF [Front: 58000 - Capturing at 29.41 fps]
Jan 31 12:15:53 ts130 zma_m1[13847]: INF [Den: 58000 - Analysing at 29.41 fps]
Jan 31 12:15:53 ts130 zmc_dvideo3[13917]: INF [Street: 58000 - Capturing at 30.30 fps]
Jan 31 12:15:53 ts130 zma_m2[13873]: INF [Deck: 58000 - Analysing at 30.30 fps]
Jan 31 12:15:53 ts130 zma_m3[13899]: INF [Front: 58000 - Analysing at 30.30 fps]

There is only one version of php installed.

Been working on this since it started. I'm stuck.

Any help would be greatly appreciated.

Re: ZoneMinder is not installed properly: php's date.timezone is not set to a valid timezone

Posted: Wed Feb 01, 2017 7:42 am
by PacoLM
Hi,
There is only one version of php installed.
Are you 100% sure? I have a dedicated server with only the basics packages and I have 4 php.ini files on my computer (Ubuntu 14.04)
/etc/php5/cgi/php.ini
/etc/php5/apache2/php.ini
/etc/php5/fpm/php.ini
/etc/php5/cli/php.ini

You could find more files called php.ini by issuing the command find / -name php.ini (just trying to help here, do not know your linux skills).
On my system, the timezone is set on 3 out of 4 files:
$ grep timezone /etc/php5/apache2/php.ini
date.timezone = "Europe/Madrid"
$ grep timezone /etc/php5/cgi/php.ini
;date.timezone =
$ grep timezone /etc/php5/fpm/php.ini
date.timezone = "Europe/Madrid"
$ grep timezone /etc/php5/cli/php.ini
date.timezone = "Europe/Madrid"

So I would do those checks, maybe you need to setup your timezone in more than one file.

Hope it helps,

PacoLM

Re: ZoneMinder is not installed properly: php's date.timezone is not set to a valid timezone

Posted: Wed Feb 01, 2017 12:27 pm
by tedukes
I ran locate php.ini and didn't find anything except one that is in a backup directory/partition I made after I backed up my old 6.8 system and did a fresh install of 7.3 I extracted the backup to help configure the new system.

phpinfo.php reports its using /etc/php.ini

I ran the command you provided and got the same result.

Something seems to be overridding it.

Thanks

[SOLVED] Re: ZoneMinder is not installed properly: php's date.timezone is not set to a valid timezone

Posted: Wed Feb 01, 2017 3:14 pm
by tedukes
Added

php_value date.timezone "America/New_York"

to /etc/http/conf.modules.d/10-php.conf

Re: ZoneMinder is not installed properly: php's date.timezone is not set to a valid timezone

Posted: Fri Feb 03, 2017 5:23 am
by qudo
Hi I having the same problem with my rasbian installation.