Comment 15 for bug 1372501

Revision history for this message
Jose Cavieres (jcavieres) wrote : Re: [Bug 1372501] Re: INSERT with NOW() gives incorrect timestamp

Se use the C connector.

JCS
El 18 feb. 2016 7:01 AM, "Jervin R" <email address hidden> escribió:

> Jose, Bram - gotcha - I am trying to reproduce this using some simple
> scripts. It seems MGC 10.0.21 and PXC 5.6.22 are the highest versions
> affected - anyone running higher? Aside from Java, anyone using PHP or
> something else for the persistent connections?
>
> --
> You received this bug notification because you are subscribed to a
> duplicate bug report (1453964).
> https://bugs.launchpad.net/bugs/1372501
>
> Title:
> INSERT with NOW() gives incorrect timestamp
>
> Status in Percona Server:
> New
> Status in Percona XtraDB Cluster:
> Incomplete
>
> Bug description:
> Had a very strange issue today.
>
> From a C program (using libmysqlclient) I am executing queries like
> INSERT INTO ... (t, ..) VALUES (NOW(), ...)
> And similarly UPDATE .... WHERE ..=NOW()
>
> For the past 12 hours or so all NOW() statements resulted in a
> TIMESTAMP of '2014-09-22 05:17:03' in the database fields.
>
> Yeah... "huh!?"... like after that time the time stood still...
>
> Just to be clear: the machine is running NTP and I checked the date
> manually, it's perfectly synchronized.
>
> Presumably NOW() is not expanded on the client-side right? So my
> libmysqlclient application can't be blamed, correct?
> Must be the SQL server / Percona then?
>
> I restarted the client application - which closed the connection to
> the SQL server and reinitiated it - and the bug disappeared... or at
> least for now.
>
> Using ubuntu:
> i percona-xtrabackup 2.2.3-4982-1.trusty
> amd64 Open source backup tool for InnoDB and XtraDB
> ii percona-xtradb-cluster-56 5.6.20-25.7-886.trusty
> amd64 Percona XtraDB Cluster with Galera
> ii percona-xtradb-cluster-client-5.6 5.6.20-25.7-886.trusty
> amd64 Percona XtraDB Cluster database client binaries
> ii percona-xtradb-cluster-common-5.6 5.6.20-25.7-886.trusty
> amd64 Percona XtraDB Cluster database common files (e.g.
> /etc/mysql/my.cnf)
> ii percona-xtradb-cluster-galera-3 3.7.3256.trusty
> amd64 Metapackage for latest version of galera3.
> ii percona-xtradb-cluster-galera-3.x 3.7.3256.trusty
> amd64 Galera components of Percona XtraDB Cluster
> ii percona-xtradb-cluster-server-5.6 5.6.20-25.7-886.trusty
> amd64 Percona XtraDB Cluster database server binaries
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/percona-server/+bug/1372501/+subscriptions
>