Ubuntu – VirtualBox errors out when trying to install Ubuntu (failed to open ISO)

isovirtualboxvirtualization

Whenever I try to install Ubuntu 12.10/12.04 using the regular ISO in a VirtualBox VM, it does not work and produces the following error:

Failed to open the CD/DVD image
/home/ewt/Documents/iso/ubuntu-12.10-desktop-i386.iso.

Could not get the storage format of the medium
'/home/ewt/Documents/iso/ubuntu-12.10-desktop-i386.iso'
(VERR_NOT_SUPPORTED).

Result Code: VBOX_E_IPRT_ERROR (0x80BB0005) Component: Medium
Interface: IMedium {53f9cc0c-e0fd-40a5-a404-a7a5272082cd} Callee:
IVirtualBox {c28be65f-1a8f-43b4-81f1-eb60cb516e66}

Best Answer

Your ISO file is not the same as the release on the download servers and is probably corrupt. We've determined that from the comments - here's the how and why. In the meantime, just re-download it from a reliable source and check it using md5sum after download against the list of published hashes here: Ubuntu community wiki - UbuntuHashes.

Ubuntu installation media are large sets of downloads. For each file available, Ubuntu publishes SHA1, SHA256 and MD5 checksums (available on your favourite mirror, e.g. here). You can check the integrity of your copy by running the same checksum and verify it is the same as Ubuntu has published. If it matches, then both files are exactly the same1 and you're all set. In a case of a mismatch, several things could have caused it: download from an untrusted source, unreliable network connection, local file system corruption, etc.

Yours didn't match and produced a completely different string. All we know from there is that your image is different than the "official" ones on the Ubuntu servers. This may just be a harmless one-off, but if you downloaded it from an untrusted source, somebody may have altered it without you knowing it. Be careful in such a case.

This is why one should always check the integrity of the files you are running on your PC. Either an ISO or an application package. APT, the package management tool on Ubuntu, will check it for you already by verifying the integrity all the way from the developer last to touch it until it gets installed on your machine. This is done using GnuPG signatures and the keyring installed on your machine to check it against. However, for ISOs to install the operating system on, this isn't available yet, so you'll have to do it manually.

1There's a remote possibility of hash collisions, i.e. two different files producing the same hash. However, that's very very unlikely to be as a result of a coincedence.