www.fabiankeil.de/gehacktes/dvd-duplicate-detector/

How to efficiently rip and store DVDs with duplicated VOB files

Since a few years DVDs occasionally contain VOB files that are only stored on the disc once, but referenced multiple times on the file system level. Ripping such discs can waste a lot of space and as those discs usually also have lots of unreadable sectors can be really slow (hours instead of minutes).

Annoyed by this I wrote dvd-duplicate-detector.pl to deduplicate rips again to save space. Deduplicating at the end of the process doesn't save time, though, therefore the script can also prepare a directory before the rip is started, so only unique files are ripped. This saves both time and disk space, but only works with ripping software with resume support (skip files that already exist and have the expected size). The deduplication also requires a file system with hard-link support but that shouldn't be an issue.

Dependencies

dvd-duplicate-detector.pl takes the output of isoinfo -l as input to detect duplicates based on the starting addresses on the disc. isoinfo is part of the official cdrtools. dvd-duplicate-detector.pl probably also works with the Debian fork cdrkit, but I haven't tested it.

To actually rip the DVD I'm using dvdbackup extended with some patches to implement resume support and other stuff. Before I became aware of dvdbackup I used vobcopy, unmaintained patches are available.

Usage

Figure out the address of the DVD device

fk@r500 ~ $cdrecord -scanbus
Cdrecord-ProDVD-ProBD-Clone 3.01a10 (amd64-unknown-freebsd10.0) Copyright (C) 1995-2012 Joerg Schilling
Using libscg version 'schily-0.9'.
scsibus0:
	0,0,0	  0) '' '' '' NON CCS Disk
	0,1,0	  1) *
	0,2,0	  2) *
	0,3,0	  3) *
	0,4,0	  4) *
	0,5,0	  5) *
	0,6,0	  6) *
	0,7,0	  7) *
scsibus1:
	1,0,0	100) 'HL-DT-ST' 'DVDRAM GSA-T50N ' 'RX05' Removable CD-ROM
	1,1,0	101) *
	1,2,0	102) *
	1,3,0	103) *
	1,4,0	104) *
	1,5,0	105) *
	1,6,0	106) *
	1,7,0	107) *

Looks like the address on my system is 1,0,0.

Get the isoinfo

fk@r500 ~/dvds/diverse $isoinfo -l dev=1,0,0 > blafasel.isoinfo

Verify the result (optional)

Note the high number of files with a size of 1073739776 bytes. They only fit on the disc because some of them start at the same address.

fk@r500 ~/dvds/diverse $cat blafasel.isoinfo 
**BAD RRVERSION (0) in '  ' field 00 00.

Directory listing of /
d---------   0    0    0       2048 Jul 19 2005 [    259 02] . 
d---------   0    0    0       2048 Aug  1 2005 [    259 02] .. 
d---------   0    0    0       2048 Aug  1 2005 [    260 02] AUDIO_TS 
d---------   0    0    0       6144 Aug  1 2005 [    261 02] VIDEO_TS 

Directory listing of /AUDIO_TS/
d---------   0    0    0       2048 Aug  1 2005 [    260 02] . 
d---------   0    0    0       2048 Aug  1 2005 [    259 02] .. 

