How to verify a CD against an ISO image?Is it possible to insert a physical CD into a VirtualBox machine?Is...

Do creatures all have the same statistics upon being reanimated via the Animate Dead spell?

How can I offer a test ride while selling a bike?

Understanding STM32 datasheet regarding decoupling capacitors

Strange math syntax in old basic listing

Is there an evolutionary advantage to having two heads?

Why were the Night's Watch required to be celibate?

What are the benefits of cryosleep?

Modern approach to radio buttons

Differences between “pas vrai ?”, “c’est ça ?”, “hein ?”, and “n’est-ce pas ?”

Is the world in Game of Thrones spherical or flat?

Why to use water tanks from Space shuttle in museum?

What does "Marchentalender" on the front of a postcard mean?

What are the problems in teaching guitar via Skype?

What does it mean when you think without speaking?

Asking bank to reduce APR instead of increasing credit limit

Can a rogue effectively triple their speed by combining Dash and Ready?

How to properly maintain eye contact with people that have distinctive facial features?

Creating Fictional Slavic Place Names

My player wants to cast multiple charges of magic missile from a wand

Could IPv6 make NAT / port numbers redundant?

Why do Russians call their women expensive ("дорогая")?

How was Apollo supposed to rendezvous in the case of a lunar abort?

Beginner's snake game using PyGame

Term for checking piece whose opponent daren't capture it



How to verify a CD against an ISO image?


Is it possible to insert a physical CD into a VirtualBox machine?Is there a CD/DVD disk reading test tool for Linux?Create a Random ISO Image Using ddHow to checksum a CD/DVD? (to verify integrity of my Debian installation)Is there a CD/DVD disk reading test tool for Linux?How to create UDF images and burn them to DVD or CDROM?Create multisession ISO image to burn on a remote CDstrange problems on cd-rom writersUsing Fedora 19 to burn .iso-image to external HDDHow to copy CDROM to ISO in Debian 8.x?How do I resume a 'wodim' DVD burn aborted with Ctrl+C?Is it possible to insert a physical CD into a VirtualBox machine?Batch convert ISO/WAV/CUE back into BIN/CUEErase RW disc and burn linux .iso






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ margin-bottom:0;
}







8















I've got a physical burnt CD and the original ISO image of it. No reference checksum files were provided for the CD contents. How do I check the actual CD is correct (corresponds to the original image) and fully readable?










share|improve this question

























  • Do you mean to check the data on the CD right after it was burned ? Because most burning software tools have an option to check written data (ex Nero).

    – Silviu
    May 27 '12 at 18:57











  • I know but I need to to do the check not right after the burning procedure but after some time (after the burning program was already closed), maybe even on a different PC. As far as I know Nero doesn't offer to initiate a verification procedure independently of a burning procedure - it's verification facility is only an add-on for burning and can happen only right after the burning. What I want is to insert a CD, choose an ISO file and click to verify... Another constraint is that I wan't to do this under Linux as I suspect my Windows CD/IDE driver is not ok.

    – Ivan
    May 27 '12 at 19:12











  • That's really difficult , are you burning a bootable CD or pure data ?

    – daisy
    May 28 '12 at 13:42











  • A bootable CD..

    – Ivan
    May 28 '12 at 20:01











  • FYI, some Linux ISOs have a built-in boot option to verify their contents. You can use that option and it'll check all the disc's files against a file containing checksums. You could also run md5sum yourself and compare, if you don't want to boot the CD/DVD.

    – Skylar Ittner
    Apr 28 at 20:14


















8















I've got a physical burnt CD and the original ISO image of it. No reference checksum files were provided for the CD contents. How do I check the actual CD is correct (corresponds to the original image) and fully readable?










share|improve this question

























  • Do you mean to check the data on the CD right after it was burned ? Because most burning software tools have an option to check written data (ex Nero).

    – Silviu
    May 27 '12 at 18:57











  • I know but I need to to do the check not right after the burning procedure but after some time (after the burning program was already closed), maybe even on a different PC. As far as I know Nero doesn't offer to initiate a verification procedure independently of a burning procedure - it's verification facility is only an add-on for burning and can happen only right after the burning. What I want is to insert a CD, choose an ISO file and click to verify... Another constraint is that I wan't to do this under Linux as I suspect my Windows CD/IDE driver is not ok.

    – Ivan
    May 27 '12 at 19:12











  • That's really difficult , are you burning a bootable CD or pure data ?

    – daisy
    May 28 '12 at 13:42











  • A bootable CD..

    – Ivan
    May 28 '12 at 20:01











  • FYI, some Linux ISOs have a built-in boot option to verify their contents. You can use that option and it'll check all the disc's files against a file containing checksums. You could also run md5sum yourself and compare, if you don't want to boot the CD/DVD.

    – Skylar Ittner
    Apr 28 at 20:14














