I want make a backup of my Home directory and I've read a good method is to use the tar tool, and I think it suits me well since all I need to do is create a .tar of every folder in the Home directory (Desktop.tar, Documents.tar, etc) and then transfer if to the External Hard Drive (EHD).
One of my concerns, though, is making sure the files that gets copied to the EHD are not corrupted in the process. So I'm was thinking to follow this procedure to verify the integrity of my data (I will use the Desktop directory as example, but it is exactly the same for every other folder):
- Use
tarand createDesktop.tarinside my computer. - Calculate
md5andsha-2hashes forDesktop.tar. - Move
Desktop.tarto the EHD, which, let's say, is calledbackup. - Calculate
md5andsha-2hashes forbackup/Desktop.tarand verify they are the same as the ones calculated in the second step.
So my questions are:
- Is this a good procedure to verify the data on my backup has not been corrupted in the transfer?
- I know the tool used to calculate the
md5hash ismd5sum, but I'm not really sure what tool to use to calculate thesha-2hash function. So should I usesha224sum,sha256sum,sha384sumorsha512sum?