Bug #33565 Backup: question marks in processlist
Submitted: 29 Dec 2007 0:19 Modified: 28 Feb 2008 18:00
Reporter: Peter Gulutzan Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Server: Backup Severity:S3 (Non-critical)
Version:6.0.5-alpha-debug OS:Linux (SUSE 10 64-bit)
Assigned to: Chuck Bell CPU Architecture:Any

[29 Dec 2007 0:19] Peter Gulutzan
Description:
SHOW PROCESSLIST shows nothing but '?'s in the Info column,
when RESTORE is happening.

Built from mysql-6.0-backup source with BUILD/compile-pentium-debug-max.
Last changeset = "ChangeSet@1.2753, 2007-12-20 15:32:22-05:00".

How to repeat:
Start two connections. Call them T1 and T2.

On T1, say:
CREATE DATABASE x;
USE x
CREATE TABLE t (s1 INT);
INSERT INTO t VALUES (1),(2),(3),(4),(5);
INSERT INTO t SELECT * FROM t;
INSERT INTO t SELECT * FROM t;
INSERT INTO t SELECT * FROM t;
INSERT INTO t SELECT * FROM t;
INSERT INTO t SELECT * FROM t;
INSERT INTO t SELECT * FROM t;
INSERT INTO t SELECT * FROM t;
INSERT INTO t SELECT * FROM t;
INSERT INTO t SELECT * FROM t;
INSERT INTO t SELECT * FROM t;
INSERT INTO t SELECT * FROM t;
INSERT INTO t SELECT * FROM t;
INSERT INTO t SELECT * FROM t;
INSERT INTO t SELECT * FROM t;
/* enough rows so that RESTORE will be slow */
BACKUP DATABASE x TO '/usr/local/mysql/var/t8';
DROP DATABASE x;
RESTORE FROM '/usr/local/mysql/var/t8';

On T2, say:
SELECT SLEEP(5);
SHOW PROCESSLIST;

This is the result that I usually see:

mysql> show processlist;
+----+------+-----------+------+---------+------+-------+-------------------+
| Id | User | Host      | db   | Command | Time | State | Info              |
+----+------+-----------+------+---------+------+-------+-------------------+
|  1 | root | localhost | x    | Query   |   13 | NULL  | h4z????????????Q |
|  2 | root | localhost | x    | Query   |    0 | NULL  | show processlist  |
+----+------+-----------+------+---------+------+-------+-------------------+
2 rows in set (0.00 sec)
[29 Dec 2007 5:40] MySQL Verification Team
Thank you for the bug report.
[24 Jan 2008 18:09] Chuck Bell
This bug is fixed by BUG#32970. Once that patch is made, the process list correctly identifies the backup command and the locking thread(s).

Will reverify once BUG#32970 is pushed.
[28 Feb 2008 18:00] Chuck Bell
Cannot reproduce the bug using latest tree. The bug did appear in previous trees. Conclusion: BUG#32970 fixed this bug. Recommend close this bug.