8












8








8


3






I've got a physical burnt CD and the original ISO image of it. No reference checksum files were provided for the CD contents. How do I check the actual CD is correct (corresponds to the original image) and fully readable?










share|improve this question
















I've got a physical burnt CD and the original ISO image of it. No reference checksum files were provided for the CD contents. How do I check the actual CD is correct (corresponds to the original image) and fully readable?







data-cd burning






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Jul 23 '14 at 19:42









Braiam

24k2079145




24k2079145










asked May 27 '12 at 18:42









IvanIvan

6,0042071101




6,0042071101













  • Do you mean to check the data on the CD right after it was burned ? Because most burning software tools have an option to check written data (ex Nero).

    – Silviu
    May 27 '12 at 18:57











  • I know but I need to to do the check not right after the burning procedure but after some time (after the burning program was already closed), maybe even on a different PC. As far as I know Nero doesn't offer to initiate a verification procedure independently of a burning procedure - it's verification facility is only an add-on for burning and can happen only right after the burning. What I want is to insert a CD, choose an ISO file and click to verify... Another constraint is that I wan't to do this under Linux as I suspect my Windows CD/IDE driver is not ok.

    – Ivan
    May 27 '12 at 19:12











  • That's really difficult , are you burning a bootable CD or pure data ?

    – daisy
    May 28 '12 at 13:42











  • A bootable CD..

    – Ivan
    May 28 '12 at 20:01











  • FYI, some Linux ISOs have a built-in boot option to verify their contents. You can use that option and it'll check all the disc's files against a file containing checksums. You could also run md5sum yourself and compare, if you don't want to boot the CD/DVD.

    – Skylar Ittner
    Apr 28 at 20:14



















  • Do you mean to check the data on the CD right after it was burned ? Because most burning software tools have an option to check written data (ex Nero).

    – Silviu
    May 27 '12 at 18:57











  • I know but I need to to do the check not right after the burning procedure but after some time (after the burning program was already closed), maybe even on a different PC. As far as I know Nero doesn't offer to initiate a verification procedure independently of a burning procedure - it's verification facility is only an add-on for burning and can happen only right after the burning. What I want is to insert a CD, choose an ISO file and click to verify... Another constraint is that I wan't to do this under Linux as I suspect my Windows CD/IDE driver is not ok.

    – Ivan
    May 27 '12 at 19:12











  • That's really difficult , are you burning a bootable CD or pure data ?

    – daisy
    May 28 '12 at 13:42











  • A bootable CD..

    – Ivan
    May 28 '12 at 20:01











  • FYI, some Linux ISOs have a built-in boot option to verify their contents. You can use that option and it'll check all the disc's files against a file containing checksums. You could also run md5sum yourself and compare, if you don't want to boot the CD/DVD.

    – Skylar Ittner
    Apr 28 at 20:14

















Do you mean to check the data on the CD right after it was burned ? Because most burning software tools have an option to check written data (ex Nero).

– Silviu
May 27 '12 at 18:57





Do you mean to check the data on the CD right after it was burned ? Because most burning software tools have an option to check written data (ex Nero).

– Silviu
May 27 '12 at 18:57













I know but I need to to do the check not right after the burning procedure but after some time (after the burning program was already closed), maybe even on a different PC. As far as I know Nero doesn't offer to initiate a verification procedure independently of a burning procedure - it's verification facility is only an add-on for burning and can happen only right after the burning. What I want is to insert a CD, choose an ISO file and click to verify... Another constraint is that I wan't to do this under Linux as I suspect my Windows CD/IDE driver is not ok.

– Ivan
May 27 '12 at 19:12





I know but I need to to do the check not right after the burning procedure but after some time (after the burning program was already closed), maybe even on a different PC. As far as I know Nero doesn't offer to initiate a verification procedure independently of a burning procedure - it's verification facility is only an add-on for burning and can happen only right after the burning. What I want is to insert a CD, choose an ISO file and click to verify... Another constraint is that I wan't to do this under Linux as I suspect my Windows CD/IDE driver is not ok.

