[sf-lug] multisum - multiple sums/hashes in a single pass (e.g. check ISOs)
Will
guacamolepandemonium at gmail.com
Mon Mar 18 16:27:42 PDT 2013
Interesting. Just recently I was doing something similar but used a bash
one-liner stuff to do it.
dd if=/dev/cdrom bs=<sector count> count=2048 | tee >(md5sum 1>&2)
>(sha1sum 1>&2) >(sha256sum 1>&2) > /dev/null
Replace with your cdrom device. Here on Xubuntu there are multiple symlinks
pointing to the real device.
"count" and "bs" values can be swapped, but I've generally found the larger
the "bs" value, the faster it all goes, so I try to put the larger of the
two there.
The "<sector count>" is the number of 2048 sectors in the iso and can be
found by dividing the iso filesize in bytes by 2048.
Though having actual dedicated tools that make things easier are good.
Especially when they get packaged.
On Mon, Mar 18, 2013 at 2:46 PM, Michael Paoli <
Michael.Paoli at cal.berkeley.edu> wrote:
> Something I did a while ago (and tweaked earlier this year). Anyway,
> "useful enough" I though I'd put it out there publicly - and just did so
> today. It works similar to md5sum, sha1sum and the like. But where
> multiple such (check)sums/hashes are desired, its generally
> significantly more efficient, as it only reads input file(s) once, and
> calculates all the various sums in a single (read) pass. It can
> calculate a fair number of various sums. By default it calculates those
> provided for most Debian ISOs. :-)
>
> This can be particularly useful and efficient where multiple such sums
> are provided for an ISO image, and one wants to check more than one of
> them. More details and code, etc., go here:
> http://www.rawbw.com/~mp/perl/**#multisum<http://www.rawbw.com/~mp/perl/#multisum>
>
>
> ______________________________**_________________
> sf-lug mailing list
> sf-lug at linuxmafia.com
> http://linuxmafia.com/mailman/**listinfo/sf-lug<http://linuxmafia.com/mailman/listinfo/sf-lug>
> Information about SF-LUG is at http://www.sf-lug.org/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://linuxmafia.com/pipermail/sf-lug/attachments/20130318/6e1dd8f7/attachment.html>
More information about the sf-lug
mailing list