Rip DVDs in Linux the (Semi-)Easy Way
Posted by Kevin Purdy at 4:00 AM on December 8, 2007

With its hacker-friendly aesthetic and open source mentality, you'd think a Linux desktop would be the best place to assert your digital rights—you know, make backup copies of your DVDs, convert them for iPods, that kind of thing.
And you'd be half right. There are plenty of programs that let you take control of your video discs, but they're only useful if you can make it through a maze of configuration menus, command line options, choices about bit rates and codecs, and the occasional confusing message about a missing library.
I've tried out a good number of DVD ripping and conversion programs, and I've made peace with one method, and one program, that gets the job done more often than not. It's not exactly one-click, but once your system is set up, you can drop in DVDs and back them up or convert them with relative ease.Note on system differences: I set up my ripping/burning system on a Lenovo Thinkpad T61 running a brand-new installation of Ubuntu 7.10 (Gutsy Gibbon). As with so many things Linux, packages and commands may vary based on your system. But for the most part, the tools I use in this walkthrough work across distributions and on both major desktop environments, GNOME and KDE.
Make your system media-friendly
The key ingredient to ripping in Linux is enabling your system to read encrypted DVDs—the kind you buy and rent. Since Linux lacks (to my knowledge) a licensed DVD player, we'll be using the libdvdcss2 package to get access. You might find the libdvdcss2 package in your distro's repositories, but you'll definitely find it at the VideoLAN web site, and Ubuntu users can install it from the Medibuntu site.
If you're going to be shrinking your DVDs down to portable media formats like DivX or MPEG-4, you need the corresponding codecs installed. For Ubuntu users, that means heading to Applications->Add/Remove, typing in gstreamer and installing all the packages that come up, along with installing the w32codecs package from the Medibuntu source above. In other distros, try searching your installation programs for terms like "codec," "divx," "restricted," and other relevant phrases.
The program I'll be using to shrink dual-layer DVDs down to burn-able size is K9Copy, available in many repositories. It's straight-forward, it doesn't ask 47 questions about your bitrate preferences, and it works mostly on its own. Although it's KDE based, it runs in GNOME environments without too many required libraries.
Finally, here are the programs I recommend for playing and burning video files and ISOs. Use what you know best, but I've had the best success with these selections:
- VLC Media Player: Just like on Windows and Mac, the Linux version of this all-in-one wonder plays nearly anything resembling video or audio. You could use it to play back entire DVD backup folders, as Adam prefers, or even play the DVD image itself.
- DeVeDe and ManDVD: For creating burnable DVD images from video files. DeVeDe can handle fancier conversions, but ManDVD lets you create some pretty slick-looking front-end menus.
- K3b or GnomeBaker: These burning programs for KDE and GNOME seem to just work, and often catch errors before burning rather than create coasters, in my experience.
Getting started
Load a DVD into your drive, launch K9copy and select the blue folder icon in the top left corner. The title contents of your disc will be displayed, but don't touch any of that yet. Hit the "Settings" menu and select "Configure K9Copy."
Select the "DVD" category on the left of the menu that pops up, then change the "Output directory" to a convenient location. This is where the "AUDIO_TS" and "VIDEO_TS" folders that make up a DVD will go before an ISO is made. I had trouble getting the folders to go into a Windows-formatted storage partition on my Ubuntu system, and while I think KDE-based users might have more success, plan on having at least 9 GB free on your actual Ext3 (or Linux-formatted) drive or partition. You can change the "DVD size" setting here if you have trouble burning to disc, but the default 4400 MB is what most single-layer DVD-Rs can hold.
Now select the MPEG-4 category, unless you don't plan on compressing DVDs down to video files. I've found success choosing the XviD codec, selecting the "2 pass" option and changing the codec under the "Audio" tab to AC3, but video geeks will know what to do here. You can also easily opt for better quality rips and larger files by adjusting the "File size" option in the "Video" tab or splitting the rips onto two or more CD-Rs. Note that these are just the default settings; you can rip to another format, like the iPod-friendly MPEG-4 using the "MPEG4 Encoding Options" tab at the main window's bottom edge.
Hit "OK," and now it's time to choose what we want to retain from the DVD. If you want to copy everything—including menus, featurettes and all the language and subtitle tracks—select the "DVD Playback Options" menu from the right-hand edge and check the "Keep original menus" button at the bottom. Otherwise, you can go title by title through the DVD, deciding which audio, video and subtitle tracks to drop for better picture quality. If you're unsure what to pick, hit the camera button at the top left to preview the video and change the subtitle and audio options to see what's best.
Let 'er rip
Now make sure the "ISO image" output device is selected, and then click either the MPEG4 or Copy buttons (or choose from the Actions menu) to start ripping. I found my ripping times to be about even with DVD Shrink in Windows, but certainly faster than if I ran DVD Shrink in WINE or other Windows emulators. After it finishes, you're most of the way there—you can burn the ISOs to DVD-Rs, watch the backups in your media player, or use the video files wherever you can play 'em. K9Copy has an option to burn directly to DVDs, but I haven't read too many great things about it.
As I said earlier, this is what worked for me, and I've read similar success stories in Linux forums and amongst our own commenters. Die-hard GNOME users who never install KDE-applications might check out a similar program, DVD95, but I found the interface a bit too confusing for a first-timer.
Have a better system for ripping DVDs on your Linux box? Know an uber-command-line trick that does the job every time? Let's hear about it in the comments.
Kevin Purdy is a guest editor at Lifehacker who's thrilled that he's now able to back up the entire Michael Mann canon.

