Playing DVDs in Ubuntu 7.10 (Gutsy Gibbon)

A blogger by the name of John Bradbury posted three excellent videos (1, 2, 3) showing his first experiences with Ubuntu. It was really wonderful to watch; lots of ‘WOW’s and pleasant surprises :) The only real problem he had was watching a DVD. When you pop it into the drive in Ubuntu, Totem (the default media player) gives a rather unhelpful error message:

An error occurred
Could not read from resource.

This is unfortunate enough. What’s worse though is that even if you have the decss library (which Ubuntu does not carry in its official repositories due to legal concerns in places like the US because of the hated DMCA…) that would normally allow Ubuntu to play DVDs through Totem (the default video player in Ubuntu), it does not seem to work properly in Gutsy (grr! bad bug!)

OK, so how do we fix this?

First run System -> Administration -> Synaptic Package Manager (supply your password when asked)

[Update: under Settings -> Repositories -> Ubuntu Software, if “Community-maintained Open Source software (universe)” isn’t checked, be sure to do so]

and (if you haven’t already) add the free section of the Medibuntu repository by going Settings -> Repositories -> Third-Party Software (tab) and click the “Add” button and add this source:

deb http://packages.medibuntu.org/ gutsy free

Update: Whoops! Forgot to mention that you have to add their key or else you’ll get a security warning when you install from their site. You can still proceed without adding their key, but its annoying to get that message and besides, its a good practice to get into :) So! Install the package:

gui-apt-key

then close Synaptic and in the Gnome panel menu you’ll find an entry under Applications -> System Tools -> APT Key Manager so run that and add the Key ID:

0C5A2783

which will show up as “Medibuntu Packaging Team”. You can close the APT Key Manger now. Now restart Synaptic, press the reload button and install these two packages:

libdvdcss2
vlc

It will automatically install all of the required dependencies as well. When its done you can close Synaptic and then go System -> Preferences -> Removable Drives and Media -> Multimedia (tab) and replace the “Video DVD Discs” command (totem %m) with:

vlc --vout-filter deinterlace --deinterlace-mode blend --volume 512 %m

[Update 12/17: added “–volume 512” so that it starts playing with an volume of “100” in VLC… this is rather counterintuitive and not exactly what it says in the manual, but it works. Update Jan. 2: Please note the double dashes in the above command; WordPress was converting them to a single long dash character that doesn’t work if you just copy and paste]

Now, whenever you pop in a DVD it should start playing :) Should you desire a desktop shortcut to play DVDs (e.g. if you want to disable disks playing automatically when inserted), right-click on the Desktop, click “Create Launcher…” give it a Name like “DVD Player” and a Command of:

vlc --vout-filter deinterlace --deinterlace-mode blend --volume 512 dvd:///cdrom

Enjoy your movies! ^_^

Advertisements

