Details
-
Type:
Bug
-
Status: Open
-
Priority:
Minor
-
Resolution: Unresolved
-
Affects Version/s: 5.5.29
-
Fix Version/s: 5.5
-
Component/s: None
-
Labels:None
Description
If I add a column to mysql.user and set a user's MAX_QUERY_TIME, it is obviously stored, since it survives server restart; but the value is not shown in the result set of SELECT from mysql.user – max_query_timeout there is NULL.
The test below is pretty much the same as in the original patch, I've only added two SELECTs, before and after server restart:
Test output:
ALTER TABLE mysql.user ADD max_query_timeout decimal(14,6) AFTER max_user_connections; FLUSH PRIVILEGES; GRANT USAGE ON *.* TO user1@localhost WITH MAX_QUERY_TIME 1.005; SELECT user, host, max_query_timeout FROM mysql.user WHERE user='user1'; user host max_query_timeout user1 localhost NULL connect con1,localhost,user1,,test,,; SELECT @@max_query_time; @@max_query_time 1.005000 disconnect con1; # restart and reconnect connection default; SELECT user, host, max_query_timeout FROM mysql.user WHERE user='user1'; user host max_query_timeout user1 localhost NULL connect con1,localhost,user1,,test,,; SELECT @@global.max_query_time,@@session.max_query_time; @@global.max_query_time @@session.max_query_time 0.000000 1.005000 disconnect con1;
Test code:
--enable_connect_log ALTER TABLE mysql.user ADD max_query_timeout decimal(14,6) AFTER max_user_connections; FLUSH PRIVILEGES; GRANT USAGE ON *.* TO user1@localhost WITH MAX_QUERY_TIME 1.005; SELECT user, host, max_query_timeout FROM mysql.user WHERE user='user1'; connect(con1,localhost,user1,,test,,); SELECT @@max_query_time; disconnect con1; --echo # restart and reconnect connection default; source include/restart_mysqld.inc; SELECT user, host, max_query_timeout FROM mysql.user WHERE user='user1'; connect(con1,localhost,user1,,test,,); SELECT @@global.max_query_time,@@session.max_query_time; disconnect con1;
revision-id: monty@askmonty.org-20130103201517-ovawwss2pxed09tu revno: 3612 branch: maria-5.5-monty
Gliffy Diagrams
Attachments
Issue Links
- relates to
-
MDEV-6963
Testing for max_query_time
-
- Open
-
Activity
- All
- Comments
- Work Log
- History
- Activity
- Transitions