MySQL Slow query not working
Hi guys,
I notice the following today :
Tons of queries not slower than what I set in /etc/my.cnf
Any ideas why? I'm running the following mysql version: Server version: 5.6.16-cll-lve MySQL Community Server (GPL)
# Query_time: 0.000155 Lock_time: 0.000023 Rows_sent: 1 Rows_examined: 18Tons of queries not slower than what I set in /etc/my.cnf
slow-query-log = 1
slow-query-log-file = /var/log/mysql-slow.log
long_query_time = 20
log-queries-not-using-indexesAny ideas why? I'm running the following mysql version: Server version: 5.6.16-cll-lve MySQL Community Server (GPL)
-
Hello :) I have moved this thread into our "Optimization" forum. You are likely to receive more user-feedback here. Thank you. 0 -
Any ideas yet guys? Server version: 5.6.16-cll-lve MySQL Community Server (GPL) slow-query-log = 1 slow-query-log-file = /var/log/mysql-slow.log log-error = /var/log/mysqld.log long_query_time = 5 log-queries-not-using-indexes
I'm seeing these in slow query log all the time, looks like it's logging everything. :# User@Host: cphulkd[cphulkd] @ localhost [] Id: 1146 # Query_time: 0.000145 Lock_time: 0.000018 Rows_sent: 1 Rows_examined: 3 SET timestamp=1413611043; SELECT COUNT(*) FROM logins WHERE IP='' and LOGINTIME > FROM_UNIXTIME('1413610143'); # User@Host: cphulkd[cphulkd] @ localhost [] Id: 1146 # Query_time: 0.000122 Lock_time: 0.000026 Rows_sent: 1 Rows_examined: 3 SET timestamp=1413611043; SELECT COUNT(*) FROM logins WHERE USER='' AND STATUS=0 AND SERVICE='imap' AND LOGINTIME > FROM_UNIXTIME('1413610743'); # User@Host: cphulkd[cphulkd] @ localhost [] Id: 1146 # Query_time: 0.000152 Lock_time: 0.000026 Rows_sent: 1 Rows_examined: 3 SET timestamp=1413611043; SELECT COUNT(*) FROM logins WHERE USER='' AND STATUS=0 AND SERVICE='mail' AND LOGINTIME > FROM_UNIXTIME('1413610743'); # Time: 141018 7:44:05 # User@Host: cphulkd[cphulkd] @ localhost [] Id: 1149 # Query_time: 0.000148 Lock_time: 0.000028 Rows_sent: 1 Rows_examined: 3 SET timestamp=1413611045; SELECT COUNT(*) FROM logins WHERE IP='41.13.74.170' and LOGINTIME > FROM_UNIXTIME('1413610145'); # User@Host: cphulkd[cphulkd] @ localhost [] Id: 1149 # Query_time: 0.000113 Lock_time: 0.000024 Rows_sent: 1 Rows_examined: 3 SET timestamp=1413611045; SELECT COUNT(*) FROM logins WHERE USER='' AND STATUS=0 AND SERVICE='pop3' AND LOGINTIME > FROM_UNIXTIME('1413610745'); # User@Host: cphulkd[cphulkd] @ localhost [] Id: 1149 # Query_time: 0.000112 Lock_time: 0.000035 Rows_sent: 1 Rows_examined: 3 SET timestamp=1413611045; SELECT COUNT(*) FROM logins WHERE USER='' AND STATUS=0 AND SERVICE='mail' AND LOGINTIME > FROM_UNIXTIME('141360 -
Disable log-queries-not-using-indexes 0 -
Thanks that worked. What is a reasonable setting for slow query time? I have mine on 5 seconds? Is this good enough for shared hosting? 0
Please sign in to leave a comment.
Comments
4 comments