Bug #84575 Needs "LOCAL" for FLUSH TABLES (mysqldump --single-transaction --flush-logs)
| Submitted: | 20 Jan 2017 2:08 | Modified: | 7 Feb 2017 22:42 |
|---|---|---|---|
| Reporter: | SeWoong Jeon | Email Updates: | |
| Status: | Not a Bug | Impact on me: | |
| Category: | MySQL Server: mysqldump Command-line Client | Severity: | S3 (Non-critical) |
| Version: | 5.7 | OS: | Any |
| Assigned to: | MySQL Verification Team | CPU Architecture: | Any |
[7 Feb 2017 22:42]
MySQL Verification Team
Hi, That's not a bug, it's intentional. We can argue if the intention/design is good or bad but it is intentional. And since there is a simple way to have the LOCAL flush I don't see a problem there. We anyhow suggest you move away from mysqldump and use mysqlbackup. all best Bogdan
Portions of this website are copyright © 2001, 2002 The PHP Group
Page generated in 0.039 sec. using MySQL 8.4.7-u6-cloud
Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the
respective copyright holders.
It is not reviewed in advance
by Oracle and does not necessarily represent the opinion of
Oracle or any other party.
Description: when --single-transaction, --flush-logs and --master-data are used together, "FLUSH LOCAL TABLES" query is performed. however, when only --single-transaction and --flush-logs are used, a "FLUSH TABLES" query is performed, it seems enough to use "FLUSH LOCAL TABLES". How to repeat: Execute "mysqldump --single-transaction --flush-logs" without --master-data Suggested fix: client/mysqldump.c return ( mysql_query_with_error_report(mysql_con, 0, - ((opt_master_data != 0) ? + ((opt_master_data != 0 || (opt_single_transaction && flush_logs)) ? "FLUSH /*!40101 LOCAL */ TABLES" : "FLUSH TABLES")) || mysql_query_with_error_report(mysql_con, 0, "FLUSH TABLES WITH READ LOCK") );