Comments (AU Comments · US Comments)
There are currently no AU comments for this post.
voxstin
Posted 10:00 PM 7/12/07
@katemines: There are many legitimate reasons for one to want to rip his or her DVD collection. Here's just one. My brother is physically disabled, and physically cannot walk to his DVD player to change DVDs. So I ripped all of his DVDs (each of which was legally purchased from Wal-Mart) on to a computer harddrive. And now he accesses his ENTIRE dvd collection through the interface of his Xbox. Voila...
One more example for prosperity's sake. I rip all of my DVDs, and shrink them so that I can watch them from my Treo telephone while I'm on the subway.
So. No one's trying to take the food off of your table; but why are ya'll trying to take our write as consumers away from us?
voxstin
OctaneZ
Posted 9:39 PM 7/12/07
There is also the always venerable Handbrake. It's CLI but easy to understand, just run it with "--help" and you'll be on your way.
My one complaint is that it's multi-threading seems to stop at two cores for the video and one core for the audio, though that may be a limitation of the transcoding going on.
OctaneZ
Andrewski
Posted 9:19 PM 7/12/07
Also, if you just want a backup copy of the movies themselves on your computer (I know I do), take a look at Thoggen: [thoggen.net] Very simple, does its job well.
Also, on Ubuntu, you can just install 'ubuntu-restricted-extras', described here: [help.ubuntu.com] I believe it'll automatically set up the repositories for you.
Andrewski
ecpepper
Posted 6:18 PM 7/12/07
I actually found myself doing precisely this yesterday morning (and, to our actor friend KATEMINES, I was not making illegal copies. I was extracting clips of individual scenes to show in one of my lecture courses.)
I had a question, though, that I might as well ask here. The default settings for K9Copy specify a width of 640 pixels. Am I right in thinking that most DVDs are 720 pixels wide and that I should change that value to get a true DVD-quality video?
ecpepper
-emory-
Posted 4:56 PM 7/12/07
Well I've jsut gotten back into full Dvd backing up craze again, and I've found that dvd:rip works great! Simply back it up first, then transcode to avi with the same program. It can save sessions too, so you don't have to do it in one sitting! Works GREAT. DEVEDE i've foudn works great for bruning those avi files to dvd.
-emory-
massysett
Posted 4:51 PM 7/12/07
"Since Linux lacks (to my knowledge) a licensed DVD player,"
If you buy Mandriva, Xandros, etc., you'll pay your ransom to the DVD licensors and get a fully licensed player.
massysett
jbravo188
Posted 2:21 PM 7/12/07
Thanks Adam! The link didn't work but a quick yahoo search : and I'm downloading now!
jbravo188
Therevan
Posted 2:06 PM 7/12/07
@ADM: Thanks, ADM! I was hoping somebody would share their command line tips. In researching this, I found a lot of instructions, but yours is much more straight-forward. I'll have to give it a try.
Therevan
ADM
Posted 1:51 PM 7/12/07
you can also use dvd::rip, which is simple after you use it once.
or if you want to use the command line, the easiest is dvd-backup:
apt-get install dvdbackup
then:
dvdbackup -M -i/dev/dvd -o/mnt/mydrive/movies/
where /dev/dvd is your DVD drive and /mnt/myrdrive/movies is the directory you want a directory for that movie to be created in.
DVD backup leaves you with a VIDEO_TS folder; dvd::rip leaves you with de-CSS'd .vob files. So it's not transcoding it like your solution, but it does only take 20 minutes and the results from either program are viewable in VLC.
ADM
SuperChuck
Posted 1:50 PM 7/12/07
I love k9copy. It's incredibly simple, and it just plain works.
SuperChuck
katemines
Posted 1:49 PM 7/12/07
I am a big fan of your website but am a little frusterated by this posting. There is a strike going on in Hollywood right now because people aren't being paid for their work. I am an actor not a writer and I dont make very much money doing it. When you rip a DVD its money taken out of the pockets of the people who put in time and effort to do good work and they are not being reimbursed for that. Please remember that every time you rip a DVD.
katemines
Adam Pash, LH Senior Editor
Posted 1:32 PM 7/12/07
@jbravo188: any one know of any free non-trial software out there (windows)? Try this on for size:
[lifehacker.com]
Good luck!
Adam Pash, LH Senior Editor
jbravo188
Posted 1:24 PM 7/12/07
i know this is for Linux but i'm having the damdest time burning an .avi movie onto a watchable dvd, any one know of any free non-trial software out there, i was using intervideo windvd, it doesn't like me anymore. Thanks
jbravo188
Jason
Posted 9:14 AM 8/12/07
Kate, the money parade may just be over for the huge chain of distributors and other parasites that value-add for themselves on top of the work that you and other media producers do. They are the reason movies cost $8 in the theatre. Time and tech wait for no man, and if media companies don't think fast and smart to find a new distribution model, it'll be the dustbin of history for them.
Can anyone come up with a commandline that automatically rips DVDs as soon as they're put in the drive?
Jason
Will
Posted 6:23 AM 8/12/07
@katemines: "When you rip a DVD its money taken out of the pockets of the people who put in time and effort to do good work and they are not being reimbursed for that."
I think you have confused ripping a DVD with pirating a movie. It is not legal to pirate a movie, however it is perfectly legal to rip a DVD to a different format, which is explained in this post. Personally though, if I didn't get paid enough for what I did, I would find a new job.
Will
BackDoorAngel
Posted 4:10 AM 8/12/07
for those who'd rather 'wine' about it (such a bad pun, but obligatory it seems) DVD Dectripter, DVD Shrink, and Ripit4me all work fairly well in linux.
It's also good to note that many DVDs won't work with K9 copy since newer copy protections evolve faster than K9 copy is updated to circumvent them. I've had good luck with Ripit4me under Debian etch wine 9.49
download links:
[www.softpedia.com]
[www.dvddecrypter.org.uk]
[www.filehippo.com]
BackDoorAngel
wildeny
Posted 12:18 AM 8/12/07
How about the region code?
wildeny
Adam Chernow
Posted 11:11 AM 8/12/07
@katemines: Notice nowhere was it ever mentioned that he was going to share the ripped files. All he is doing is showing us how to make a back-up of our DVDs, which last time I checked was still perfectly legal.
Adam Chernow
bts3685
Posted 10:30 AM 8/12/07
@Jason:
i don't know of any tools per se, but a simple bash script should do it.
here's what you would need to do:
1. tell it to monitor for when a disc is inserted
(my guess is that it shows up in dmesg).
2. test to see if the disc is blank or not (not sure how one would do this; anyone else? maybe mounting it, trying to do an ls -a on it and if the # of files is >1, then initiate the rest of the script, else spit an error message back... maybe something with MIME or encoding types?)
3. call one of the above CLI dvd utils to initiate the rip (optional: prompt the user for where they want to save the image to).
4. (optional) prompt user to insert blank DVD to burn image to.
4b. (optional) when done, prompt user if they want to burn another copy or if they're finished.
i wish i knew more about BASHing to help you out more specifically, but if you give that list to some of the script gurus in ##linux on irc.freenode.net, i'm sure they'll whip something together for you (because it'd be something the whole community could benefit from). just remember to ask nice and politely, and be generous with detailed info (preferrably in a pastebin such as www.pastebin.ca).
bts3685
emmetp
Posted 9:58 AM 8/12/07
aciudrip works! and it's in the ubuntu repositories!
emmetp
whiskey
Posted 1:31 PM 9/12/07
@katemines: When you want to protect your own investment against the wear and tear of using it constantly (say, that LazyTown or Barney DVD won't last much if you leave it to your kids, but they have to learn to play their own movies), you make a copy of it, granted you won't be showing both copies at the same time, you will keep said DVD on it's case, only bringing it back once your backup has been effectively destroyed...
The Writers Guild of America struggle has nothing to do with creating perfectly legal backups of your own stuff, (and that is why it says do not make ILLEGAL copies of this material), it has to do with TV corps not sharing fairly the benefits of placing and selling content online with the writers.
whiskey
Therevan
Posted 6:46 AM 9/12/07
@wildeny: I didn't find that to be a problem, nor did it come up. In fact, this method has rescued an Australian copy of "Dark City" my mom accidentally bought for me for Christmas a year ago from the garbage.
Therevan
daengbo
Posted 12:34 AM 10/12/07
@JASON
If you're using Ubuntu 7.10, it's quite easy to rip. First install a command-line transcoder like ffmpeg (sudo aptitude install ffmpeg). In the menu, go to
System -> Preferences -> Removable Drives and Media
In the Multimedia tab, choose to play video DVD disks and insert the following command:
ffmpeg -i dvd://1 ~/Desktop/movie.avi
This should work fo all movies where dvd://1 is the main feature. Look up more on ffmpeg to get options like language and subtitles.
daengbo
somerandomnerd
Posted 5:29 AM 12/12/07
@KateMines,
There is a strike going on in Hollywood right now because writers aren't being paid fairly for their work. Specifically, because they aren't being paid a fair rate for their work when it's released on video and digital formats; the people who make DVD cases are paid a bigger share of the DVD sales than the screenwriters of a film sold on DVD. The share they get for downloads is even less, and as digital download starts eating into televisions' market share (ie. they get paid for TV-on-demand at the same negligible rate that they are paid for digital downloads), this could get much worse for them in the very near future.
I live in the UK, so most US-only download services aren't available to me, I don't actually have the option of supporting the studios who have created this situation and forced the writers guild into a strike, but I would argue that copying your own DVDs for your own use is hardly hurting the writers guild's cause.
somerandomnerd
youkai
Posted 11:18 PM 8/12/07
I ripped my entire DVD collection to my hard drive (over 300 discs), and wrote a script to help automate the process. At its core, it uses dvdbackup, but it eliminates all unnecessary interaction with you by:
- Automatically starts ripping as soon as the DVD is inserted
- Automatically names the subdirectory using the DVD label.
- Ejects the DVD when done, so you just have to pop in the next disc.
The only time you have to interact with it, is when the DVD label is blank, or it's a duplicate name with a DVD you already ripped.
0) Before starting, install dvdbackup
1) Download the script from here, and save it somewhere (like ~/ripdvd)
[cct-public.s3.amazonaws.com]
2) Make sure it is executable with 'chmod a+x ~/ripdvd'
3) Open it up in an editor, and change the 'backup_dir=' line to specify the directory where you want it to place all your DVD subdirectories.
4) In GNOME, go to System->Preferences->Removable Drives/Media->Multimedia, and set the "Play DVD when inserted" command to "/home//ripdvd %d" (I don't know how to do this in other types of desktop environments)
Then, insert a DVD. A Terminal window (primitive, isn't it?) will pop up with the script output. If it doesn't like the default name, it will beep, and ask you to enter a different one. After ripping, it will eject, and you can put in another disc, and the process will start over. Meanwhile, back in the terminal window, it will have asked you if you want to rename it from the default name. If not, just press ENTER.
Hope folks find this helpful.
youkai
clownsoup
Posted 11:53 AM 8/12/07
Oh, and as for converting an AVI into DVD in Linux; I just use Ubuntu, WINE and ConvertXtoDVD. It won't burn to DVD, but it converts like a charm and I can burn with K3b
clownsoup
clownsoup
Posted 11:49 AM 8/12/07
@ VOXSTIN: There are many legitimate reasons for one to want to rip his or her DVD collection.
And another one is that my young children have damaged many expensive Disney DVDs beyond repair. ALAS! If only I had some means to legally archive content that I purchased! Then I could buy the DVD and archive it on cheap media and not pay $25 every time my 5yo scratched a dvd beyond repair!
Seriously tho; Thanks to DVD Shrink I have saved boatloads of money by archiving my purchased content. Young children can be rough on media.
clownsoup
Jaymoon
Posted 10:36 AM 8/12/07
You can also just run the perfect combination under Wine: DVD Decryptor and DVD Shrink.
And in most cases, DVD Shrink is all that you need to copy a DVD to an .ISO image.
As far as the speeds, copying DVDs in DVD Shrink take about the same time as they do on my Windows machines...
Jaymoon
jhckr
Posted 10:45 PM 7/12/07
I agree with VOXSTIN. I have also digitized almost all of my DVDs so I can access any of them from any computer/set-top-box on my home network using MythVideo (a MythTV plugin). I can also watch these DVD rips on my archos media player.
I prefer mplayer and mencoder for ripping and transcoding myself because they are scriptable and fast.
Ripping (Dump the whole movie into one de-CSS'ed VOB file):
mplayer dvd://$TITLE -dvd-device /dev/dvd -v -v -dumpstream -dumpfile out.vob
Transcoding (3 passes):
CACHE=out.vob
OUT=final_output.avi
A_ID=128
A_BITRATE=192
V_BITRATE=1200
mencoder "$CACHE" -oac mp3lame -lameopts abr:br=$A_BITRATE:mode=0 -aid $A_ID -af volume=15:sc -ovc frameno -o frameno.avi
mencoder "$CACHE" -oac copy -ovc lavc -lavcopts vcodec=mpeg4:vhq:v4mv:vqmin=2:vbitrate=${V_BITRATE}:vpass=1 -vf pp=de -aid $A_ID -o "/dev/null"
mencoder "$CACHE" -oac copy -ovc lavc -lavcopts vcodec=mpeg4:vhq:v4mv:vqmin=2:vbitrate=${V_BITRATE}:vpass=2 -vf pp=de -aid $A_ID -o "$OUT"
jhckr
spr0k3t
Posted 6:00 PM 7/12/07
I like acidrip. The default settings are a little low (made for DVD 2 CD rips) so just a few default changes is needed, but it's a simple 1 click rip and you're done. I have my entire library backed up. A good 1 click ripping software for those redmond users out there... dvdshrink or the open source (multiplatform) handbreak.
spr0k3t
SoSaysSunny
Posted 2:24 AM 14/12/07
My situation is a little different ...
I'd like to rip a couple of my DVDs to audio-only CDs to listen to during my hour-long commute (creating TRUE soundtracks).
Of all the possible solutions folks have provided, which would work for this task and be the simplest (to setup and/or to execute)?
Thanks for any help you can give,
Sunny
SoSaysSunny