77

I have been using Brasero to rip my DVD collection to .iso. However, I've discovered some errors in some of the DVDs through playback e.g. VLC player would just stop playing the iso file when a bad section in playback is met (half-way through a film).

The worst thing is that no errors or warnings were thrown during the ripping process - I could have . Is there a method or application that will monitor DVD/file data integrity and avoid such scenarios in the future?

Anything equivalent to Exact Audio Copier or CDparanoia for DVDs?

nf313743
  • 941

16 Answers16

81

I think you can use dd to copy disks well. Using

dd if=/dev/cdrom of=image_name.iso

I can confirm it works well with CDs and should work well with DVDs too.

Edit: I just used this to rip a DVD, so I can confirm it works with DVDs too.

hg8
  • 13,582
Neojames
  • 1,744
41

I haven't found one link that points to what I believe is a correct answer. Most just say DD the CD/DVD. But there is an extra padding at the end of the media that may cause errors.

I should also point out this will work with most, but I ran into issues with Sony CSS/CPPM Protection, which I used another program to achieve the desired results.

Any, I've found the following to work great for me.. :

  1. get the info of the CD/DVD you're copying. I haven't tried this with an audio CD because I just rip them to flac's , but the following is a test on a DVD..

    # isoinfo -d -i /dev/sr1 | grep -i -E 'block size|volume size'
    Logical block size is: 2048
    Volume size is: 2264834
    

    We use the Logical block size for the BS= variable and Volume size for the COUNT=

  2. use DD to copy the DVD to an iso:

    # dd if=/dev/sr1 of=/mnt/incoming/test.iso bs=2048 count=2264834
    2264834+0 records in
    2264834+0 records out
    4638380032 bytes (4.6 GB, 4.3 GiB) copied, 373.405 s, 12.4 MB/s
    

    To monitor dd progress one alternative is to add status=progress.

  3. Test the image against the actual DVD..

    # md5sum /mnt/incoming/test.iso 
    d3a2cdd58b8c9ade05786526a4a8eae2  /mnt/incoming/test.iso
    

    md5sum /dev/sr1

    d3a2cdd58b8c9ade05786526a4a8eae2 /dev/sr1

Hope this helps someone looking for a complete answer.

Pablo Bianchi
  • 17,371
D1g1ta1
  • 511
  • 4
  • 4
16

Use dvdbackup.

Here's how to rip the entire DVD:

dvdbackup -i /dev/dvd -o ~ -M

That puts the DVD contents into a new subdirectory of your home directory (~). To then generate an .iso, use this command:

mkisofs -dvd-video -udf -o ~/dvd.iso ~/[movie_name]