Directory listing of /VIDEO_TS/
d---------   0    0    0       6144 Aug  1 2005 [    261 02] . 
d---------   0    0    0       2048 Aug  1 2005 [    259 02] .. 
----------   0    0    0      40960 Aug  1 2005 [    549 00] VIDEO_TS.BUP;1 
----------   0    0    0      40960 Aug  1 2005 [    465 00] VIDEO_TS.IFO;1 
----------   0    0    0      98304 Aug  1 2005 [    485 00] VIDEO_TS.VOB;1 
----------   0    0    0      32768 Aug  1 2005 [    601 00] VTS_01_0.BUP;1 
----------   0    0    0      32768 Aug  1 2005 [    569 00] VTS_01_0.IFO;1 
----------   0    0    0      32768 Aug  1 2005 [    585 00] VTS_01_1.VOB;1 
----------   0    0    0      16384 Aug  1 2005 [  10346 00] VTS_02_0.BUP;1 
----------   0    0    0      16384 Aug  1 2005 [    617 00] VTS_02_0.IFO;1 
----------   0    0    0   17696768 Aug  1 2005 [    625 00] VTS_02_0.VOB;1 
----------   0    0    0    2211840 Aug  1 2005 [   9266 00] VTS_02_1.VOB;1 
----------   0    0    0     163840 Aug  1 2005 [2569097 00] VTS_03_0.BUP;1 
----------   0    0    0     163840 Aug  1 2005 [  10354 00] VTS_03_0.IFO;1 
----------   0    0    0  440711168 Aug  1 2005 [  11231 00] VTS_03_0.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 226422 00] VTS_03_1.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 750709 00] VTS_03_2.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1274996 00] VTS_03_3.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1799283 00] VTS_03_4.VOB;1 
----------   0    0    0  502839296 Aug  1 2005 [2323570 00] VTS_03_5.VOB;1 
----------   0    0    0     196608 Aug  1 2005 [2569177 00] VTS_04_0.BUP;1 
----------   0    0    0     196608 Aug  1 2005 [  10434 00] VTS_04_0.IFO;1 
----------   0    0    0  440711168 Aug  1 2005 [  11231 00] VTS_04_0.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 226422 00] VTS_04_1.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 750709 00] VTS_04_2.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1274996 00] VTS_04_3.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1799283 00] VTS_04_4.VOB;1 
----------   0    0    0  502839296 Aug  1 2005 [2323570 00] VTS_04_5.VOB;1 
----------   0    0    0     196608 Aug  1 2005 [2569273 00] VTS_05_0.BUP;1 
----------   0    0    0     196608 Aug  1 2005 [  10530 00] VTS_05_0.IFO;1 
----------   0    0    0  440711168 Aug  1 2005 [  11231 00] VTS_05_0.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 226422 00] VTS_05_1.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 750709 00] VTS_05_2.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1274996 00] VTS_05_3.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1799283 00] VTS_05_4.VOB;1 
----------   0    0    0  502839296 Aug  1 2005 [2323570 00] VTS_05_5.VOB;1 
----------   0    0    0     196608 Aug  1 2005 [2569369 00] VTS_06_0.BUP;1 
----------   0    0    0     196608 Aug  1 2005 [  10626 00] VTS_06_0.IFO;1 
----------   0    0    0  440711168 Aug  1 2005 [  11231 00] VTS_06_0.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 226422 00] VTS_06_1.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 750709 00] VTS_06_2.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1274996 00] VTS_06_3.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1799283 00] VTS_06_4.VOB;1 
----------   0    0    0  502839296 Aug  1 2005 [2323570 00] VTS_06_5.VOB;1 
----------   0    0    0     163840 Aug  1 2005 [2569465 00] VTS_07_0.BUP;1 
----------   0    0    0     163840 Aug  1 2005 [  10722 00] VTS_07_0.IFO;1 
----------   0    0    0  440711168 Aug  1 2005 [  11231 00] VTS_07_0.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 226422 00] VTS_07_1.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 750709 00] VTS_07_2.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1274996 00] VTS_07_3.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1799283 00] VTS_07_4.VOB;1 
----------   0    0    0  502839296 Aug  1 2005 [2323570 00] VTS_07_5.VOB;1 
----------   0    0    0      92160 Aug  1 2005 [2569545 00] VTS_08_0.BUP;1 
----------   0    0    0      92160 Aug  1 2005 [  10802 00] VTS_08_0.IFO;1 
----------   0    0    0  440711168 Aug  1 2005 [  11231 00] VTS_08_0.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 226422 00] VTS_08_1.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 750709 00] VTS_08_2.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1274996 00] VTS_08_3.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1799283 00] VTS_08_4.VOB;1 
----------   0    0    0  502839296 Aug  1 2005 [2323570 00] VTS_08_5.VOB;1 
----------   0    0    0     163840 Aug  1 2005 [2569590 00] VTS_09_0.BUP;1 
----------   0    0    0     163840 Aug  1 2005 [  10847 00] VTS_09_0.IFO;1 
----------   0    0    0  440711168 Aug  1 2005 [  11231 00] VTS_09_0.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 226422 00] VTS_09_1.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 750709 00] VTS_09_2.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1274996 00] VTS_09_3.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1799283 00] VTS_09_4.VOB;1 
----------   0    0    0  502839296 Aug  1 2005 [2323570 00] VTS_09_5.VOB;1 
----------   0    0    0     131072 Aug  1 2005 [2569670 00] VTS_10_0.BUP;1 
----------   0    0    0     131072 Aug  1 2005 [  10927 00] VTS_10_0.IFO;1 
----------   0    0    0  440711168 Aug  1 2005 [  11231 00] VTS_10_0.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 226422 00] VTS_10_1.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 750709 00] VTS_10_2.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1274996 00] VTS_10_3.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1799283 00] VTS_10_4.VOB;1 
----------   0    0    0  502839296 Aug  1 2005 [2323570 00] VTS_10_5.VOB;1 
----------   0    0    0     163840 Aug  1 2005 [2569734 00] VTS_11_0.BUP;1 
----------   0    0    0     163840 Aug  1 2005 [  10991 00] VTS_11_0.IFO;1 
----------   0    0    0  440711168 Aug  1 2005 [  11231 00] VTS_11_0.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 226422 00] VTS_11_1.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 750709 00] VTS_11_2.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1274996 00] VTS_11_3.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1799283 00] VTS_11_4.VOB;1 
----------   0    0    0  502839296 Aug  1 2005 [2323570 00] VTS_11_5.VOB;1 
----------   0    0    0     163840 Aug  1 2005 [2569814 00] VTS_12_0.BUP;1 
----------   0    0    0     163840 Aug  1 2005 [  11071 00] VTS_12_0.IFO;1 
----------   0    0    0  440711168 Aug  1 2005 [  11231 00] VTS_12_0.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 226422 00] VTS_12_1.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 750709 00] VTS_12_2.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1274996 00] VTS_12_3.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1799283 00] VTS_12_4.VOB;1 
----------   0    0    0  502839296 Aug  1 2005 [2323570 00] VTS_12_5.VOB;1 
----------   0    0    0     163840 Aug  1 2005 [2569894 00] VTS_13_0.BUP;1 
----------   0    0    0     163840 Aug  1 2005 [  11151 00] VTS_13_0.IFO;1 
----------   0    0    0  440711168 Aug  1 2005 [  11231 00] VTS_13_0.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 226422 00] VTS_13_1.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [ 750709 00] VTS_13_2.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1274996 00] VTS_13_3.VOB;1 
----------   0    0    0 1073739776 Aug  1 2005 [1799283 00] VTS_13_4.VOB;1 
----------   0    0    0  502839296 Aug  1 2005 [2323570 00] VTS_13_5.VOB;1

