Start slave IO_THREAD in mysqldump output

Bug #766681 reported by MikeG
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
holland-backup
Won't Fix
Undecided
Unassigned

Bug Description

To immediately start queuing the master logs during a slave initialization from a master-data dump, it would be nice to optionally inject START SLAVE IO_THREAD after the CHANGE MASTER TO MASTER_LOG_FILE ...

This would presumably fail if the slave had not first had CHANGE MASTER TO MASTER_HOST, MASTER_USER, MASTER_PASSWORD but perhaps that is a feature since you then avoid having to manually extract the CHANGE from the dump file and worse forget to do so starting at the master's first available.

Revision history for this message
m00dawg (tim-moocowproductions) wrote :

It sounds like a good idea - I'm just trying to think of some of the edge cases. So far the worst case I can think of is queueing logs one might not use (such as when doing point-in-time-recovery). I think this should be a feature that must be enabled (ie not default) so at least people that turn it on should have an idea of what they are getting into?

Revision history for this message
MikeG (mikegriffin) wrote :

I said optionally.. :)

Revision history for this message
Andrew Garner (muzazzi) wrote :

I think this would be a better fit for some front-end script that assist with the restore (maybe a holland restore ... command). I don't think we should be messing with mysqldump's standard output at backup time at any rate.

For an example of how I might envision a restore script working you can see the holland_restore experiment for mysqldump I have here:

https://github.com/abg/holland_restore

I just implemented this basic idea:

$ mysqlrestore --start-slave-early < sakila.binlog.sql > sakila.binlog.io_thread.sql

$ diff -u sakila.binlog.sql sakila.binlog.io_thread.sql
--- sakila.binlog.sql 2011-04-19 21:31:59.000000000 -0400
+++ sakila.binlog.io_thread.sql 2011-04-19 21:41:10.000000000 -0400
@@ -20,6 +20,7 @@
--

CHANGE MASTER TO MASTER_LOG_FILE='bin-log.000001', MASTER_LOG_POS=106;
+START SLAVE IO_THREAD;

--
-- Table structure for table `actor`
$

Revision history for this message
Andrew Garner (muzazzi) wrote :

This has been open a while and I am going to reject this right now. I don't want holland to get into the business of modifying mysqldump output directly.

Changed in holland-backup:
status: New → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.