1

I'm trying to install Ubuntu from a live USB but always encounter errors in the copying files installation phase.

The error message says that this I/O error are commonly due to faulty Medium or HDD. I'm checking my SSD and making a new Live USB to try again.

So this is my concern I can md5sum the ISO I download, but how do I check the live USB is good?

5
  • I would suspect that other hardware is throwing the error , such as motherboard. I've used same USB that I was using for 3 other installations for an old PC , as well as live CD, but in no way it was successfull. I had to use another computer with SATA to USB controller to install Ubuntu there and then plug in the HDD back to the computer. Nov 22, 2015 at 21:38
  • I don't get it @Serg . His question is asking about how does he check the live USB is good? right
    – BeGood
    Nov 22, 2015 at 21:45
  • probably not enough ram, try this instead help.ubuntu.com/community/Installation/MinimalCD
    – mchid
    Nov 22, 2015 at 21:47
  • @BeGood If you've read the question, you can see that OP mentioned I/O error while trying to install from a live USB. Live USB itself may be totally fine, but there may be issue with other hardware. Nov 22, 2015 at 21:48
  • Voted to reopen because this question is not a duplicate of the linked question: they're asking how to check if the Live USB has defects, not how to check which defect(s) it has (which would imply by premise that the Live USB is defective, which is something yet to be determined).
    – kos
    Apr 13, 2016 at 5:53

1 Answer 1

3

You can check the integrity of the image written to the USB drive by checking its MD5 sum against the original ISO's MD5 sum:

  1. Check the original ISO's size:

    % ls -l archlinux-2015.10.01-dual.iso 
    -rwxrwxr-x 1 user user 689963008 nov 22 21:35 archlinux-2015.10.01-dual.iso
    
  2. Run this command (replace /dev/sdc with the actual device and change 689963008 according to the original ISO's size):

    sudo dd if=/dev/sdc iflag=fullblock count=$((689963008/512)) 2>/dev/null | md5sum -
    
  3. Check the output against the original ISO's MD5 sum.

If you want to get fancy:

  1. Enable the Universe repository (you can do that in Software & Updates);

  2. Install pv: sudo apt-get install pv;

  3. Check the original ISO's size:

    % ls -l archlinux-2015.10.01-dual.iso 
    -rwxrwxr-x 1 user user 689963008 nov 22 21:35 archlinux-2015.10.01-dual.iso
    
  4. Run this command (replace /dev/sdc with the actual device and change 689963008 according to the original ISO's size):

    sudo dd if=/dev/sdc iflag=fullblock count=$((689963008/512)) 2>/dev/null | pv -s 689963008 | md5sum -
    
  5. Check the output against the original ISO's MD5 sum.

19
  • Please explain the downvote. This method works perfectly, so I guess the problem is elsewhere.
    – kos
    Nov 22, 2015 at 21:16
  • Does it work with LiveUSB ?. I mean after make a boots file in USB, whole file are extracted from iso.
    – BeGood
    Nov 22, 2015 at 21:19
  • 1
    @BeGood Not sure what you mean exactly, but this will work either if done from an installed system or from a Live USB, even if the running system has been booted from the Live USB itself.
    – kos
    Nov 22, 2015 at 21:26
  • 1
    @user3005629 Yes, I didn't mention that you'll have to enable the Universe repository in order to install pv (you can do that in Software & Updates).
    – kos
    Nov 22, 2015 at 21:40
  • 1
    @BeGood My bad, I thought that option would have run a S.M.A.R.T. test or something. Then yes it's basically the same, but you don't necessarily need to boot the Live USB.
    – kos
    Nov 22, 2015 at 21:49

Not the answer you're looking for? Browse other questions tagged or ask your own question.