Prepare the directory you want to rip into

fk@r500 ~/dvds/diverse $dvd-duplicate-detector.pl --deduplicate-directory BLAFASEL < blafasel.isoinfo 
Creating BLAFASEL
Master files:
VIDEO_TS/VIDEO_TS.BUP
VIDEO_TS/VIDEO_TS.IFO
VIDEO_TS/VIDEO_TS.VOB
VIDEO_TS/VTS_01_0.BUP
VIDEO_TS/VTS_01_0.IFO
VIDEO_TS/VTS_01_1.VOB
VIDEO_TS/VTS_02_0.BUP
VIDEO_TS/VTS_02_0.IFO
VIDEO_TS/VTS_02_0.VOB
VIDEO_TS/VTS_02_1.VOB
VIDEO_TS/VTS_03_0.BUP
VIDEO_TS/VTS_03_0.IFO
VIDEO_TS/VTS_03_0.VOB
VIDEO_TS/VTS_03_1.VOB
VIDEO_TS/VTS_03_2.VOB
VIDEO_TS/VTS_03_3.VOB
VIDEO_TS/VTS_03_4.VOB
VIDEO_TS/VTS_03_5.VOB
VIDEO_TS/VTS_04_0.BUP
VIDEO_TS/VTS_04_0.IFO
VIDEO_TS/VTS_05_0.BUP
VIDEO_TS/VTS_05_0.IFO
VIDEO_TS/VTS_06_0.BUP
VIDEO_TS/VTS_06_0.IFO
VIDEO_TS/VTS_07_0.BUP
VIDEO_TS/VTS_07_0.IFO
VIDEO_TS/VTS_08_0.BUP
VIDEO_TS/VTS_08_0.IFO
VIDEO_TS/VTS_09_0.BUP
VIDEO_TS/VTS_09_0.IFO
VIDEO_TS/VTS_10_0.BUP
VIDEO_TS/VTS_10_0.IFO
VIDEO_TS/VTS_11_0.BUP
VIDEO_TS/VTS_11_0.IFO
VIDEO_TS/VTS_12_0.BUP
VIDEO_TS/VTS_12_0.IFO
VIDEO_TS/VTS_13_0.BUP
VIDEO_TS/VTS_13_0.IFO
Duplicates that can be replaced with links:
VIDEO_TS/VTS_04_0.VOB -> VIDEO_TS/VTS_03_0.VOB
Checking existence of VIDEO_TS/VTS_04_0.VOB
The original VIDEO_TS/VTS_03_0.VOB doesn't exist yet. Creating a placeholder.
Linking VIDEO_TS/VTS_04_0.VOB to VIDEO_TS/VTS_03_0.VOB
VIDEO_TS/VTS_04_1.VOB -> VIDEO_TS/VTS_03_1.VOB
Checking existence of VIDEO_TS/VTS_04_1.VOB
The original VIDEO_TS/VTS_03_1.VOB doesn't exist yet. Creating a placeholder.
Linking VIDEO_TS/VTS_04_1.VOB to VIDEO_TS/VTS_03_1.VOB
VIDEO_TS/VTS_04_2.VOB -> VIDEO_TS/VTS_03_2.VOB
Checking existence of VIDEO_TS/VTS_04_2.VOB
The original VIDEO_TS/VTS_03_2.VOB doesn't exist yet. Creating a placeholder.
Linking VIDEO_TS/VTS_04_2.VOB to VIDEO_TS/VTS_03_2.VOB
VIDEO_TS/VTS_04_3.VOB -> VIDEO_TS/VTS_03_3.VOB
Checking existence of VIDEO_TS/VTS_04_3.VOB
The original VIDEO_TS/VTS_03_3.VOB doesn't exist yet. Creating a placeholder.
Linking VIDEO_TS/VTS_04_3.VOB to VIDEO_TS/VTS_03_3.VOB
VIDEO_TS/VTS_04_4.VOB -> VIDEO_TS/VTS_03_4.VOB
Checking existence of VIDEO_TS/VTS_04_4.VOB
The original VIDEO_TS/VTS_03_4.VOB doesn't exist yet. Creating a placeholder.
Linking VIDEO_TS/VTS_04_4.VOB to VIDEO_TS/VTS_03_4.VOB
VIDEO_TS/VTS_04_5.VOB -> VIDEO_TS/VTS_03_5.VOB
Checking existence of VIDEO_TS/VTS_04_5.VOB
The original VIDEO_TS/VTS_03_5.VOB doesn't exist yet. Creating a placeholder.
Linking VIDEO_TS/VTS_04_5.VOB to VIDEO_TS/VTS_03_5.VOB
VIDEO_TS/VTS_05_0.VOB -> VIDEO_TS/VTS_03_0.VOB
Checking existence of VIDEO_TS/VTS_05_0.VOB
Linking VIDEO_TS/VTS_05_0.VOB to VIDEO_TS/VTS_03_0.VOB
VIDEO_TS/VTS_05_1.VOB -> VIDEO_TS/VTS_03_1.VOB
Checking existence of VIDEO_TS/VTS_05_1.VOB
Linking VIDEO_TS/VTS_05_1.VOB to VIDEO_TS/VTS_03_1.VOB
VIDEO_TS/VTS_05_2.VOB -> VIDEO_TS/VTS_03_2.VOB
Checking existence of VIDEO_TS/VTS_05_2.VOB
Linking VIDEO_TS/VTS_05_2.VOB to VIDEO_TS/VTS_03_2.VOB
VIDEO_TS/VTS_05_3.VOB -> VIDEO_TS/VTS_03_3.VOB
Checking existence of VIDEO_TS/VTS_05_3.VOB
Linking VIDEO_TS/VTS_05_3.VOB to VIDEO_TS/VTS_03_3.VOB
VIDEO_TS/VTS_05_4.VOB -> VIDEO_TS/VTS_03_4.VOB
Checking existence of VIDEO_TS/VTS_05_4.VOB
Linking VIDEO_TS/VTS_05_4.VOB to VIDEO_TS/VTS_03_4.VOB
VIDEO_TS/VTS_05_5.VOB -> VIDEO_TS/VTS_03_5.VOB
Checking existence of VIDEO_TS/VTS_05_5.VOB
Linking VIDEO_TS/VTS_05_5.VOB to VIDEO_TS/VTS_03_5.VOB
VIDEO_TS/VTS_06_0.VOB -> VIDEO_TS/VTS_03_0.VOB
Checking existence of VIDEO_TS/VTS_06_0.VOB
Linking VIDEO_TS/VTS_06_0.VOB to VIDEO_TS/VTS_03_0.VOB
VIDEO_TS/VTS_06_1.VOB -> VIDEO_TS/VTS_03_1.VOB
Checking existence of VIDEO_TS/VTS_06_1.VOB
Linking VIDEO_TS/VTS_06_1.VOB to VIDEO_TS/VTS_03_1.VOB
VIDEO_TS/VTS_06_2.VOB -> VIDEO_TS/VTS_03_2.VOB
Checking existence of VIDEO_TS/VTS_06_2.VOB
Linking VIDEO_TS/VTS_06_2.VOB to VIDEO_TS/VTS_03_2.VOB
VIDEO_TS/VTS_06_3.VOB -> VIDEO_TS/VTS_03_3.VOB
Checking existence of VIDEO_TS/VTS_06_3.VOB
Linking VIDEO_TS/VTS_06_3.VOB to VIDEO_TS/VTS_03_3.VOB
VIDEO_TS/VTS_06_4.VOB -> VIDEO_TS/VTS_03_4.VOB
Checking existence of VIDEO_TS/VTS_06_4.VOB
Linking VIDEO_TS/VTS_06_4.VOB to VIDEO_TS/VTS_03_4.VOB
VIDEO_TS/VTS_06_5.VOB -> VIDEO_TS/VTS_03_5.VOB
Checking existence of VIDEO_TS/VTS_06_5.VOB
Linking VIDEO_TS/VTS_06_5.VOB to VIDEO_TS/VTS_03_5.VOB
VIDEO_TS/VTS_07_0.VOB -> VIDEO_TS/VTS_03_0.VOB
Checking existence of VIDEO_TS/VTS_07_0.VOB
Linking VIDEO_TS/VTS_07_0.VOB to VIDEO_TS/VTS_03_0.VOB
VIDEO_TS/VTS_07_1.VOB -> VIDEO_TS/VTS_03_1.VOB
Checking existence of VIDEO_TS/VTS_07_1.VOB
Linking VIDEO_TS/VTS_07_1.VOB to VIDEO_TS/VTS_03_1.VOB
VIDEO_TS/VTS_07_2.VOB -> VIDEO_TS/VTS_03_2.VOB
Checking existence of VIDEO_TS/VTS_07_2.VOB
Linking VIDEO_TS/VTS_07_2.VOB to VIDEO_TS/VTS_03_2.VOB
VIDEO_TS/VTS_07_3.VOB -> VIDEO_TS/VTS_03_3.VOB
Checking existence of VIDEO_TS/VTS_07_3.VOB
Linking VIDEO_TS/VTS_07_3.VOB to VIDEO_TS/VTS_03_3.VOB
VIDEO_TS/VTS_07_4.VOB -> VIDEO_TS/VTS_03_4.VOB
Checking existence of VIDEO_TS/VTS_07_4.VOB
Linking VIDEO_TS/VTS_07_4.VOB to VIDEO_TS/VTS_03_4.VOB
VIDEO_TS/VTS_07_5.VOB -> VIDEO_TS/VTS_03_5.VOB
Checking existence of VIDEO_TS/VTS_07_5.VOB
Linking VIDEO_TS/VTS_07_5.VOB to VIDEO_TS/VTS_03_5.VOB
VIDEO_TS/VTS_08_0.VOB -> VIDEO_TS/VTS_03_0.VOB
Checking existence of VIDEO_TS/VTS_08_0.VOB
Linking VIDEO_TS/VTS_08_0.VOB to VIDEO_TS/VTS_03_0.VOB
VIDEO_TS/VTS_08_1.VOB -> VIDEO_TS/VTS_03_1.VOB
Checking existence of VIDEO_TS/VTS_08_1.VOB
Linking VIDEO_TS/VTS_08_1.VOB to VIDEO_TS/VTS_03_1.VOB
VIDEO_TS/VTS_08_2.VOB -> VIDEO_TS/VTS_03_2.VOB
Checking existence of VIDEO_TS/VTS_08_2.VOB
Linking VIDEO_TS/VTS_08_2.VOB to VIDEO_TS/VTS_03_2.VOB
VIDEO_TS/VTS_08_3.VOB -> VIDEO_TS/VTS_03_3.VOB
Checking existence of VIDEO_TS/VTS_08_3.VOB
Linking VIDEO_TS/VTS_08_3.VOB to VIDEO_TS/VTS_03_3.VOB
VIDEO_TS/VTS_08_4.VOB -> VIDEO_TS/VTS_03_4.VOB
Checking existence of VIDEO_TS/VTS_08_4.VOB
Linking VIDEO_TS/VTS_08_4.VOB to VIDEO_TS/VTS_03_4.VOB
VIDEO_TS/VTS_08_5.VOB -> VIDEO_TS/VTS_03_5.VOB
Checking existence of VIDEO_TS/VTS_08_5.VOB
Linking VIDEO_TS/VTS_08_5.VOB to VIDEO_TS/VTS_03_5.VOB
VIDEO_TS/VTS_09_0.VOB -> VIDEO_TS/VTS_03_0.VOB
Checking existence of VIDEO_TS/VTS_09_0.VOB
Linking VIDEO_TS/VTS_09_0.VOB to VIDEO_TS/VTS_03_0.VOB
VIDEO_TS/VTS_09_1.VOB -> VIDEO_TS/VTS_03_1.VOB
Checking existence of VIDEO_TS/VTS_09_1.VOB
Linking VIDEO_TS/VTS_09_1.VOB to VIDEO_TS/VTS_03_1.VOB
VIDEO_TS/VTS_09_2.VOB -> VIDEO_TS/VTS_03_2.VOB
Checking existence of VIDEO_TS/VTS_09_2.VOB
Linking VIDEO_TS/VTS_09_2.VOB to VIDEO_TS/VTS_03_2.VOB
VIDEO_TS/VTS_09_3.VOB -> VIDEO_TS/VTS_03_3.VOB
Checking existence of VIDEO_TS/VTS_09_3.VOB
Linking VIDEO_TS/VTS_09_3.VOB to VIDEO_TS/VTS_03_3.VOB
VIDEO_TS/VTS_09_4.VOB -> VIDEO_TS/VTS_03_4.VOB
Checking existence of VIDEO_TS/VTS_09_4.VOB
Linking VIDEO_TS/VTS_09_4.VOB to VIDEO_TS/VTS_03_4.VOB
VIDEO_TS/VTS_09_5.VOB -> VIDEO_TS/VTS_03_5.VOB
Checking existence of VIDEO_TS/VTS_09_5.VOB
Linking VIDEO_TS/VTS_09_5.VOB to VIDEO_TS/VTS_03_5.VOB
VIDEO_TS/VTS_10_0.VOB -> VIDEO_TS/VTS_03_0.VOB
Checking existence of VIDEO_TS/VTS_10_0.VOB
Linking VIDEO_TS/VTS_10_0.VOB to VIDEO_TS/VTS_03_0.VOB
VIDEO_TS/VTS_10_1.VOB -> VIDEO_TS/VTS_03_1.VOB
Checking existence of VIDEO_TS/VTS_10_1.VOB
Linking VIDEO_TS/VTS_10_1.VOB to VIDEO_TS/VTS_03_1.VOB
VIDEO_TS/VTS_10_2.VOB -> VIDEO_TS/VTS_03_2.VOB
Checking existence of VIDEO_TS/VTS_10_2.VOB
Linking VIDEO_TS/VTS_10_2.VOB to VIDEO_TS/VTS_03_2.VOB
VIDEO_TS/VTS_10_3.VOB -> VIDEO_TS/VTS_03_3.VOB
Checking existence of VIDEO_TS/VTS_10_3.VOB
Linking VIDEO_TS/VTS_10_3.VOB to VIDEO_TS/VTS_03_3.VOB
VIDEO_TS/VTS_10_4.VOB -> VIDEO_TS/VTS_03_4.VOB
Checking existence of VIDEO_TS/VTS_10_4.VOB
Linking VIDEO_TS/VTS_10_4.VOB to VIDEO_TS/VTS_03_4.VOB
VIDEO_TS/VTS_10_5.VOB -> VIDEO_TS/VTS_03_5.VOB
Checking existence of VIDEO_TS/VTS_10_5.VOB
Linking VIDEO_TS/VTS_10_5.VOB to VIDEO_TS/VTS_03_5.VOB
VIDEO_TS/VTS_11_0.VOB -> VIDEO_TS/VTS_03_0.VOB
Checking existence of VIDEO_TS/VTS_11_0.VOB
Linking VIDEO_TS/VTS_11_0.VOB to VIDEO_TS/VTS_03_0.VOB
VIDEO_TS/VTS_11_1.VOB -> VIDEO_TS/VTS_03_1.VOB
Checking existence of VIDEO_TS/VTS_11_1.VOB
Linking VIDEO_TS/VTS_11_1.VOB to VIDEO_TS/VTS_03_1.VOB
VIDEO_TS/VTS_11_2.VOB -> VIDEO_TS/VTS_03_2.VOB
Checking existence of VIDEO_TS/VTS_11_2.VOB
Linking VIDEO_TS/VTS_11_2.VOB to VIDEO_TS/VTS_03_2.VOB
VIDEO_TS/VTS_11_3.VOB -> VIDEO_TS/VTS_03_3.VOB
Checking existence of VIDEO_TS/VTS_11_3.VOB
Linking VIDEO_TS/VTS_11_3.VOB to VIDEO_TS/VTS_03_3.VOB
VIDEO_TS/VTS_11_4.VOB -> VIDEO_TS/VTS_03_4.VOB
Checking existence of VIDEO_TS/VTS_11_4.VOB
Linking VIDEO_TS/VTS_11_4.VOB to VIDEO_TS/VTS_03_4.VOB
VIDEO_TS/VTS_11_5.VOB -> VIDEO_TS/VTS_03_5.VOB
Checking existence of VIDEO_TS/VTS_11_5.VOB
Linking VIDEO_TS/VTS_11_5.VOB to VIDEO_TS/VTS_03_5.VOB
VIDEO_TS/VTS_12_0.VOB -> VIDEO_TS/VTS_03_0.VOB
Checking existence of VIDEO_TS/VTS_12_0.VOB
Linking VIDEO_TS/VTS_12_0.VOB to VIDEO_TS/VTS_03_0.VOB
VIDEO_TS/VTS_12_1.VOB -> VIDEO_TS/VTS_03_1.VOB
Checking existence of VIDEO_TS/VTS_12_1.VOB
Linking VIDEO_TS/VTS_12_1.VOB to VIDEO_TS/VTS_03_1.VOB
VIDEO_TS/VTS_12_2.VOB -> VIDEO_TS/VTS_03_2.VOB
Checking existence of VIDEO_TS/VTS_12_2.VOB
Linking VIDEO_TS/VTS_12_2.VOB to VIDEO_TS/VTS_03_2.VOB
VIDEO_TS/VTS_12_3.VOB -> VIDEO_TS/VTS_03_3.VOB
Checking existence of VIDEO_TS/VTS_12_3.VOB
Linking VIDEO_TS/VTS_12_3.VOB to VIDEO_TS/VTS_03_3.VOB
VIDEO_TS/VTS_12_4.VOB -> VIDEO_TS/VTS_03_4.VOB
Checking existence of VIDEO_TS/VTS_12_4.VOB
Linking VIDEO_TS/VTS_12_4.VOB to VIDEO_TS/VTS_03_4.VOB
VIDEO_TS/VTS_12_5.VOB -> VIDEO_TS/VTS_03_5.VOB
Checking existence of VIDEO_TS/VTS_12_5.VOB
Linking VIDEO_TS/VTS_12_5.VOB to VIDEO_TS/VTS_03_5.VOB
VIDEO_TS/VTS_13_0.VOB -> VIDEO_TS/VTS_03_0.VOB
Checking existence of VIDEO_TS/VTS_13_0.VOB
Linking VIDEO_TS/VTS_13_0.VOB to VIDEO_TS/VTS_03_0.VOB
VIDEO_TS/VTS_13_1.VOB -> VIDEO_TS/VTS_03_1.VOB
Checking existence of VIDEO_TS/VTS_13_1.VOB
Linking VIDEO_TS/VTS_13_1.VOB to VIDEO_TS/VTS_03_1.VOB
VIDEO_TS/VTS_13_2.VOB -> VIDEO_TS/VTS_03_2.VOB
Checking existence of VIDEO_TS/VTS_13_2.VOB
Linking VIDEO_TS/VTS_13_2.VOB to VIDEO_TS/VTS_03_2.VOB
VIDEO_TS/VTS_13_3.VOB -> VIDEO_TS/VTS_03_3.VOB
Checking existence of VIDEO_TS/VTS_13_3.VOB
Linking VIDEO_TS/VTS_13_3.VOB to VIDEO_TS/VTS_03_3.VOB
VIDEO_TS/VTS_13_4.VOB -> VIDEO_TS/VTS_03_4.VOB
Checking existence of VIDEO_TS/VTS_13_4.VOB
Linking VIDEO_TS/VTS_13_4.VOB to VIDEO_TS/VTS_03_4.VOB
VIDEO_TS/VTS_13_5.VOB -> VIDEO_TS/VTS_03_5.VOB
Checking existence of VIDEO_TS/VTS_13_5.VOB
Linking VIDEO_TS/VTS_13_5.VOB to VIDEO_TS/VTS_03_5.VOB