– Ivan
May 27 '12 at 19:12













That's really difficult , are you burning a bootable CD or pure data ?

– daisy
May 28 '12 at 13:42





That's really difficult , are you burning a bootable CD or pure data ?

– daisy
May 28 '12 at 13:42













A bootable CD..

– Ivan
May 28 '12 at 20:01





A bootable CD..

– Ivan
May 28 '12 at 20:01













FYI, some Linux ISOs have a built-in boot option to verify their contents. You can use that option and it'll check all the disc's files against a file containing checksums. You could also run md5sum yourself and compare, if you don't want to boot the CD/DVD.

– Skylar Ittner
Apr 28 at 20:14





FYI, some Linux ISOs have a built-in boot option to verify their contents. You can use that option and it'll check all the disc's files against a file containing checksums. You could also run md5sum yourself and compare, if you don't want to boot the CD/DVD.

– Skylar Ittner
Apr 28 at 20:14










5 Answers
5






active

oldest

votes


















4














If the ISO file is the same one used to burn the CD, then here are my two favourites:



diff /dev/sr0 /tmp/file.iso


Compares the recorded image against the image file. If you feel a bit more masochistic, you could try something like this:



sha1sum /dev/sr0 /tmp/file.iso


and compare the signatures. This one's more useful if you already have the SHA1 sum somewhere. Both commands will read the medium to the end.



