How to create an ISO image from an optical disc on Linux

Creating an ISO image from a data CD, DVD, or Blu-ray turns the disc into a single file that is easier to archive, checksum, mount, and reuse than the original media. The saved image can be attached to a virtual machine, copied to another system, or written back to removable media without returning to the physical disc.

On Linux, a data disc usually appears as a read-only block device such as /dev/sr0. Reading that device with dd copies the disc data into an .iso file, and the saved image can then be inspected or mounted with the same filesystem-aware tools used for any other ISO 9660 image.

This workflow is for data discs that the kernel exposes as a normal optical drive device. Audio CDs, mixed-mode discs, damaged media, and copy-protected discs often need different tools, the destination filesystem needs free space at least equal to the disc size, and reading the optical device usually requires sudo privileges.

Steps to create an ISO image from an optical disc in Linux:

  1. List block devices and identify the optical drive device name.
    $ lsblk --list --output NAME,SIZE,TYPE,RO,MOUNTPOINTS
    NAME        SIZE TYPE RO MOUNTPOINTS
    nvme0n1   476.9G disk  0
    nvme0n1p1    1G part  0 /boot/efi
    nvme0n1p2 475.9G part  0 /
    sr0         4.3G rom   1

    Use the read-only rom entry for the inserted disc. Optical drives commonly appear as /dev/sr0, but systems with multiple drives can expose /dev/sr1 or another /dev/sr* path instead.

  2. Create a destination directory for the image file.
    $ mkdir -p ~/iso-backups
  3. Copy the optical disc into an .iso file with dd.
    $ sudo dd if=/dev/sr0 of=~/iso-backups/archive-disc.iso bs=2048 status=progress conv=fsync
    185+0 records in
    185+0 records out
    378880 bytes (379 kB, 370 KiB) copied, 0.0257333 s, 14.7 MB/s

    Replace /dev/sr0 with the actual optical device from lsblk. status=progress prints transfer statistics while the copy is running, and conv=fsync waits for the image file to be flushed before dd exits.

    If dd reports an input/output error, treat the saved file as incomplete and retry only after cleaning the disc, trying another drive, or switching to a recovery-oriented workflow.

  4. Confirm that the saved file is recognized as an ISO image.
    $ file ~/iso-backups/archive-disc.iso
    /home/operator/iso-backups/archive-disc.iso: ISO 9660 CD-ROM filesystem data 'ARCHIVE_DISC'

    The volume label shown by file comes from the disc and can differ from this example.

  5. Create a temporary mountpoint and mount the image read-only for a quick content check.
    $ sudo mkdir -p /mnt/archive-disc
    $ sudo mount -o loop,ro ~/iso-backups/archive-disc.iso /mnt/archive-disc

    Loop-mounting the image confirms that the saved file can be read like the original optical disc without putting the media back in the drive.

  6. List the top-level contents of the mounted image to confirm that the expected files are present.
    $ ls -1 /mnt/archive-disc
    README.txt
    docs
  7. Unmount the image when the verification check is complete.
    $ sudo umount /mnt/archive-disc