The Pragmatic Addict

Create ISO disc images

I’m a linux command line junkie. Every once in a while I need to make an ISO image file of something on a CD/DVD/Blu-Ray. This is an ongoing article that will be updated as I learn more about the task.

CD (Compact Disc) 750MB

This is by far the easiest one to do on virtually any Linux machine. Because a CD has zero copy protection, you just do a byte-for-byte copy

dd status=progress if=/dev/sr0 of=./mycd.iso

DVD (Digital Versatile Disc) 7.5GB

Now we get into the ‘fun’ part. A DVD is not only region locked but has physical errors on it to prevent doing the CD method. To get around this you need to extract all the files off of the disc then reassemble them into an ISO file.

But wait, there’s more, in order to read the disc you’ll need libdvdcss2. In most Debian distributions this is not available, you’ll need to use the deb-multimedia repository. The resulting ISO image will be stripped of all copy protections.

dvdbackup --mirror --input=/dev/sr0 --name=dvdfiles
genisoimage -dvd-video -udf -V dvdname -o dvdname.iso dvdfiles/

Blu-Ray 41GB

This format is different than DVD in that the copy protection is in the data on the disc. Unlike DVD there are no hard errors on the disc to stop a copy so the CD method works here. In order to play these back at minimum you’ll need libaacs to handle the aacs encryption.

dd status=progress if=/dev/sr0 of=./mybluray.iso

Playstation 1 (PSX) 750MB

The normal dd command won’t work with this format due to all the copy protection errors on the disc. You can open the resuting .cue file as an iso in your favorite emulator.

apt-get install cdrdao
cdrdao read-cd --read-raw --datafile "output.bin" --device /dev/sr0 --driver generic-mmc-raw "output.toc"
toc2cue output.toc output.cue

Playstation 2 (PS2) 750MB-7.5GB

The Playstation 2 dropped all hard errors on it’s discs (CD & DVD Formats). The normal dd command works!

dd status=progress if=/dev/sr0 of=./mycd.iso

Created: 2024-04-09 Modified: 2024-05-09