Bug #69399 Inconsistency in crash report
Submitted: 4 Jun 2013 17:21 Modified: 5 Jun 2013 12:50
Reporter: Valeriy Kravchuk Email Updates:
Status: Won't fix Impact on me:
Category:MySQL Server: Errors Severity:S3 (Non-critical)
Version:5.5.x, 5.6.x OS:Any
Assigned to: CPU Architecture:Any
Tags: crash, error, UTC

[4 Jun 2013 17:21] Valeriy Kravchuk
In case of crashes time reported in one place in the error log is inconsistent with others. UTC is used for a message about signal, while local time is used in other messages, like this:

00:41:38 UTC - mysqld got signal 11 ;
This could be because you hit a bug. It is also possible that this binary
or one of the libraries it was linked against is corrupt, improperly built,
or misconfigured. This error can also be caused by malfunctioning hardware.
We will try our best to scrape up some info that will hopefully help
diagnose the problem, but since we have already crashed,
something is definitely wrong and this may fail.

It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 1013437 K  bytes of memory
Hope that's ok; if not, decrease some variables in the equation.

Thread pointer: 0x268bbc0
Attempting backtrace. You can use the following information to find out
where mysqld died. If you see no messages after this, something went
terribly wrong...
stack_bottom = 7f460720ce48 thread_stack 0x40000

Trying to get some variables.
Some pointers may be invalid and cause the dump to abort.
Query (26969b0): UPDATE t1 JOIN t1fed ON t1.id = t1fed.id SET t1fed.message = t1.message
Connection ID (thread ID): 40

The manual page at http://dev.mysql.com/doc/mysql/en/crashing.html contains
information that should help you find out what is causing the crash.
130212 19:41:38 mysqld_safe Number of processes running now: 0
130212 19:41:38 mysqld_safe mysqld restarted

(this is from my favorite bug #68354). Note this:

00:41:38 UTC - mysqld got signal 11 ;

and compare to other messages:

130212 19:41:38 mysqld_safe Number of processes running now: 0
130212 19:41:38 mysqld_safe mysqld restarted

It's UTC (and only time) vs local date and time in timestamp.

How to repeat:
Crash any version of MySQL server and check. Use test case from bug #68354 if in doubts on how to crash MySQL...

Suggested fix:
Use consistent format all over the error log? Print UTC time upon server startup as additional message if you consider this essential.
[4 Jun 2013 17:54] MySQL Verification Team
Likely not a bug.  The thing is, signal handler must use approved safe functions or risk causing a crash itself... "time()" is safe but returns UTC.  Do you have a suggestion what can be used in its place?

http://bugs.mysql.com/bug.php?id=54082 for details.
[5 Jun 2013 12:50] MySQL Verification Team
This behavior is intentional and will not be changed. 
Functions called from signal handlers must be async signal safe...