Rip a CD/DVD to ISO format.

dd if=/dev/cdrom of=~/cdrom_image.iso
An easy method to generate ISOs from CD/DVD media.

By: o0110o
2012-07-10 06:03:25

6 Alternatives + Submit Alt

What Others Think

But... You don't have to remember the dd syntax. Under Unix, everything's a file, so these will work too: cp /dev/cdrom ~/cdrom_image.iso cat /dev/cdrom > ~/cdrom_image.iso
flatcap · 533 weeks and 2 days ago
@flatcap: That's good to know, thanks. I'm an Ubuntu user by default, lol.
o0110o · 533 weeks and 2 days ago
Wow, thats very good to know, flatcap. But does that mean you can do the opposite: cp ~/cdrom_image.iso > /dev/cdrom To write an ISO to a disk? I don't think it does, but why wouldn't that work then?
raikia · 533 weeks and 2 days ago
@o0110o: I should have been clearer. My two commands will work under all Unix-like OSs (Ubuntu included).
flatcap · 533 weeks and 2 days ago
@raikia: Hmm... Now you've got me. I don't know. I think not. cdroms are awkward things. It'll certainly work with most normal block devices. I sometime use that method for disks, e.g. cp /dev/sda1 2012_07_10_sda1.img cat 2012_07_10_sda1.img > /dev/sda1
flatcap · 533 weeks and 2 days ago
The only problem here is that there is no error checking or correction. The cdrecord package includes a command line tool called readcd that rips CDs to iso files quite nicely: readcd dev=<cdrom> f=foo.iso
oshu · 533 weeks and 2 days ago

What do you think?

Any thoughts on this command? Does it work on your machine? Can you do the same thing with only 14 characters?

You must be signed in to comment.

What's this? is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.

Share Your Commands

Stay in the loop…

Follow the Tweets.

Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.


Subscribe to the feeds.

Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):

Subscribe to the feed for: