默认是 10s ,改为 200ms
mysql> show global variables like 'long_query_time%'; +-----------------+-----------+ | Variable_name | Value | +-----------------+-----------+ | long_query_time | 10.000000 | +-----------------+-----------+ 1 row in set (0.01 sec) mysql> set global long_query_time=0.2; Query OK, 0 rows affected (0.01 sec) mysql> show global variables like 'long_query_time%'; +-----------------+----------+ | Variable_name | Value | +-----------------+----------+ | long_query_time | 0.200000 | +-----------------+----------+ 1 row in set (0.00 sec)
Leave a Reply