On Thu, Nov 28, 2002 at 01:51:02PM +0100, Jochen Voss wrote: > Is this a good way to check wheter the CDs are official Debian CDs?
Yes! Except md5sum should be called differently, see below. > The result was that the checksums did match for CD #1, but did NOT > match for the remaining CDs. When she asked the dealer he told her, > that this does not indicate a problem, but could be caused by > "additional bits at the beginning or end of the CD". Does this make > sense? It does, unfortunately ("at the end", at least). According to the mkisofs docs, many OSs break if the length of a CD is not a multiple of the OS page size, or something like that. To avoid this problem, mkisofs adds a few sectors of zeroes to the end of the CD image. These zeroes are included in the md5sum. However, when writing the image to CD, I think some programs add yet more padding to the end of the written data, "just to be safe". cdrecord needs an explicit "-pad" to do this, but other programs may add the padding by default. But it is possible to pass the correct data to md5sum: First, mount the CD. Just working on the unmounted device doesn't always seem to work. Then, try one of two things: cat /dev/cdrom | md5sum Apparently, this is preferable to "md5sum /dev/cdrom" because cat does a better job of really reading all the available data - YMMV. I'm not sure whether the above will work if more padding was added e.g. by cdrecord, so better try the alternative: dd if=/dev/cdrom bs=1k count=##### | md5sum where the ##### is the "1k-blocks" value from the output of "df /cdrom". HTH, Richard -- __ _ |_) /| Richard Atterer | CS student at the Technische | GnuPG key: | \/¯| http://atterer.net | Universität München, Germany | 0x888354F7 ¯ '` ¯
pgpmDFIrMNiUC.pgp
Description: PGP signature