If you feel like it you can obviously pipe the isoinfo output into dvd-duplicate-detector.pl directly.

Verify the result (optional)

The directory should now exist and contain a bunch of empty files with a link count above 1.

fk@r500 ~/dvds/diverse $ls -lR BLAFASEL/
total 9
drwxr-x---  2 fk  fk  68 2012-12-30 20:36:59 VIDEO_TS/

BLAFASEL/VIDEO_TS:
total 33
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_03_0.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_03_1.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_03_2.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_03_3.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_03_4.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_03_5.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_04_0.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_04_1.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_04_2.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_04_3.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_04_4.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_04_5.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_05_0.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_05_1.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_05_2.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_05_3.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_05_4.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_05_5.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_06_0.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_06_1.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_06_2.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_06_3.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_06_4.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_06_5.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_07_0.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_07_1.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_07_2.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_07_3.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_07_4.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_07_5.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_08_0.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_08_1.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_08_2.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_08_3.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_08_4.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_08_5.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_09_0.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_09_1.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_09_2.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_09_3.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_09_4.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_09_5.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_10_0.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_10_1.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_10_2.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_10_3.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_10_4.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_10_5.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_11_0.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_11_1.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_11_2.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_11_3.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_11_4.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_11_5.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_12_0.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_12_1.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_12_2.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_12_3.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_12_4.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_12_5.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_13_0.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_13_1.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_13_2.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_13_3.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_13_4.VOB
-rw-r-----  11 fk  fk  0 2012-12-30 20:36:59 VTS_13_5.VOB

Resume the rip

You can now resume the rip. An application with resume support will only rip unique file and skip over the duplicates as they'll already have the right size due to being hard links to a unique file.

fk@r500 ~/dvds/diverse $dvdbackup -M --error=f -v -p -i /dev/cd0 -n BLAFASEL

I'll add the expected dvdbackup output in the future.