I bought a cheap IDE DVD ROM drive for my linux workstation. Getting the bloody thing to work took me almost a week. Here's the problems and answers I have. Your milage may vary.
I purchased a Diamond Data 16x IDE DVD ROM drive from Ascent Computers in Wellington. They're a good supplier for New Zealanders.
My home machine at the time was this
The physical installation of a DVD drive is straight-forward. The drive may be installed as a master or slave, but it must be the only master or the only slave.
Data DVDs can be mounted without needing all the changes described below. All you need to do is to make sure that your system supports udf as a filesystem. Try cat /proc/filesystems and look for a line "udf"
If you don't have that, as root modprobe udf. If that doesn't insert the module then your kernel needs to be recompiled. Consult your distro's documentation for further help.
Then all you need to do is mount /dev/hdd /mnt -t udf as root.
Here's the output from a df -h with "The Matrix" mounted...
tramadol:/var/www/linux-dvd> df -h Filesystem Size Used Avail Use% Mounted on /dev/hda3 37G 11G 24G 32% / /dev/hda1 38M 15M 22M 40% /boot caffeine:shared 43G 34G 6.2G 85% /shared /dev/hdd 7.7G 7.7G 0 100% /dvd
All DVD movie disks have a udf filesystem, and a directory named \VIDEO_TS Inside that directory are all the files that make up the movie you would see on a normal DVD player.
Again, The Matrix...
tramadol:/var/www/linux-dvd> l /dvd/VIDEO_TS/ -h total 7.1G -r--r--r-- 1 4294967295 4294967295 18K Oct 14 1999 VIDEO_TS.BUP -r--r--r-- 1 4294967295 4294967295 18K Oct 14 1999 VIDEO_TS.IFO -r--r--r-- 1 4294967295 4294967295 208K Oct 14 1999 VIDEO_TS.VOB -r--r--r-- 1 4294967295 4294967295 34K Oct 14 1999 VTS_01_0.BUP -r--r--r-- 1 4294967295 4294967295 34K Oct 14 1999 VTS_01_0.IFO -r--r--r-- 1 4294967295 4294967295 0 Oct 14 1999 VTS_01_0.VOB -r--r--r-- 1 4294967295 4294967295 839M Oct 14 1999 VTS_01_1.VOB -r--r--r-- 1 4294967295 4294967295 136K Oct 14 1999 VTS_02_0.BUP -r--r--r-- 1 4294967295 4294967295 136K Oct 14 1999 VTS_02_0.IFO -r--r--r-- 1 4294967295 4294967295 55M Oct 14 1999 VTS_02_0.VOB -r--r--r-- 1 4294967295 4294967295 1.0G Oct 14 1999 VTS_02_1.VOB -r--r--r-- 1 4294967295 4294967295 1.0G Oct 14 1999 VTS_02_2.VOB -r--r--r-- 1 4294967295 4294967295 309M Oct 14 1999 VTS_02_3.VOB -r--r--r-- 1 4294967295 4294967295 1.0G Oct 14 1999 VTS_02_4.VOB -r--r--r-- 1 4294967295 4294967295 1.0G Oct 14 1999 VTS_02_5.VOB -r--r--r-- 1 4294967295 4294967295 887M Oct 14 1999 VTS_02_6.VOB -r--r--r-- 1 4294967295 4294967295 46K Oct 14 1999 VTS_03_0.BUP -r--r--r-- 1 4294967295 4294967295 46K Oct 14 1999 VTS_03_0.IFO -r--r--r-- 1 4294967295 4294967295 0 Oct 14 1999 VTS_03_0.VOB -r--r--r-- 1 4294967295 4294967295 1009M Oct 14 1999 VTS_03_1.VOB tramadol:/var/www/linux-dvd>
The first three files describe the DVD and chapters, angles, subtitles, etc that are available. The .VOB files are mpeg stream data, and make up the movie proper.
Run dmesg | less and you should see a line or two like this...
hda: ST340810A, ATA DISK drive ide0 at 0x1f0-0x1f7,0x3f6 on irq 14 ide1 at 0x170-0x177,0x376 on irq 15 hdc: Hewlett-Packard CD-Writer Plus 9100, ATAPI CD/DVD-ROM drive hdd: DVD-ROM 16X, ATAPI CD/DVD-ROM drive
Now, most likely you're using the ide-cd module for access to IDE CDROM drives. Thats okay for file access, but for playing DVDs in linux you MUST use ide-scsi.
Check in the output of dmesg; if you see a chunk like this:
Uniform CD-ROM driver Revision: 3.12 hdc: ATAPI 32X CD-ROM CD-R/RW drive, 4096kB Cache, UDMA(33) hdd: ATAPI 16X DVD-ROM drive, 256kB Cache, UDMA(100)
Or if this command returns some lines:
dmesg | grep "CD-ROM driver"
Then you're using the ide-cd module. Remove all the modules with
rmmod ide-cd cdrom sr_mod
Then you need to do this, again as root:
modprobe ide-scsi modprobe sr_mod
If you do this correctly then run dmesg again, and at the bottom should be a section like this: (from inserting ide-scsi)
scsi0 : SCSI host adapter emulation for IDE ATAPI devices Vendor: HP Model: CD-Writer+ 9100 Rev: 1.0c Type: CD-ROM ANSI SCSI revision: 02 scsi1 : SCSI host adapter emulation for IDE ATAPI devices Vendor: DVD-ROM Model: 16X Rev: 5.CV Type: CD-ROM ANSI SCSI revision: 02
(from inserting sr_mod)
sr0: scsi3-mmc drive: 32x/32x writer cd/rw xa/form2 cdda tray Uniform CD-ROM driver Revision: 3.12 Attached scsi CD-ROM sr0 at scsi0, channel 0, id 0, lun 0 sr1: scsi3-mmc drive: 16x/16x cd/rw xa/form2 cdda tray Attached scsi CD-ROM sr1 at scsi1, channel 0, id 0, lun 0
What does this mean? Well now your linux box is emulating a SCSI adapter, and also that the IDE CDROM drives are also SCSI. My first drive is the writer /dev/hdc which is now referred to as /dev/sr0, and the DVD drive at /dev/hdd is now /dev/sr1
You will have to edit your /etc/fstab to make sure the lines for the cdrom refer to /dev/srX rather than /dev/hdX
In addition, you should set up a symlink from /dev/dvd to /dev/srX (where srX is the DVD drive.) Many utilities look at /dev/dvd for the disk.
You do not need to mount a DVD in order to play the movie.
Burning CDs. If you use an IDE CD burner, and you have been using cdrecord with the "dev=ATAPI:0,0,0" parameter, then you may need to change to "dev=0,0,0" because ide-scsi has taken over the IDE writer.
Your boot loader (probably lilo or grub) can be configured to tell the kernel to use ide-scsi for one drive and cdrom for another. Add a line like this:
to use ide-scsi emulation on hdb, but to leave hdc as a regular cdrom or data-only DVD drive.
Kernel 2.6.x has removed devfs, so links like /dev/dvd are not made automatically, and they're not remembered across reboots. You may need to make them another way.
What does this error mean?
libdvdread: Using libdvdcss version 1.2.5 for DVD access libdvdread: Can't seek to block 256 libdvdread: Can't open file VIDEO_TS.IFO
It means that you aren't using ide-scsi for the DVD drive. Read and follow this page.
My frame rate is crappy - why? Probably because you have a junk video card, like me. This machine has an on-board Trident CyberBlade video card, which is "adequate" for office users. I have seen a PII 266 playing DVD full screen, using an Nvidia graphics card, whereas this Celeron 1GHz returns 11-16 FPS in ogle. The answer, upgrade your video card (may mean a new motherboard.)
Still to fix... XXX
Regions - explain RPCII and zones
Why are some VOB files zero bytes long?
Why the naming system of VTS_0x_y.VOB? I guess that X is the layer (DVDs being several layers thick)
What is the /AUDIO_TS directory for on some DVDs?
Why do some disks have a windowsie AUTORUN.INF file?
Why is the owner of all those files "4294967295" ?
This file last modified Sunday January 23, 2005
If you find something here useful, feel free to donate bitcoin: Donations address: 14LHst9s1UEh8NMem87qaEd9tJWSCiNt1x.