If you want, you can alternatively only rip the main feature (see archlinux or sourceforge documentation). If you want a video file (e.g. .m4v) instead of an .iso, use handbrake after ripping the entire DVD (don't forget to install libdvdcss!).

There are ways to reduce the number of steps, but this seems to be more robust than alternatives.

I've been especially happy with the archlinux documentation.

P.S. I suspect that most of the answers were excellent at the time of writing, but I found them to be unhelpful at the time I'm writing this, so I thought I'd write an answer that works for me in case others are finding this question around the same time that I did.

jrennie
  • 489
13

You have several options, all work well in GNOME:

  • AcidRip Install acidrip is an automated front end for MPlayer/Mencoder (ripping and encoding DVD tool using mplayer and mencoder) written in Perl, using Gtk2::Perl for a graphical interface. Makes encoding a DVD just one button click!

    sudo apt install acidrip
    
  • dvd-rip Install dvdrip is a full featured DVD copy program written in Perl i.e. front end for transcode and ffmpeg. It provides an easy to use but feature-rich Gtk+ GUI to control almost all aspects of the ripping and transcoding process.

    It uses the widely known video processing swissknife transcode and many other Open Source tools. dvd::rip itself is licensed under GPL / Perl Artistic License. You can install dvd::rip as follows under Debian / Ubuntu Linux:

    sudo apt install dvdrip
    
  • K9copy Install k9copy is a KDE DVD Backup tool. It allows the copy of a DVD9 to a DVD5. It is also known as a Linux DVD shrink. It supports the following features: The video stream is compressed to make the video fit on a 4.7GB recordable DVD. DVD Burning. Creation of ISO images. Choosing which audio and subtitle tracks are copied. Title preview (video only). The ability to preserve the original menus.

    sudo apt install k9copy
    
Pablo Bianchi
  • 17,371
stephenmyall
  • 9,885
11

In case of a strong or weird anti-copy protection and the DVD is yours, you should decrypt the DVD first and then execute a fault-tolerant copy of it.

Install dependencies:

$ sudo apt install libdvd-pkg && sudo dpkg-reconfigure libdvd-pkg
$ sudo apt install mplayer gddrescue

Decrypt your DVD (assuming the device file is /dev/sr0):

$ mplayer -dvd-device /dev/sr0 dvd:// -vo null -ao null -ss 10 -endpos 1

Create the image:

$ ddrescue -n -b 2048 /dev/sr0 title.iso title.log

You can work on the image "title.iso" later on. ddrescue should have skipped garbled content if any.

Sahabia
  • 111
7

Brasero will accurately copy DVDs. You must first install 'libdvdcss2' from the VLC website. This allows Brasero to defeat the 'CSS' (Content Scramble System) which is used in commercial DVDs to prevent unauthorized copying.

RCline7
  • 536
5

Anything equivalent to Exact Audio Copier or CDparanoia for DVDs?

dvdisaster can do multiple passes if a sector is damaged, equivalently to CDparanoia. Example usage:

dvdisaster -d /dev/sr0 -i /path/to/output.iso --read-raw -r --read-attempts 5-20

It's in Ubuntu's universe repo.

serv-inc
  • 3,159
  • 1
  • 26
  • 32
4

Try using ddrescue. I was able to make a bitwise copy of my DVD with the following command with success from a cygwin command prompt:

ddrescue --no-scrape /dev/scd0 backup.iso

A similar command can be used on other variations of *inx. Of course you would have to download ddrescue for your flavour of *inx using the appropriate install app. See your *inx help pages for details.

Adrian
  • 201
3

Handbrake is in the default repositories of all currently supported versions of Ubuntu. To install it open the terminal and type:

sudo apt install handbrake  

To install the CLI version of Handbrake open the terminal and type:

sudo apt install handbrake-cli

The results of snap find handbrake will usually show that the version of handbrake-jz is the latest stable version of Handbrake. To install this handbrake snap package run these commands:

sudo snap install handbrake-jz

How to Rip DVDs Using HandBrake

  1. Open HandBrake.
  2. Choose the file you want to rip by selecting the File -> Open Single Title.
  3. Choose the destination to save the stored file by clicking the downward triangle ▼ next to To: in the lower right corner and browsing to the destination directory.
  4. Click the green Start icon at the top to begin ripping the DVD.
karel
  • 122,292
  • 133
  • 301
  • 332
2
mkisofs -r -o file.iso /dev/cdrom

This is just one example, feel free to check mkisofs --help to check all the other options.

user827992
  • 2,901
2

I add SimpleBurn (http://simpleburn.tuxfamily.org/ ), a minimalistic free Linux application enabling you to make ISO file from DVD disc easily and quickly. Of course, you will have to install libdvdcss2 in your Linux if you want to extract media content from the copy-protected DVD discs. For more DVD/Blu-ray digitizing tools and knowledge, visit my site at: http://dvd0101.com.

1

D1g1ta1's answer about using bs=# count=# at the end of the dd command successfully created 4.6GB .iso files of my 4.6GB DVD (of a Qubes OS 4.0 .iso). However upon calculating the sha256 hash, I found that the contents for some reason turned out different.

Using dd if=discDrive of=disc.iso, without parameters, works normally and produces and correct hash values. Before, my drive was acting up and it was producing the wrong hash value; in addition, before, my disc drive was not creating the full 4.6GB iso. I think my drive is just broken.

K3b is a GUI program. I found it successfully creates .iso files and the hashes calculated of the resulting .iso files are correct!

The Brasero program also works and the resulting .iso files are also correct.

Zanna
  • 72,312
1

There was a previous attempt to provide a "complete" answer, but it did not take CSS copy protection into account. So here's my attempt at a follow-up. I am taking the approach of trying the lightest touch first, and then moving on to increasingly aggressive approaches only as circumstances warrant.

If the DVD does not use CSS (content scramble system) encryption, then the simple dd command recommended in other answers will work.

(All code snippets are borrowed from previous answers)

# isoinfo -d -i /dev/sr1 | grep -i -E 'block size|volume size'
Logical block size is: 2048
Volume size is: 2264834

dd if=/dev/sr1 of=backup.iso bs=[Logical Block Size from above] count=[Volume size from above]

If the disc does use CSS encryption, but no other tricks such as "fake" bad blocks, then the dd command by itself may not work. This is because the firmware inside most DVD drives will recognize the presence of CSS encryption, and will refuse to allow low-level read access to any sectors that are marked as subject to copyright protection. You must use a program which invokes the DeCSS library (or something equivalent) to "unlock" the disc in the drive's firmware first, and then the dd command can do its job. The DeCSS library is not included by default a fresh Ubuntu installation, but there are instructions in the "Restricted Formats" section of the Ubuntu Wiki to install it. Be aware that using this software may carry legal consequences in some jurisdictions.

# apt install libdvd-pkg && dpkg-reconfigure libdvd-pkg
# apt install mplayer
# mplayer -dvd-device /dev/sr0 dvd:// -vo null -ao null -ss 10 -endpos 1

Now continue with the isoinfo and dd commands above

If the disc has both CSS encryption and additional protective measures such as fake bad blocks, then just unlocking the disc in the drive's firmware is not enough. Even though it is perfectly normal for such a disc to present unrecoverable errors when you attempt to read these fake bad blocks, the video content itself is actually completely intact. However, the normal dd command would likely abort at the first such block it encounters. ddrescue would be your friend in that case.

# apt install gddrescue

Use the instructions above to use a DeCSS-enabled player app to unlock the drive's firmware. Instead of moving on to isoinfo and dd, use ddrescue:

# ddrescue --no-scrape /dev/sr0 backup.iso
1

I have extracted to an .iso file with k3b (KDE based tool)

K3b Main Menu -> Tools -> Copy Medium

On the left, check "Create image" if not already checked and uncheck "Remove image" if it checked.

Click on the Image tab and pick a path for "Write image file to:"

E.g. "/home/me/tmp/myDvd.iso"

Click "Start"

Then just cancel the copy after the file has been extracted.

1

I used to use dd to rip my DVDs in the past, it required libdvdcss to work though.

sudo apt-get install libdvd-pkg
Byte Commander
  • 110,243
TGM
  • 602
0
mkisofs -pad -J -R -oDVD.iso -graft-points "/AUDIO_TS=/media/sr0/AUDIO_TS" "/VIDEO_TS=/media/sr0/VIDEO_TS"

mount -t iso9660 -o loop,ro DVD.iso /mnt

growisofs -dvd-compat -Z /dev/dvd=DVD.iso -speed=2
devav2
  • 37,290