Wrong recommendation for parameter slow_query_log in warning during startup
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
MariaDB |
New
|
Undecided
|
Unassigned |
Bug Description
When I start the database with
slow_query_log = 0
I get the following warning:
101231 8:15:06 [Warning] options --log-slow-
This is a wrong recommendation. log_slow_queries is deprecated slow_query_log should be used instead in the error message.
sql/mysqld.cc
9244 if ((opt_log_
9245 opt_log_
9246 !opt_slow_log)
9247 sql_print_
What further comes into my mind in this relation is if it makes sense at all to print this warning if I have explicitly mentioned slow_query_log = 0. Because then I have expressed my wish to disable the slow query log and should not be warned about.
Can we distinguish between "set to zero" and "not set at all" in the opt_slow_log variable? Then we could make the if in line 9244 a bit more sophisticated.
For example: ... && (opt_slow_log == NULL)
These warnings are very confusing.
When using log_slow_queries, I get the following message:
<pre>110526 11:37:49 [Warning] The syntax '--log_ slow_queries' is deprecated and will be removed in MySQL 7.0. Please use '--slow_ query_log' /'--log- slow-file' instead.</pre>
But if I follow that recommendation and change to slow_query_log, I get this warning. Not sure which combination is best/correct
<pre>110628 10:50:26 [Warning] options --log-slow- admin-statement s, --log-queries- not-using- indexes and --log-slow- slave-statement s have no effect if --log_slow_queries is not set</pre>