Is there any method to check the integrity of the backup archive ?
More explanation:
I want to put some integrity check into my Virtualmins servers backup, but I didn’t find a lot of things with Virtualmin.
I have some Virtualmins servers backup-ing data in a distant backup server through FTP. What I want is to make a checksum test on my archive before the data was send to compare the cksum of the archive on my backup server, In order to check if the data was sent successfully ! And next a simple test to see if the archive is not corrupt.
I already know how to check if an archive is good on my backup server.
Simple shell script making.
gunzip -c /your/path/archive.tgz | tar -t > /dev/null
Then test “$?”
I already know how to make the cksum of my archive in my backup server.
My problem is:
I can’t perform cksum on the backup archive before it was sent.
I tried to run some command with the “Command to run after backup” in backup jobs but it’s seems the archive was deleted before my shell script run.
How to do a cksum of the temp archive created when the backup job is finished ?
Yeah, the command to be run after a backup is run after the entire backup process has been completed… there isn’t a way to run a command after performing the backup for each individual Virtual Server.
The best suggestion I could offer is to setup a cron job on the backup server itself, and have it run the checksums long after the backup has completed.
But i still have a question:
A cron job to perform checksum after the backup job finished is good for me ! But where the archive was stored ? I look for them but didn’t find them. Its seem’s they (the archives) were deleted right after the backup finish.
Those aren’t really designed to be used, at that point… and you’re right, they are deleted as soon as the backup is completed. They also have random names, so it’d be difficult to perform any checks against them.
If you need to do some work on them before they’re transferred, you could always use a local destination for the backups, and then write a script that first performs a checksum of them, followed by performing an FTP transfer of them to your backup server.
Good morning Eric, I end my day, you start your’s !
That’s exactly what I think, it will be very hard to perform checksum on temporary backup archive…
But it seems strange nobody think about checking if an FTP transfer goes wright ? Am I the first idiot who tries checking all his backup ? =)
I think you have an idea of new options in virtualmin backup job, perform checksum to check data transfer !
For now i guess i have to content myself with simple archive check on my backup server.