If you want to do it the way @Marki555 suggests, you'll want to mount both optical drive and image first. Here's a complete script: (you can, of course, dispense with the sudo if you're root — a bad idea, in general)



sudo mkdir /tmp/{a,b}
sudo mount /dev/sr0 /tmp/a -o ro # or whatever
sudo mount /tmp/file.iso /tmp/b -o loop,ro
diff -dur /tmp/{a,b}
sudo umount /tmp/a
sudo umount /tmp/b
sudo rmdir /tmp/{a,b}





share|improve this answer



















  • 2





    cmp [-l] is better suited for binary files. Diff works best on text.

    – derobert
    Sep 11 '12 at 15:21



















4














First, you rip your CD to a temporary file:



dd if=/dev/sr0 of=copy.iso


Then you check if copy.iso and orig.iso have the same size, for example with:



stat -c '%s %n' orig.iso copy.iso


If the size is identical, it's easy:



sha1sum orig.iso copy.iso


But I noticed that in certain cases the size can be slightly different because there are trailing zeroes in either the copy or the original image. For example, if copy.iso is smaller than orig.iso:



sha1sum copy.iso
head -c $(stat -c %s copy.iso) orig.iso | sha1sum


Of course you should also check that the trailing bytes are just zeroes:



od -j $(stat -c %s copy.iso) orig.iso


The first line, except for the offset, should be zeroes only. The second line should be an asterisk. The asterisk is to avoid showing consecutive identical lines.






share|improve this answer


























  • +1 for checksums. This is usually the de facto standard for comparing files(or directories) and not caring about knowing the differences(as is the case with diff): more minimal.

    – nikitautiu
    Sep 11 '12 at 13:22











  • or you can do head -c $(stat -c %s /path/to/master.iso) /dev/sr0 | sha1sum to avoid needing to make an image of the burnt CD.

    – Hitechcomputergeek
    Dec 21 '16 at 21:57



















2














You can check that CD is fully readable by using dd (for example dd if=/dev/cdrom of=/dev/null). But you can't compare it directly with an ISO image. Each software will create slightly different ISO file (maybe some different headers, or padding), although these different ISO images will all provide the same CD contents (directory structure, file attributes and file contents).



So you can only mount the CD, mount the ISO image and compare it at filesystem level by using some kind of directory comparison tool (sorry, I didn't use any yet on linux).






share|improve this answer
























  • diff -r will compare the directory contents recursively.

    – Kevin
    May 27 '12 at 20:37






  • 3





    Since the cd was burned from an already prepared iso image, there's nothing to be built differently when burning, so you can directly compare the cd with the iso image.

    – psusi
    May 28 '12 at 2:35



















1














If you still have the ISO, you can compare them byte by byte using cmp. It's a simple enough command and it exits on the first difference it finds, so it's considerably faster than making a checksum if there actually is an error early on.



cmp /dev/cdrom /path/cdrom.iso


Possible outcomes on success:




  • no output: it's identical and all OK. You may append && echo OK to the command if the lack of output confuses you.


  • cmp: EOF on cdrom.iso: it's identical but the cdrom has more bytes than your iso file. This is usually due to zero padding at the end of the cdrom. Since that does not matter in practice, it's still a success.


Possible outcomes on failure:





  • cmp: EOF on /dev/cdrom: for some reason the data on your CDROM is incomplete. Maybe your ISO was too large to fit a real CD.


  • /dev/cdrom cdrom.iso differ: byte 18296321, line 71780: there is some unexpected difference between your CDROM and your ISO image.






share|improve this answer































    -1














    Brasero can do that:
    Tools -> Check integrity...






    share|improve this answer
























      Your Answer








      StackExchange.ready(function() {
      var channelOptions = {
      tags: "".split(" "),
      id: "106"
      };
      initTagRenderer("".split(" "), "".split(" "), channelOptions);

      StackExchange.using("externalEditor", function() {
      // Have to fire editor after snippets, if snippets enabled
      if (StackExchange.settings.snippets.snippetsEnabled) {
      StackExchange.using("snippets", function() {
      createEditor();
      });
      }
      else {
      createEditor();
      }
      });

      function createEditor() {
      StackExchange.prepareEditor({
      heartbeatType: 'answer',
      autoActivateHeartbeat: false,
      convertImagesToLinks: false,
      noModals: true,
      showLowRepImageUploadWarning: true,
      reputationToPostImages: null,
      bindNavPrevention: true,
      postfix: "",
      imageUploader: {
      brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
      contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
      allowUrls: true
      },
      onDemand: true,
      discardSelector: ".discard-answer"
      ,immediatelyShowMarkdownHelp:true
      });


      }
      });














      draft saved

      draft discarded


















      StackExchange.ready(
      function () {
      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f39467%2fhow-to-verify-a-cd-against-an-iso-image%23new-answer', 'question_page');
      }
      );

      Post as a guest















      Required, but never shown

























      5 Answers
      5






      active

      oldest

      votes








      5 Answers
      5






      active

      oldest

      votes









      active

      oldest

      votes






      active

      oldest

      votes









      4














      If the ISO file is the same one used to burn the CD, then here are my two favourites:



      diff /dev/sr0 /tmp/file.iso


      Compares the recorded image against the image file. If you feel a bit more masochistic, you could try something like this:



      sha1sum /dev/sr0 /tmp/file.iso


      and compare the signatures. This one's more useful if you already have the SHA1 sum somewhere. Both commands will read the medium to the end.



      If you want to do it the way @Marki555 suggests, you'll want to mount both optical drive and image first. Here's a complete script: (you can, of course, dispense with the sudo if you're root — a bad idea, in general)



      sudo mkdir /tmp/{a,b}
      sudo mount /dev/sr0 /tmp/a -o ro # or whatever
      sudo mount /tmp/file.iso /tmp/b -o loop,ro
      diff -dur /tmp/{a,b}
      sudo umount /tmp/a
      sudo umount /tmp/b
      sudo rmdir /tmp/{a,b}





      share|improve this answer



















      • 2





        cmp [-l] is better suited for binary files. Diff works best on text.

        – derobert
        Sep 11 '12 at 15:21
















      4














      If the ISO file is the same one used to burn the CD, then here are my two favourites:



      diff /dev/sr0 /tmp/file.iso


      Compares the recorded image against the image file. If you feel a bit more masochistic, you could try something like this:



      sha1sum /dev/sr0 /tmp/file.iso


      and compare the signatures. This one's more useful if you already have the SHA1 sum somewhere. Both commands will read the medium to the end.



      If you want to do it the way @Marki555 suggests, you'll want to mount both optical drive and image first. Here's a complete script: (you can, of course, dispense with the sudo if you're root — a bad idea, in general)



      sudo mkdir /tmp/{a,b}
      sudo mount /dev/sr0 /tmp/a -o ro # or whatever
      sudo mount /tmp/file.iso /tmp/b -o loop,ro
      diff -dur /tmp/{a,b}
      sudo umount /tmp/a
      sudo umount /tmp/b
      sudo rmdir /tmp/{a,b}





      share|improve this answer



















      • 2





        cmp [-l] is better suited for binary files. Diff works best on text.

        – derobert
        Sep 11 '12 at 15:21














      4












      4








      4







      If the ISO file is the same one used to burn the CD, then here are my two favourites:



      diff /dev/sr0 /tmp/file.iso


      Compares the recorded image against the image file. If you feel a bit more masochistic, you could try something like this:



      sha1sum /dev/sr0 /tmp/file.iso


      and compare the signatures. This one's more useful if you already have the SHA1 sum somewhere. Both commands will read the medium to the end.



      If you want to do it the way @Marki555 suggests, you'll want to mount both optical drive and image first. Here's a complete script: (you can, of course, dispense with the sudo if you're root — a bad idea, in general)



      sudo mkdir /tmp/{a,b}
      sudo mount /dev/sr0 /tmp/a -o ro # or whatever
      sudo mount /tmp/file.iso /tmp/b -o loop,ro
      diff -dur /tmp/{a,b}
      sudo umount /tmp/a
      sudo umount /tmp/b
      sudo rmdir /tmp/{a,b}





      share|improve this answer













      If the ISO file is the same one used to burn the CD, then here are my two favourites:



      diff /dev/sr0 /tmp/file.iso


      Compares the recorded image against the image file. If you feel a bit more masochistic, you could try something like this:



      sha1sum /dev/sr0 /tmp/file.iso


      and compare the signatures. This one's more useful if you already have the SHA1 sum somewhere. Both commands will read the medium to the end.



      If you want to do it the way @Marki555 suggests, you'll want to mount both optical drive and image first. Here's a complete script: (you can, of course, dispense with the sudo if you're root — a bad idea, in general)



      sudo mkdir /tmp/{a,b}
      sudo mount /dev/sr0 /tmp/a -o ro # or whatever
      sudo mount /tmp/file.iso /tmp/b -o loop,ro
      diff -dur /tmp/{a,b}
      sudo umount /tmp/a
      sudo umount /tmp/b
      sudo rmdir /tmp/{a,b}






      share|improve this answer












      share|improve this answer



      share|improve this answer










      answered May 27 '12 at 23:28









      AlexiosAlexios

      14.9k15068




      14.9k15068








      • 2





        cmp [-l] is better suited for binary files. Diff works best on text.

        – derobert
        Sep 11 '12 at 15:21














      • 2





        cmp [-l] is better suited for binary files. Diff works best on text.

        – derobert
        Sep 11 '12 at 15:21








      2




      2





      cmp [-l] is better suited for binary files. Diff works best on text.

      – derobert
      Sep 11 '12 at 15:21





      cmp [-l] is better suited for binary files. Diff works best on text.

      – derobert
      Sep 11 '12 at 15:21













      4














      First, you rip your CD to a temporary file:



      dd if=/dev/sr0 of=copy.iso


      Then you check if copy.iso and orig.iso have the same size, for example with:



      stat -c '%s %n' orig.iso copy.iso


      If the size is identical, it's easy:



      sha1sum orig.iso copy.iso


      But I noticed that in certain cases the size can be slightly different because there are trailing zeroes in either the copy or the original image. For example, if copy.iso is smaller than orig.iso:



      sha1sum copy.iso
      head -c $(stat -c %s copy.iso) orig.iso | sha1sum


      Of course you should also check that the trailing bytes are just zeroes:



      od -j $(stat -c %s copy.iso) orig.iso


      The first line, except for the offset, should be zeroes only. The second line should be an asterisk. The asterisk is to avoid showing consecutive identical lines.






      share|improve this answer


























      • +1 for checksums. This is usually the de facto standard for comparing files(or directories) and not caring about knowing the differences(as is the case with diff): more minimal.

        – nikitautiu
        Sep 11 '12 at 13:22











      • or you can do head -c $(stat -c %s /path/to/master.iso) /dev/sr0 | sha1sum to avoid needing to make an image of the burnt CD.

        – Hitechcomputergeek
        Dec 21 '16 at 21:57
















      4














      First, you rip your CD to a temporary file:



      dd if=/dev/sr0 of=copy.iso


      Then you check if copy.iso and orig.iso have the same size, for example with:



      stat -c '%s %n' orig.iso copy.iso


      If the size is identical, it's easy:



      sha1sum orig.iso copy.iso


      But I noticed that in certain cases the size can be slightly different because there are trailing zeroes in either the copy or the original image. For example, if copy.iso is smaller than orig.iso:



      sha1sum copy.iso
      head -c $(stat -c %s copy.iso) orig.iso | sha1sum


      Of course you should also check that the trailing bytes are just zeroes:



      od -j $(stat -c %s copy.iso) orig.iso


      The first line, except for the offset, should be zeroes only. The second line should be an asterisk. The asterisk is to avoid showing consecutive identical lines.






      share|improve this answer


























      • +1 for checksums. This is usually the de facto standard for comparing files(or directories) and not caring about knowing the differences(as is the case with diff): more minimal.

        – nikitautiu
        Sep 11 '12 at 13:22











      • or you can do head -c $(stat -c %s /path/to/master.iso) /dev/sr0 | sha1sum to avoid needing to make an image of the burnt CD.

        – Hitechcomputergeek
        Dec 21 '16 at 21:57














      4












      4








      4







      First, you rip your CD to a temporary file:



      dd if=/dev/sr0 of=copy.iso


      Then you check if copy.iso and orig.iso have the same size, for example with:



      stat -c '%s %n' orig.iso copy.iso


      If the size is identical, it's easy:



      sha1sum orig.iso copy.iso


      But I noticed that in certain cases the size can be slightly different because there are trailing zeroes in either the copy or the original image. For example, if copy.iso is smaller than orig.iso:



      sha1sum copy.iso
      head -c $(stat -c %s copy.iso) orig.iso | sha1sum


      Of course you should also check that the trailing bytes are just zeroes:



      od -j $(stat -c %s copy.iso) orig.iso


      The first line, except for the offset, should be zeroes only. The second line should be an asterisk. The asterisk is to avoid showing consecutive identical lines.






      share|improve this answer















      First, you rip your CD to a temporary file:



      dd if=/dev/sr0 of=copy.iso


      Then you check if copy.iso and orig.iso have the same size, for example with:



      stat -c '%s %n' orig.iso copy.iso


      If the size is identical, it's easy:



      sha1sum orig.iso copy.iso


      But I noticed that in certain cases the size can be slightly different because there are trailing zeroes in either the copy or the original image. For example, if copy.iso is smaller than orig.iso:



      sha1sum copy.iso
      head -c $(stat -c %s copy.iso) orig.iso | sha1sum


      Of course you should also check that the trailing bytes are just zeroes:



      od -j $(stat -c %s copy.iso) orig.iso


      The first line, except for the offset, should be zeroes only. The second line should be an asterisk. The asterisk is to avoid showing consecutive identical lines.







      share|improve this answer














      share|improve this answer



      share|improve this answer








      edited Mar 7 '15 at 18:34









      KeyboardWielder

      1033




      1033










      answered Sep 11 '12 at 12:51









      Francesco TurcoFrancesco Turco

      1,37331530




      1,37331530













      • +1 for checksums. This is usually the de facto standard for comparing files(or directories) and not caring about knowing the differences(as is the case with diff): more minimal.

        – nikitautiu
        Sep 11 '12 at 13:22











      • or you can do head -c $(stat -c %s /path/to/master.iso) /dev/sr0 | sha1sum to avoid needing to make an image of the burnt CD.

        – Hitechcomputergeek
        Dec 21 '16 at 21:57



















      • +1 for checksums. This is usually the de facto standard for comparing files(or directories) and not caring about knowing the differences(as is the case with diff): more minimal.

        – nikitautiu
        Sep 11 '12 at 13:22











      • or you can do head -c $(stat -c %s /path/to/master.iso) /dev/sr0 | sha1sum to avoid needing to make an image of the burnt CD.

        – Hitechcomputergeek
        Dec 21 '16 at 21:57

















      +1 for checksums. This is usually the de facto standard for comparing files(or directories) and not caring about knowing the differences(as is the case with diff): more minimal.

      – nikitautiu
      Sep 11 '12 at 13:22





      +1 for checksums. This is usually the de facto standard for comparing files(or directories) and not caring about knowing the differences(as is the case with diff): more minimal.

      – nikitautiu
      Sep 11 '12 at 13:22













      or you can do head -c $(stat -c %s /path/to/master.iso) /dev/sr0 | sha1sum to avoid needing to make an image of the burnt CD.

      – Hitechcomputergeek
      Dec 21 '16 at 21:57





      or you can do head -c $(stat -c %s /path/to/master.iso) /dev/sr0 | sha1sum to avoid needing to make an image of the burnt CD.

      – Hitechcomputergeek
      Dec 21 '16 at 21:57











      2














      You can check that CD is fully readable by using dd (for example dd if=/dev/cdrom of=/dev/null). But you can't compare it directly with an ISO image. Each software will create slightly different ISO file (maybe some different headers, or padding), although these different ISO images will all provide the same CD contents (directory structure, file attributes and file contents).



      So you can only mount the CD, mount the ISO image and compare it at filesystem level by using some kind of directory comparison tool (sorry, I didn't use any yet on linux).






      share|improve this answer
























      • diff -r will compare the directory contents recursively.

        – Kevin
        May 27 '12 at 20:37






      • 3





        Since the cd was burned from an already prepared iso image, there's nothing to be built differently when burning, so you can directly compare the cd with the iso image.

        – psusi
        May 28 '12 at 2:35
















      2














      You can check that CD is fully readable by using dd (for example dd if=/dev/cdrom of=/dev/null). But you can't compare it directly with an ISO image. Each software will create slightly different ISO file (maybe some different headers, or padding), although these different ISO images will all provide the same CD contents (directory structure, file attributes and file contents).



      So you can only mount the CD, mount the ISO image and compare it at filesystem level by using some kind of directory comparison tool (sorry, I didn't use any yet on linux).






      share|improve this answer
























      • diff -r will compare the directory contents recursively.

        – Kevin
        May 27 '12 at 20:37






      • 3





        Since the cd was burned from an already prepared iso image, there's nothing to be built differently when burning, so you can directly compare the cd with the iso image.

        – psusi
        May 28 '12 at 2:35














      2












      2








      2







      You can check that CD is fully readable by using dd (for example dd if=/dev/cdrom of=/dev/null). But you can't compare it directly with an ISO image. Each software will create slightly different ISO file (maybe some different headers, or padding), although these different ISO images will all provide the same CD contents (directory structure, file attributes and file contents).



      So you can only mount the CD, mount the ISO image and compare it at filesystem level by using some kind of directory comparison tool (sorry, I didn't use any yet on linux).






      share|improve this answer













      You can check that CD is fully readable by using dd (for example dd if=/dev/cdrom of=/dev/null). But you can't compare it directly with an ISO image. Each software will create slightly different ISO file (maybe some different headers, or padding), although these different ISO images will all provide the same CD contents (directory structure, file attributes and file contents).



      So you can only mount the CD, mount the ISO image and compare it at filesystem level by using some kind of directory comparison tool (sorry, I didn't use any yet on linux).







      share|improve this answer












      share|improve this answer



      share|improve this answer










      answered May 27 '12 at 18:48









      Marki555Marki555

      1,6781516




      1,6781516













      • diff -r will compare the directory contents recursively.

        – Kevin
        May 27 '12 at 20:37






      • 3





        Since the cd was burned from an already prepared iso image, there's nothing to be built differently when burning, so you can directly compare the cd with the iso image.

        – psusi
        May 28 '12 at 2:35



















      • diff -r will compare the directory contents recursively.

        – Kevin
        May 27 '12 at 20:37






      • 3





        Since the cd was burned from an already prepared iso image, there's nothing to be built differently when burning, so you can directly compare the cd with the iso image.

        – psusi
        May 28 '12 at 2:35

















      diff -r will compare the directory contents recursively.

      – Kevin
      May 27 '12 at 20:37





      diff -r will compare the directory contents recursively.

      – Kevin
      May 27 '12 at 20:37




      3




      3





      Since the cd was burned from an already prepared iso image, there's nothing to be built differently when burning, so you can directly compare the cd with the iso image.

      – psusi
      May 28 '12 at 2:35





      Since the cd was burned from an already prepared iso image, there's nothing to be built differently when burning, so you can directly compare the cd with the iso image.

      – psusi
      May 28 '12 at 2:35











      1














      If you still have the ISO, you can compare them byte by byte using cmp. It's a simple enough command and it exits on the first difference it finds, so it's considerably faster than making a checksum if there actually is an error early on.



      cmp /dev/cdrom /path/cdrom.iso


      Possible outcomes on success:




      • no output: it's identical and all OK. You may append && echo OK to the command if the lack of output confuses you.


      • cmp: EOF on cdrom.iso: it's identical but the cdrom has more bytes than your iso file. This is usually due to zero padding at the end of the cdrom. Since that does not matter in practice, it's still a success.


      Possible outcomes on failure:





      • cmp: EOF on /dev/cdrom: for some reason the data on your CDROM is incomplete. Maybe your ISO was too large to fit a real CD.


      • /dev/cdrom cdrom.iso differ: byte 18296321, line 71780: there is some unexpected difference between your CDROM and your ISO image.






      share|improve this answer




























        1














        If you still have the ISO, you can compare them byte by byte using cmp. It's a simple enough command and it exits on the first difference it finds, so it's considerably faster than making a checksum if there actually is an error early on.



        cmp /dev/cdrom /path/cdrom.iso


        Possible outcomes on success:




        • no output: it's identical and all OK. You may append && echo OK to the command if the lack of output confuses you.


        • cmp: EOF on cdrom.iso: it's identical but the cdrom has more bytes than your iso file. This is usually due to zero padding at the end of the cdrom. Since that does not matter in practice, it's still a success.


        Possible outcomes on failure:





        • cmp: EOF on /dev/cdrom: for some reason the data on your CDROM is incomplete. Maybe your ISO was too large to fit a real CD.


        • /dev/cdrom cdrom.iso differ: byte 18296321, line 71780: there is some unexpected difference between your CDROM and your ISO image.






        share|improve this answer


























          1












          1








          1







          If you still have the ISO, you can compare them byte by byte using cmp. It's a simple enough command and it exits on the first difference it finds, so it's considerably faster than making a checksum if there actually is an error early on.



          cmp /dev/cdrom /path/cdrom.iso


          Possible outcomes on success:




          • no output: it's identical and all OK. You may append && echo OK to the command if the lack of output confuses you.


          • cmp: EOF on cdrom.iso: it's identical but the cdrom has more bytes than your iso file. This is usually due to zero padding at the end of the cdrom. Since that does not matter in practice, it's still a success.


          Possible outcomes on failure:





          • cmp: EOF on /dev/cdrom: for some reason the data on your CDROM is incomplete. Maybe your ISO was too large to fit a real CD.


          • /dev/cdrom cdrom.iso differ: byte 18296321, line 71780: there is some unexpected difference between your CDROM and your ISO image.






          share|improve this answer













          If you still have the ISO, you can compare them byte by byte using cmp. It's a simple enough command and it exits on the first difference it finds, so it's considerably faster than making a checksum if there actually is an error early on.



          cmp /dev/cdrom /path/cdrom.iso


          Possible outcomes on success:




          • no output: it's identical and all OK. You may append && echo OK to the command if the lack of output confuses you.


          • cmp: EOF on cdrom.iso: it's identical but the cdrom has more bytes than your iso file. This is usually due to zero padding at the end of the cdrom. Since that does not matter in practice, it's still a success.


          Possible outcomes on failure:





          • cmp: EOF on /dev/cdrom: for some reason the data on your CDROM is incomplete. Maybe your ISO was too large to fit a real CD.


          • /dev/cdrom cdrom.iso differ: byte 18296321, line 71780: there is some unexpected difference between your CDROM and your ISO image.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Jul 23 '14 at 22:19









          frostschutzfrostschutz

          28.2k26093




          28.2k26093























              -1














              Brasero can do that:
              Tools -> Check integrity...






              share|improve this answer




























                -1














                Brasero can do that:
                Tools -> Check integrity...






                share|improve this answer


























                  -1












                  -1








                  -1







                  Brasero can do that:
                  Tools -> Check integrity...






                  share|improve this answer













                  Brasero can do that:
                  Tools -> Check integrity...







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered 2 hours ago









                  damian101damian101

                  11




                  11






























                      draft saved

                      draft discarded




















































                      Thanks for contributing an answer to Unix & Linux Stack Exchange!


                      • Please be sure to answer the question. Provide details and share your research!

                      But avoid



                      • Asking for help, clarification, or responding to other answers.

                      • Making statements based on opinion; back them up with references or personal experience.


                      To learn more, see our tips on writing great answers.




                      draft saved


                      draft discarded














                      StackExchange.ready(
                      function () {
                      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f39467%2fhow-to-verify-a-cd-against-an-iso-image%23new-answer', 'question_page');
                      }
                      );

                      Post as a guest















                      Required, but never shown





















































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown

































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown







                      Popular posts from this blog

                      Taj Mahal Inhaltsverzeichnis Aufbau | Geschichte | 350-Jahr-Feier | Heutige Bedeutung | Siehe auch |...

                      Baia Sprie Cuprins Etimologie | Istorie | Demografie | Politică și administrație | Arii naturale...

                      Nicolae Petrescu-Găină Cuprins Biografie | Opera | In memoriam | Varia | Controverse, incertitudini...