51 Responses to “Playing DVDs in Ubuntu 7.10 (Gutsy Gibbon)”

  1. lhstech Says:

    Nice post.

    I like VLC as well but I saw another post where you can do the same thing by just installing Movie Player (Totem xine backend) from Add/Remove. This will also uninstall the default Movie Player that’s based on gstreamer.

    If you do this and add the libdvdcss2 package from synaptic then you can play dvd’s without having to do any changes. And Movie Player is already the default player so it will autoplay your dvd’s. This is just a simpler way of achieving the same thing you are writing about. I have done this on all of my installs (which covers multiple desktops and laptops now) and it “just works.”

  2. lhstech Says:

    Correction to above post…

    I forgot to mention that in addition to libdvdcss2, you also need to install libxine1-ffmepg from synaptic packet manager. Just install…no further configuration needed after making the three packet installations that I mentioned.

  3. Limulus Says:

    My issue with totem-xine is that it is mutually exclusive with totem-gstreamer; unless I am mistaken, should I want the gstreamer codecs to be used I need totem-gstreamer (Ubuntu default). I can always install Xine (gxine) separately.

    In fact, I generally install as many media players as I can find; its not so much an issue these days, but in the past, Totem wasn’t very good and there are still cases where the others do a better job with a specific file type. Right now I have on my system:

    totem-gstreamer
    gxine
    vlc (+ libdvdcss2 of course ;)
    mplayer (+ w32codecs)
    realplay (from feisty parter repo; its basically helix-player + proprietary codecs)

  4. lhstech Says:

    I agree with you and install mulitple media players and codecs (including all of the gstreamer codecs). So far though I have not had any problems with the totem-xine installation and I watch multiple videos and movies using the totem-xine method.

    The only problem I have ever had was trying to play movies was without the totem-xine as you wrote about above. Once I changed to totem-xine everything worked. I do not know if you have to have the totem-gstreamer installed to access the codecs. Like I said…everything seems to work without totem-gstreamer installed.

    Now I haven’t gone into in-depth testing of the different media players. I usually have to set up computers using the simplest method (that works, of course!) possible for other people. And the totem-xine is the simplest I have found so far and I still haven’t found anything yet that I can not play.

    I have also used vlc (I am a big fan of vlc) for a long time now and put it side by side with totem-xine and really did not seem any noticeable difference between the two playing movies. Maybe others get different results but I have done this on multiple desktops and laptops from a variety of manufacturers and everything works with the totem-xine install.

  5. Ubuntu Care » Blog Archive » Playing DVDs in Ubuntu Gutsy Says:

    […] OK, so how do we fix this? Leave a Reply […]

  6. Shan-Hou Says:

    This is incredibly clear. Thank you so much for the help – you made it easy for a ‘newb’ (read: technologically retarded) to get his DVDs to work. Cheers mate!

  7. Limulus Says:

    You’re welcome! I am really glad if this post helped even just one person :)

  8. Playing DVDs in Ubuntu using Totem « Me and U(buntu) Says:

    […] – everything worked fine from there. Obviously I didn’t figure this out all on my own (this blog post and comments were helpful), and there are several other alternatives, including using a different video player, […]

  9. bryan clardy Says:

    hopefully this will make acidrip work again. I had it working on my 5.10 version, finally upgraded, and poof. nada.

    The fix has made everything else perfect. I really appreciate it.

    p.s. this appears to have fixed acidrip. you da man.

  10. Limulus Says:

    Cool, glad to hear that it fixed your system :) I’m going to guess that it was the libdvdcss2 package that did the trick; its really important for various programs that get info from video DVDs.

  11. Die Fünf von der EDV » DVDs unter Ubuntu Says:

    […] gestossen, wo eine recht gute Anleitung für Das Problem drin steht. Ich bin mal so frei, zu verlinken. Funktioniert wunderbar […]

  12. Play/Rip DVDs in Ubuntu « twodayslate Says:

    […] official way is much easier and makes much more sense but Limulus’ idea is also […]

  13. Nate Jones Says:

    I tried this solution and it got me past the error message mentioned at the top. Unfortunately, I still can’t play DVD’s in either Totem or VLC. The program loads briefly when I put in the DVD and then seems to disappear. The window goes away (not minimized) and nothing happens.

    What’s going on?

  14. Limulus Says:

    When a window disappears like that, the program has silently crashed. Please run the vlc command at the end of my post from Terminal (under Accessories) to see any warning messages and paste them in here… Based on any errors you get you might try searching on http://ubuntuforums.org/

  15. Jonny Says:

    I followed the steps exactly. It doesnt work for me, Totem or VLC. When I run the command line VLC command, I get the following:
    ————————–
    VLC media player 0.8.6c Janus
    libdvdnav: Using dvdnav version 0.1.10 from http://dvd.sf.net
    libdvdread: Encrypted DVD support unavailable.
    libdvdread: Attempting to use device /dev/hdc mounted on /media/cdrom0 for CSS authentication
    libdvdnav: Can’t read name block. Probably not a DVD-ROM device.
    libdvdnav: Unable to find map file ‘/home/mediacenter/.dvdnav/.map’
    libdvdnav: DVD disk reports itself with Region mask 0x00fe0000. Regions: 1
    [00000281] main playlist: nothing to play
    [00000281] main playlist: stopping playback

    ———————-
    obviously I didnt get DVD encryption installed.

  16. Limulus Says:

    Johnny: where it says “libdvdread: Encrypted DVD support unavailable.” it should read “libdvdread: Using libdvdcss version 1.2.9 for DVD access”

    IOW, the problem is that you either don’t have the libdvdcss2 package installed, or something went wrong in its installation. Uninstall it and then try installing it again. Out of curiosity, do you have a 32-bit or 64-bit version of Ubuntu running?

  17. Garrett Says:

    This is wonderful. I am first time Ubuntu user and this saved the day.

  18. Tristan Says:

    “I forgot to mention that in addition to libdvdcss2, you also need to install libxine1-ffmepg from synaptic packet manager. Just install…no further configuration needed after making the three packet installations that I mentioned.”

    Hi, so this seems to be really help full because it sounds like I’m having the same problem as everyone else, but for some really weird reason, when I try to install, or rather mark that I even want to install them, libxine1-ffmepg I get.

    error title
    “Could not mark all packages for installation or upgrade”
    in the error box
    “libxine1-ffmpeg:
    Depends: libxine1 (=1.1.7) but it is not installable”

    anyone ever seen this?

    So i don’t really know anything and found the libxine1 package and list of dependencies at http://packages.ubuntu.com/feisty/libs/libxine1 and it gave me the same error so I just tried making sure I had all of its depends installed, and I have all of them except what appears to be its self… which it really really confusing me. Any one know what is going on?

    thanks
    tristan

  19. Limulus Says:

    tristan: Are you using Gutsy? (7.10)

    I note on http://packages.ubuntu.com/libxine1 that 1.1.7-1ubuntu1 is the version from Gutsy’s default repositories while a newer version, 1.1.8-2ubuntu2~gutsy1 is available from gutsy-backports.

    To get lhstech’s method working, go System -> Administration -> Synaptic Package Manager and then in Synaptic go Settings -> Repositories -> Updates (tab) and put a check next to gutsy-backports. Press close, ok, and then Reload. You should be able to install libxine1-ffmpeg then.

  20. David Says:

    you don’t explain how to do this

    Update: Whoops! Forgot to mention that you have to add their key or else you’ll get a security warning when you install from their site. You can still proceed without adding their key, but its annoying to get that message and besides, its a good practice to get into :) So! Install the package:

    gui-apt-key

  21. Limulus Says:

    David: You’re having trouble with the installing gui-apt-key step? Run Synaptic and find the gui-apt-key package in the list. Right-click it, mark for installation, press apply, press OK. Just like installing any other package. If you don’t see it in the list of packages its probably because you don’t have the Universe repository enabled (in Synaptic, go Settings -> Repositories and then put a check next to “Community-maintained Open Source software (universe)”).

  22. Greg Says:

    Thank you so much. Solved two hours of banging my head trying to fix totem.
    Much appreciated

  23. ithink2020 Says:

    Thank you, thank you, thank you!!! Worked perfectly!!!

  24. Dave Says:

    I’m running Ubuntu 7.10 64 bit. Everything installed OK But when I launch the “DVD Player” launcher it starts then crashes.
    Any ideas would be great and much appreciated.

  25. Limulus Says:

    Dave: Run Terminal (under Accessories) and run the command from there. Copy the command line output and paste it here. Perhaps also see this thread: http://ubuntuforums.org/showthread.php?t=609772

  26. D Munkey Says:

    Great post. The instructions were perfect!
    Thanx a bunch!

  27. Jeff Says:

    I made it through installing gui-apt-key, but when I enter the above key ID into the Apt Key Manger and click Add, nothing happens.

  28. Limulus Says:

    Jeff: The way it works is that you put the number in, push the button and it tries to get the information from a website. It could be that that GPG server was down when you tried to get the info. Try again and see if you can get it later. If not, you can proceed, but with a warning from Synaptic.

  29. Jeff Says:

    Thanks, will do. It seemed strange that I was getting no message of any kind and the add button was immediately relit.

    I did try to continue without it, but ran into a lot of dependences that weren’t being automatically included, and that appeared to have something to do with the failed authentication.

    Nope. Same lack of effect this morning.

  30. Jeff Says:

    Ha! It worked this evening. Thanks.

  31. Jadd Says:

    You need to install libxine1-ffmpeg too.

  32. Limulus Says:

    Jadd: AFAIK, that’s not necessary for the VLC method I described. The only program packages that explicitly depend on libxine1-ffmpeg, according to Synaptic, are: amarok, gxine, konqueror and miro.

  33. Keith Says:

    Thank goodness the Linux community shares information like this, otherwise newbies like me wouldn’t get anywhere!! Cheers for the help

  34. ChaserBren Says:

    Thanks for this info, it worked great!
    One note, for total newbies to Ubuntu like myself, I didn’t know I had to check “Community-maintained Open Source software (universe)” untiil i read through the comments. This also kept the VLC package from showing up so it might be something worth adding to the instructions.
    Otherwise, Cheers dude!

  35. Limulus Says:

    ChaserBren: thanks; I updated the post. Glad to know it worked!

  36. Koors Says:

    Thanks alot,
    These and a few other problems had me very worried, although help from a friend, KMFDM, got me through flashplayer problems and now I’m watching dvd’s!!!

  37. Limulus Says:

    BTW, I’m testing the version of Ubuntu set to be released in April, 8.04 (Hardy Heron) and DVDs play just fine in Totem again when libdvdcss2 is installed :)

  38. Charlotte Says:

    Hi Limulus,
    Thanks for uploading these instructions. I started working through them and everything was fine until I tried to add VLC. I got the error message:

    vlc:
    Depends: vlc-nox but it is not going to be installed
    Depends: libsdl-image1.2 (>=1.2.5) but it is not installable
    Depends: ttf-dejavu but it is not installable

    So searched ttf-dejavu but could only find ttf-dejavu-core or -vera
    then I searched for libsdl-image1.2 and it didn’t find anything (libsdl-image either)
    finally searched for vlc-nox, found it and then got the following error message:

    vlc-nox:
    Depends: libavcodec1d but it is not going to be installed
    Depends: libavformat1d but it is not going to be installed
    Depends: libdc1394-13 but it is not installable
    Depends: libgsm1 (>=1.0.10) but it is not installable
    Depends: libid3tag0 (>=0.15.1b) but it is not installable
    Depends: libmad0 (>=0.15.1b) but it is not installable
    Depends: libmodplug0c2 (>=1:0.7-4.1) but it is not installable
    Depends: libmpcdec3 but it is not installable

    I noticed you had suggested in a previous post to add gutsy backports, which I’ve done, but no luck.

    Any help would be appreciated!

    I’m using Ubuntu 7.10

    Cheers,
    Charlotte

  39. Limulus Says:

    Charlotte: those are interesting errors; its almost like you don’t have access to the main repository. Check to make sure you have main/restricted/universe/multiverse enabled and press reload and see if it works then.

  40. Charlotte Says:

    Hi Limulus, thanks for help vlc is now installed on my machine!

  41. new B Says:

    THANK YOU SO MUCH!!! these instructions made it so easy to get my dvds running! its people like you that make ubuntu easy to use for all of us!
    Thanks

  42. setesh Says:

    hi
    i keep getting scrambled/encryption error in gxine when i try to play the dvd-videofiles. it plays the menus perfectly.
    when i play it in vlc, it lacks a lot with the dvd videos, and somewhat plays the menu perfect

  43. PhatKat Says:

    Hi there! I had become tired of windows and experimented with buntu 8.04 beta last month. I liked it so much that i decided to DIY a buntu box and use buntu exclusively! Hardware costed really cheap and thanks to this thread i finally got decent DVD on my integrated graphics so thanks a million man!

    DIY buntu box specs
    AMD x2 4000+
    Biostar K8M800 AM2
    1GB DDR2 667 Kingston
    80GB Seagate 7200.10 HDD (for now)

  44. Ryan Says:

    Update for Hardy.
    System -> Preferences -> Removable Drives and Media -> Multimedia does not exist.

    Go to Properties->Open with->Add and System -> Preferences -> Preferred Applications -> Multimedia

  45. JC Says:

    Thanks much. I am brand new to Linux (I got a used Notebook) and couldnt for the life of me figure out how to get DVD’s to play decently. With the VLC player everything works now. By the way, I tried MPlayer and it didnt work

    Thanks again

  46. marinella Says:

    Thank you very much!
    It works perfectly!

  47. Angel Mass Says:

    I got this error when I was trying to add the key

    “The key with ID 0C5A2783 could not be imported.”

    • Limulus Says:

      Angel Mass: Were you connected to the internet when you tried? (it needs to be to get the key). Try again? Also be sure you’re running gak with root permissions (try “sudo gak” without quotes from the commandline)

  48. JDiGiacomo Says:

    This looks great!

    Unfortunately, I get an error when I try to open the APT Key Manager: Failed to execute child process “/usr/bin/su-to-root” (No such file or directory)

    Tried removing and reading and restarting PC and still the same error.

    Any suggestions?

  49. Ian Says:

    Limulus, many thanks – looked everywhere for a solution to VLC not playing DVDs – most sites give you half the story or assume you have total, er, command of the command line… Much obliged!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: