Quote:
Originally Posted by ArcaneMagus y@w the whole point of an LVM snapshot is that it is near instant (takes a few ms at most, and I believe all I/O is halted during the snapshot) so it is impossible for a user to move a file during a backup being run on an LVM snapshot  |
Yeah, you're right. I was thinking of just copying the files, not a snapshot. The second part of my answer (not intentionally my emphasis) doesn't make sense in this context
In theory it can be done live, but not very conveniently. The reason is that your database servers (MySQL, openldap) will have data in memory to be written to disk that's not written to disk yet. If you don't capture that data to disk, it won't be backed up in the filesystem snapshot.
MySQL is fairly resilient this way (think: pull power plug on server), though I don't do this for fun. There's plenty of documentation out there on backing up MySQL via a snapshot while live (
Using LVM for MySQL Backup and Replication Setup | MySQL Performance Blog), but the answer is not just "take the snapshot".
With openldap, I don't even try restoring via the live data files if it doesn't start. Perhaps others will know why, I just haven't looked into it. A slapcat/slapadd is almost always necessary.
You could do a snapshot of a virtual machine and have it be fully recoverable, granted that you also make a snapshot of the memory.
The only real way to figure this out though, would be to try it for yourself. I'd run a restore (well, several) of a snapshot and see what is restorable and what is not. You're the one that has to be there crossing fingers hoping that the thing restores successfully at 3 AM (or 10 AM on Wednesday if you're really unlucky ((knocks on wood)) ).