LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   undo lvm snapshot recovery (https://www.linuxquestions.org/questions/linux-server-73/undo-lvm-snapshot-recovery-4175440804/)

Randall Slack 12-10-2012 07:26 AM

undo lvm snapshot recovery
 
Hi all,

have a bit of a situation after a failed backup procedure using LVM-snapshot.

normally i have a script running to make backups each night of my Logical Volume, i create a snapshot of the volume and then use rsnapshot to make a backup and then remove the snapshot again, been going well for years.

untill the backup of wednesday got jammed and the script never fully completed leaving the snapshot in place (i know its my bad, should use more sanity checks in my script)

i didn't really notice anything gone bad till saturday when all te requests to my server were timing out and after logging in i noticed it was under 100% load and did a reboot, all fine till i noticed that i was missing several days, in fact the whole machine rolled back to the state since the last complete backup.
the logs were showing io errors to the snapshot, probably being full.

not sure if all is lost or if there is a way to recover this lost data.
Code:

vgcfgrestore --list drbdvg0
does show the snapshot and seems to be able to at least restore the metadata of the snapshot itself using
Code:

vgcfgrestore -f /etc/lvm/archive/drbdvg0_00158.vg drbdvg0
both the original volume and the snapshot seem to return in INACTIVE state, and trying mounting the snapshot i get the following error.
Code:

mount: special device /dev/drbdvg0/backup does not exist

need to wait now for doing a full backup of its current state before attempting to merge back the snapshot, IF at all possible, since i have no idea yet on what procedure to follow.

anybody here an idea on how to release me from this agony?

much obliged


All times are GMT -5. The time now is 12:04 PM.