Checksums do not match, image might be corrupted error with jigdoChecksums do not match, image might be corrupted error with jigdo

Posted March 6th, 2008 in Linux/Unix/BSD

After creating the 2nd DVD ISO image for Debian 4.0r3 amd64, I got the error message "ERROR: Checksums do not match, image might be corrupted!" I didn't see the point in running jigdo-lite again as it would presumably cause the same issue, so instead used rsync to synchronise the full ISO file against one on an rsync mirror. This post looks at the error messages and the rsync command and output used.

I posted about how to use jigdo-lite last week, so you can refer to that article about what jigdo is and how to use jigdo-lite.

"Checksums do not match" error message

After running jigdo-lite to create the new debian-40r3-amd64-DVD-2.iso ISO image, I got the following output at the end:

Successfully created `debian-40r3-amd64-DVD-2.iso'

-----------------------------------------------------------------
Finished!
The fact that you got this far is a strong indication that `debian-40r3-amd64-DVD-2.iso'
was generated correctly. I will perform an additional, final check,
which you can interrupt safely with Ctrl-C if you do not want to wait.

ERROR: Checksums do not match, image might be corrupted!

Using rsync to fix the ISO image

I decided not to bother running jigdo again, as it would probably not fix the issue given it had made a corrupt image in the first place by missing a file or two, and used rsync instead. rsync allows a comparison to be made against the local file and remote file, and only downloads the chunks that are required. This saves bandwidth and time if the file is only wrong in a few small places.

The command I used to rsync the debian-40r3-amd64-DVD-2.iso ISO image was:

rsync -az --progress --stats \
rsync://cdimage.debian.org/debian-cd/4.0_r3/amd64/iso-dvd/debian-40r3-amd64-DVD-2.iso .

The --progress flag shows the amount downloaded and a rough estimate of when it will be completed, and the --stats one shows some stats at the end.

When rsync starts it will show this:

receiving file list ...
1 file to consider

and then it will look like it's not doing anything for a while. At this stage it's checking the local version against the remote version. After a while, it will start to output the progress, and the output as it is downloading looks something like this:

debian-40r3-amd64-DVD-2.iso
  1297524312  27%    7.53MB/s    0:07:19

The overflated download speed is because it measures how much has been "downloaded" so far, including what was already available that it didn't need to download, with the time taken from when it started downloading.

When it's finished, it will show something like this:

debian-40r3-amd64-DVD-2.iso
  4682795008 100%    8.31MB/s    0:08:57  (1, 100.0% of 1)

Number of files: 1
Number of files transferred: 1
Total file size: 4682795008 bytes
Total transferred file size: 4682795008 bytes
Literal data: 68424 bytes
Matched data: 4682726584 bytes
File list size: 70
Total bytes sent: 547649
Total bytes received: 68682

sent 547649 bytes  received 68682 bytes  595.78 bytes/sec
total size is 4682795008  speedup is 7597.86

The text from "number of files" on is what is displayed from using the --stats flag. From this statistical information, we can see we only needed to actually download 68682 bytes to complete the image (and had to upload 547649 to do it!)

Checksum just to make sure

FInally I did a checksum just to make sure it's correct, although given I used rsync to sync the image then it should be OK. But best to make sure...

$ echo "3e198ceb260f85ca62ec5264fa81ffe7  debian-40r3-amd64-DVD-2.iso" > debian-40r3-amd64-DVD-2.iso.md5
$ md5sum -c debian-40r3-amd64-DVD-2.iso.md5
debian-40r3-amd64-DVD-2.iso: OK

Right, that looks good. It's now safe to burn the ISO image to DVD.

Related posts:

Comments

blog comments powered by Disqus