Hello!
Hobocopy looks like very good tool for hot backing up working database under Windows.
It can be done straightly. However, to keep data consistency, it is better to provide some prepearing of DB before copying will be started.
Here is full scenario:
1. Flush and lock all DB tables via "FLUSH TABLES WITH READ LOCK".
2. Make Shadow Snapshot (takes a bit of time).
3. Unlock DB tables.
4. Copy DB files from Shadow Snapshot (can take a lot of time).
With such scenario DB will be in read-only state for a short time suitable to keep normal work conditions.
The question is: how to get some "Shadow Snapshot is done" signal from hobocopy?
With it the practical scenario will be next:
1. Flush and lock all DB tables via "FLUSH TABLES WITH READ LOCK". DB switched into read-only state.
2. Run hobocopy.
2a. Asynchronously wait for hobocopy to make Shadow Snapshot.
3. Unlock DB tables (hobocopy still works). DB returns into fully working state.
4. Hobocopy are copying DB files from Shadow Snapshot.
The only way to wait "Shadow Snapshot is done" signal which I see now is to switch hobocopy verbosity to 4, send hobocopy console output into file or stream and wait for "Call to DoSnapshotSet finished." line in it. Not bad solution but slightly "duct-tapish".
Any thoughts?
Thanks!