Author Topic: DB Time Differs From PHP?  (Read 3537 times)

Offline CarlosinFL

  • Full Member
  • ***
  • Posts: 78
DB Time Differs From PHP?
« on: December 19, 2012, 03:37:16 PM »
When installing RoundCube today, the installer informed me:

Code: [Select]
Check DB config
DSN (write):  OK
DB Schema:  OK
DB Write:  OK
DB Time:  NOT OK(Database time differs s from PHP time)

My web, db, and mail are all three unique machines. Who do I need to check the PHP time on? The db server running PostgreSQL 9.2? The web server running Apache / PHP / RoundCube? Or the mail server running Postfix? I'm guessing it's the time on the web server which has PHP installed. But how do I resolve this? My database server is using NTP and looks perfect.

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,882
    • SKaero - Custom Roundcube development
Re: DB Time Differs From PHP?
« Reply #1 on: December 20, 2012, 09:57:02 AM »
That error is odd, what do you get if you run the following query on the PostgreSQL server?
Code: [Select]
SELECT EXTRACT(EPOCH FROM DATE_TRUNC('seconds', CAST ((CURRENT_TIMESTAMP) AS TIMESTAMP)))  AS tz_db;