DVD playback broken ("Media region code is mismatched to logical unit region")

Bug #502426 reported by Jens Grassel
64
This bug affects 12 people
Affects Status Importance Assigned to Milestone
libdvdread (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

I just upgraded my Dell XPS M1330 to version 9.10 and since then I can no longer play dvds.

No matter what player (totem, mplayer, vlc, dvdrip) I try nothing works.

The syslog is cluttered with lines like this:

Jan 2 22:00:19 tjalfi kernel: [ 981.470251] sr 3:0:0:0: [sr0] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
Jan 2 22:00:19 tjalfi kernel: [ 981.470263] sr 3:0:0:0: [sr0] Sense Key : Illegal Request [current]
Jan 2 22:00:19 tjalfi kernel: [ 981.470273] sr 3:0:0:0: [sr0] Add. Sense: Media region code is mismatched to logical unit region
Jan 2 22:00:19 tjalfi kernel: [ 981.470288] end_request: I/O error, dev sr0, sector 215848
Jan 2 22:00:19 tjalfi kernel: [ 981.470298] Buffer I/O error on device sr0, logical block 26981
Jan 2 22:00:19 tjalfi kernel: [ 981.470312] Buffer I/O error on device sr0, logical block 26982
Jan 2 22:00:19 tjalfi kernel: [ 981.470319] Buffer I/O error on device sr0, logical block 26983
Jan 2 22:00:19 tjalfi kernel: [ 981.470325] Buffer I/O error on device sr0, logical block 26984
Jan 2 22:00:19 tjalfi kernel: [ 981.470332] Buffer I/O error on device sr0, logical block 26985
Jan 2 22:00:19 tjalfi kernel: [ 981.470338] Buffer I/O error on device sr0, logical block 26986
Jan 2 22:00:19 tjalfi kernel: [ 981.470344] Buffer I/O error on device sr0, logical block 26987
Jan 2 22:00:19 tjalfi kernel: [ 981.470351] Buffer I/O error on device sr0, logical block 26988
Jan 2 22:00:19 tjalfi kernel: [ 981.470358] Buffer I/O error on device sr0, logical block 26989
Jan 2 22:00:19 tjalfi kernel: [ 981.470364] Buffer I/O error on device sr0, logical block 26990
Jan 2 22:00:27 tjalfi init: ureadahead-other main process (7527) terminated with status 4

I tried nearly 200 different dvds and was able to play none of them.

Revision history for this message
Daniel Letzeisen (dtl131) wrote :

You do have libdvdcss installed, correct? http://packages.medibuntu.org/karmic/libdvdcss2.html

Revision history for this message
Jens Grassel (jan0sch) wrote :

According to the documentation I installed the restricted extras package:

sudo apt-get install libdvdread4
sudo /usr/share/doc/libdvdread4/install-css.sh

There were no errors during the installation.

Revision history for this message
Jens Grassel (jan0sch) wrote :

I just reinstalled and added css support the medibuntu way. Same error. :-(

Any chance that this gets fixed (in Lucid) or do I have to switch back to Jaunty?

Revision history for this message
Roland Giesler (lifeboy) wrote :

I can confirm this bug.

I have a brand new Sahara Montevina notebook that behaves in exactly the same way. Can't play commercial DVDs.

Jan 17 10:32:23 ASLAN1 kernel: [ 3267.297486] end_request: I/O error, dev sr0, sector 16189072
Jan 17 10:32:23 ASLAN1 kernel: [ 3267.310382] sr 1:0:0:0: [sr0] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
Jan 17 10:32:23 ASLAN1 kernel: [ 3267.310397] sr 1:0:0:0: [sr0] Sense Key : Illegal Request [current]
Jan 17 10:32:23 ASLAN1 kernel: [ 3267.310407] sr 1:0:0:0: [sr0] Add. Sense: Media region code is mismatched to logical unit region

Restricted extras and libdvdcss2 et al are installed.

Revision history for this message
Roland Giesler (lifeboy) wrote :

I just installed dvdregion and set it to region 2 (which is where I am and what my DVD's are), but although my regions matches the DVD now, the error stays the same.

So this is definitely a bug and not a region that is incorrect.

Revision history for this message
Gergely Máté (sportember) wrote :

I had similar problems, and similar lines in syslog. Totem greyed out, VLC refused to play the disk.

After browsing around a bit in Launchpad Bugs, I intuitively removed the Brasero disk burner application. I don't understand the connection between Brasero and DVD playback, but now the DVDs play!

(The playback is still quirky, but that seems to be a different bug.)

Please check this in your case - if someone would confirm me, this bug could be assigned to the Brasero team.

Revision history for this message
Jens Grassel (jan0sch) wrote :

I had the problem with and without brasero. The first time I removed it because I compiled cdrtools myself. The second time it was a standard installation therefore brasero was installed.

However I can't test on this bug any further because I switched to FreeBSD for my laptop and my desktop pc is running 9.04 that isn't affected by this bug.

Revision history for this message
Surak (smkozasa) wrote :

Same problem on my new Powernote W870 (Clevo) with Blue-ray reader and DVD writer running Karmic 64 bit version. Tried to install libdvdcss2 from medibuntu, had both ubuntu-restricted-extras and kubuntu-restricted-extras, installed libdvdread4 and tried the shell script /usr/share/doc/libdvdread4/install-css.sh that downloads libdvdcss2 and installs it, but the problem persisted. Interesting to note that on my older notebook that runs the 32 bit version of Karmic, running the same script mentioned before worked just fine!

Looking dmesg, there are references to problems with DVD region (very similar to those people posted above), so I (partly) solved my problem using the regionset program and ajusted region to 4 that corresponds to most of my DVD disks. But now I can only change my drive region 4 times (5 times total allowed by firmware). Well, did this just to get the confirmation that libdvdcss2 is not doing its job!

Apparently libdvdcss2 is buggy on karmic 64 bits !!!

Revision history for this message
Surak (smkozasa) wrote :

Just realized that the difference between my two notebooks, the newer with the bug and the older without may not be related to the newer running 64 bits karmic and the older the 32 bits version, but because the older notebook was made in Brazil (region 4) and its drive is set to region 4 !

That means people will only notice this bug when trying to play a DVD disk from a different region as their drive is set to!

I must reinforce: Only change the region of your drive if you think it's worth it! You can only change it 5 times, no regrets after that!

description: updated
Revision history for this message
Alec J Weatherwood (weatherwood) wrote :
Download full text (3.9 KiB)

I have the same problem. Can't play any dvd's on my Asus UL50A with Ubuntu 9.10. This is a very bad thing for me, without a workaround I'll soon have to switch to another OS. And I don't want to, since I've been using Ubuntu for about 3 years on all my desktops and notebooks.

I've tried to uninstall Brasero, but that didn't have any effect.

Here's some logging info (and I'm more than willing to give any other information that can help fix this problem asap.

Feb 28 09:48:27 ghana kernel: [ 2.077648] sr0: scsi3-mmc drive: 24x/24x writer dvd-ram cd/rw xa/form2 cdda tray
Feb 28 09:48:27 ghana kernel: [ 2.077731] sr 1:0:0:0: Attached scsi CD-ROM sr0
Feb 28 19:45:18 ghana kernel: [ 2.065448] sr0: scsi3-mmc drive: 24x/24x writer dvd-ram cd/rw xa/form2 cdda tray
Feb 28 19:45:18 ghana kernel: [ 2.065531] sr 1:0:0:0: Attached scsi CD-ROM sr0
Feb 28 19:47:23 ghana kernel: [ 140.423304] sr 1:0:0:0: [sr0] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
Feb 28 19:47:23 ghana kernel: [ 140.423311] sr 1:0:0:0: [sr0] Sense Key : Illegal Request [current]
Feb 28 19:47:23 ghana kernel: [ 140.423317] sr 1:0:0:0: [sr0] Add. Sense: Media region code is mismatched to logical unit region
Feb 28 19:47:23 ghana kernel: [ 140.423326] end_request: I/O error, dev sr0, sector 1728
Feb 28 19:47:23 ghana kernel: [ 140.423331] Buffer I/O error on device sr0, logical block 432
Feb 28 19:47:23 ghana kernel: [ 140.423336] Buffer I/O error on device sr0, logical block 433
Feb 28 19:47:23 ghana kernel: [ 140.423342] Buffer I/O error on device sr0, logical block 434
Feb 28 19:47:23 ghana kernel: [ 140.423345] Buffer I/O error on device sr0, logical block 435
Feb 28 19:47:23 ghana kernel: [ 140.423349] Buffer I/O error on device sr0, logical block 436
Feb 28 19:47:23 ghana kernel: [ 140.423352] Buffer I/O error on device sr0, logical block 437
Feb 28 19:47:23 ghana kernel: [ 140.423356] Buffer I/O error on device sr0, logical block 438
Feb 28 19:47:23 ghana kernel: [ 140.423359] Buffer I/O error on device sr0, logical block 439
Feb 28 19:47:23 ghana kernel: [ 140.433283] sr 1:0:0:0: [sr0] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
Feb 28 19:47:23 ghana kernel: [ 140.433288] sr 1:0:0:0: [sr0] Sense Key : Illegal Request [current]
Feb 28 19:47:23 ghana kernel: [ 140.433294] sr 1:0:0:0: [sr0] Add. Sense: Media region code is mismatched to logical unit region
Feb 28 19:47:23 ghana kernel: [ 140.433302] end_request: I/O error, dev sr0, sector 1728
Feb 28 19:47:23 ghana kernel: [ 140.433306] Buffer I/O error on device sr0, logical block 432
Feb 28 19:47:23 ghana kernel: [ 140.433309] Buffer I/O error on device sr0, logical block 433
Feb 28 19:47:23 ghana kernel: [ 140.447826] sr 1:0:0:0: [sr0] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
Feb 28 19:47:23 ghana kernel: [ 140.447835] sr 1:0:0:0: [sr0] Sense Key : Illegal Request [current]
Feb 28 19:47:23 ghana kernel: [ 140.447843] sr 1:0:0:0: [sr0] Add. Sense: Media region code is mismatched to logical unit region
Feb 28 19:47:23 ghana kernel: [ 140.447855] end_request: I/O error, dev sr0, sector 1728
Feb 28 19:47:23 ghana kernel: [ 140.493322] sr 1:0:0:0: [sr0] Result: hostbyte=DID_OK dri...

Read more...

Revision history for this message
Surak (smkozasa) wrote :

Just got the following from wikipedia:

"libdvdcss uses a generated list of possible player keys. If none of them works (for instance, when the DVD drive enforces region coding) a brute force algorithm is tried so the region code of a DVD is ignored."

This means that libdvdcss2 should ignore region code IF your player key is in the list OR brute force is successful.

This could mean that libdvdcss2 is failing to brute force region code and there's nothing to do about it. I mean, couldn't find information if libdvdcss2 shoud work ALWAYS... If not, this wouldn't be exactly a bug, but a limitation.

BUT, there are people above reporting that they could use their drives with previous versions of Ubuntu.

Why am I insisting that the problem may be about region code? Note the following quotes from the reports above:

"Jan 2 22:00:19 tjalfi kernel: [ 981.470273] sr 3:0:0:0: [sr0] Add. Sense: Media region code is mismatched to logical unit region" - from the original post.

"Jan 17 10:32:23 ASLAN1 kernel: [ 3267.310407] sr 1:0:0:0: [sr0] Add. Sense: Media region code is mismatched to logical unit region" - from Roland Giesler

"Feb 28 19:47:23 ghana kernel: [ 140.423317] sr 1:0:0:0: [sr0] Add. Sense: Media region code is mismatched to logical unit region" - form Alec J Weatherwood

and this is always followed by supposed I/O errors that could be the drive refusing to give more data from a non-matching region disc.

A friend of mine has told me that it is possible to reflash the drive to make it region-free, but there is always a small risk with reflashing... The big questions remain:

1) Should libdvdcss2 work ALWAYS ignoring region?
2) When people above say that they could watch DVDs in their drives with previous releases, were they trying to watch the same discs with the same region codes? Or did they try a different disk that could be set to a different region code than their drives?

I hope this helps solving this bug.

Revision history for this message
Alec J Weatherwood (weatherwood) wrote :

I've run Regionset to change the region setting of my DVD drive. No the above mentioned errors have disappeared.

I still can't watch DVD's, because the blayback is jerky. But the problem mentioned on this page is solved by Regionset.

Revision history for this message
Surak (smkozasa) wrote :

Well, this almost proves libdvdcss is buggy. According to wikipedia, libdvdcss tries a list of keys and if not successful, tries a brute force algorithm wich, if successful, should ignore region codes. Aparently, the bug is only percievable if one tries to use discs with a different region code than the DVD drive being used. I don't know about you, but this could mean using another operating system, though may not seem so serious for many. Luckily, I was able to go over it using regionset. Not perfect because not all my discs are from the same region code... At least it is good enough for me to continue with (K)ubuntu. Please, fix this bug aap, Thanks in advance.

Revision history for this message
Sandor Rabe (schermvlieger) wrote :

I am experiencing similar trouble as the OOP (Buffer I/O error on device) while trying to play DVDs on 9.10 and on 9.04 (different machines). The region codes of the drive and the disk are identical. On the same hardware, the disk can be played in Vista (using VLC)

The OOP's syslog mentions region code issues; my syslog does not mention that at all. I do have libdvdread4 and libdl installed on both machines.

---syslog---
Mar 25 09:04:49 nyuszike kernel: [ 2711.244586] sr 1:0:0:0: [sr0] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
Mar 25 09:04:49 nyuszike kernel: [ 2711.244593] sr 1:0:0:0: [sr0] Sense Key : Illegal Request [current]
Mar 25 09:04:49 nyuszike kernel: [ 2711.244599] sr 1:0:0:0: [sr0] Add. Sense: Read of scrambled sector without authentication
Mar 25 09:04:49 nyuszike kernel: [ 2711.244606] end_request: I/O error, dev sr0, sector 12090752
--/syslog---

Revision history for this message
mjlcapdagde (mjl2009) wrote :
Download full text (6.0 KiB)

Same issue: DVD spools up to ungodly speed and makes alarming rattling noises, followed by VLC refusing to play the disc. So does Ubuntu Movie Player.
Ubuntu Version: Lucid Lynx 10.04
Hardware: Dell Latitude E6400 ATG laptop
DVD drive: Ubuntu cannot identify type - returns 'unknown type' under disc properties.
I can confirm this is not a region issue. My laptop is dual-booting and under Windows 7 this DVD player plays Region 4 (my home country's region) discs without any problems. Except one: VLC for Windows makes the same ungodly speed/rattling noise/refusal to play, very unusual behaviour for VLC under Windows. I must play DVDs through Windows Media Player instead. So I don't discount this could be a hardware issue. In my case I get the strong feeling that the system's failure to identify disc drive type is behind these errors.

Log:
Sep 30 07:43:40 bagend kernel: [ 5688.963385] UDF-fs: Partition marked readonly; forcing readonly mount
Sep 30 07:43:40 bagend kernel: [ 5688.997502] UDF-fs INFO UDF: Mounting volume 'ROMULUS MY FATHER DISC1', timestamp 2007/10/09 14:42 (1258)
Sep 30 07:43:41 bagend kernel: [ 5690.803287] sr 1:0:0:0: [sr0] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
Sep 30 07:43:41 bagend kernel: [ 5690.803292] sr 1:0:0:0: [sr0] Sense Key : Illegal Request [current]
Sep 30 07:43:41 bagend kernel: [ 5690.803296] sr 1:0:0:0: [sr0] Add. Sense: Media region code is mismatched to logical unit region
Sep 30 07:43:41 bagend kernel: [ 5690.803302] sr 1:0:0:0: [sr0] CDB: Read(10): 28 00 00 00 01 9e 00 00 10 00
Sep 30 07:43:41 bagend kernel: [ 5690.803310] end_request: I/O error, dev sr0, sector 1656
Sep 30 07:43:41 bagend kernel: [ 5690.803314] __ratelimit: 24 callbacks suppressed
Sep 30 07:43:41 bagend kernel: [ 5690.803317] Buffer I/O error on device sr0, logical block 414
Sep 30 07:43:41 bagend kernel: [ 5690.803321] Buffer I/O error on device sr0, logical block 415
Sep 30 07:43:41 bagend kernel: [ 5690.803324] Buffer I/O error on device sr0, logical block 416
Sep 30 07:43:41 bagend kernel: [ 5690.803326] Buffer I/O error on device sr0, logical block 417
Sep 30 07:43:41 bagend kernel: [ 5690.803331] Buffer I/O error on device sr0, logical block 418
Sep 30 07:43:41 bagend kernel: [ 5690.803333] Buffer I/O error on device sr0, logical block 419
Sep 30 07:43:41 bagend kernel: [ 5690.803335] Buffer I/O error on device sr0, logical block 420
Sep 30 07:43:41 bagend kernel: [ 5690.803337] Buffer I/O error on device sr0, logical block 421
Sep 30 07:43:41 bagend kernel: [ 5690.803340] Buffer I/O error on device sr0, logical block 422
Sep 30 07:43:41 bagend kernel: [ 5690.803342] Buffer I/O error on device sr0, logical block 423
Sep 30 07:43:42 bagend kernel: [ 5690.886043] sr 1:0:0:0: [sr0] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
Sep 30 07:43:42 bagend kernel: [ 5690.886051] sr 1:0:0:0: [sr0] Sense Key : Illegal Request [current]
Sep 30 07:43:42 bagend kernel: [ 5690.886057] sr 1:0:0:0: [sr0] Add. Sense: Media region code is mismatched to logical unit region
Sep 30 07:43:42 bagend kernel: [ 5690.886065] sr 1:0:0:0: [sr0] CDB: Read(10): 28 00 00 00 8a 42 00 00 08 00
Sep 30 07:43:42 bagend kernel: [ 5690.886078] end_request: I/O e...

Read more...

Revision history for this message
mjlcapdagde (mjl2009) wrote :

I solved the problem in #15.

I followed the steps in the following thread:

http://ubuntuforums.org/archive/index.php/t-1440147.html

All the relevant steps to getting DVDs to play in Ubuntu 10.04 seem to be listed in one place there.

Unfortunately for me it was a long process of trial and error rather than access to that thread!

What seems clear is:

-Ubuntu did not think the DVD drive's region was set to [4]. It reported region [2]. Windows 7 had successfully played a region [4] disc on my laptop but the drive did not seem to 'remember' the region setting under Ubuntu.
-Ubuntu was able to recognise the drive type (Matshita UJ892) using System -> Administration -> Disk Utility.
-I got garbled (presumably incorrectly decrypted) video from Totem and VLC Media Player until I deleted the folder shown in this command:

sudo rm -r ~/.dvdcss

and restarted Ubuntu.

This last step is crucial, allowing DVD decryption capabilities to be rebuilt.

Overall I feel this was an unnecessarily complex procedure to get usable DVD video on Ubuntu, but it is working flawlessly now.

Revision history for this message
Will Bickerstaff (willbickerstaff) wrote :

Surak if you're saying you think think this is a libdvdcss bug. From what I can see here, I would probably agree, as every log posted includes the 'Media region code is mismatched to logical unit region' line, so libdvdcss clearly isn't doing its job correctly. If so perhaps we should mark it as affecting that package to get the attention of the maintainers.

Revision history for this message
Surak (smkozasa) wrote : Re: [Bug 502426] Re: DVD playback broken in Karmic

I suppose it is the logical conclusion, since changing the DVD drive
region code allowed me to watch most DVDs I own (region 4). As far as I
know, libdvdcss SHOULD be able to do a workaround through this region
restrictions, but since it wasn't working with original region code
(region 1) and when I changed it to the same region as my discs (region
4) it started to work, we can get to the conclusion that libdvdcss is
doing its job partially, only, being able to decode protected DVDs, but
ONLY if the drive's region code is the same as the disc's.

And I can see why most people didn't notice this bug before: most people
DO have DVD drives with the same region code as the discs they own.

Surak

---

Em 09-10-2010 16:49, Will escreveu:
> Surak if you're saying you think think this is a libdvdcss bug. From
> what I can see here, I would probably agree, as every log posted
> includes the 'Media region code is mismatched to logical unit region'
> line, so libdvdcss clearly isn't doing its job correctly. If so perhaps
> we should mark it as affecting that package to get the attention of the
> maintainers.
>
>

Revision history for this message
Will Bickerstaff (willbickerstaff) wrote : Re: DVD playback broken in Karmic

Can someone who can reproduce, post this upstream at https://trac.videolan.org/vlc/ then we can link to that and track its progress.

Revision history for this message
Rémi Denis-Courmont (rdenis) wrote :

The VLC trac is for (surprise!) VLC. Please don't use it for dvdcss, thanks. Your bug would be immediately closed as notvlc anyhow.

summary: - DVD playback broken in Karmic
+ DVD playback broken
Changed in ubuntu:
status: New → Confirmed
summary: - DVD playback broken
+ DVD playback broken ("Media region code is mismatched to logical unit
+ region")
affects: ubuntu → libdvdread (Ubuntu)
Revision history for this message
Marcello Nuccio (marcenuc) wrote :

I've tried the fix suggested by mjlcapdagde at #16

rm -r ~/.dvdcss

and it worked on Ubuntu-13.04 (updated from 12.04). It is the first time I see this bug and I'm using ubuntu since 06.06.

Revision history for this message
JB VideoLAN (jb-videolan) wrote :

So, this is a dvdcss bug more than a dvdread one.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.