Lenovo T530, Kubuntu 12.10, NVIDIA Optimus, External Monitors

April 16, 2013
Just a couple of days after I wrote this post NVIDIA released a new version of its driver that is optimized for the Optimus technology. See http://steamforlinux.com/?q=en/node/210 for further information.

Use case

I bought a new Lenovo Thinkpad T530 laptop incl. a docking station recently. I was facing several problems regarding the docking station, the grafix card and external monitors. After spending couple of hours to get this all up and running I decided to share my experiences.

Maybe it will help someone, or maybe someone may help me by providing alternatives and/or better solutions.

Specs

Hardware

i7-3630QM, NVIDIA NVS 5400M with Optimus, SATA3 256GB CRUCIAL m4 SSD, 16 GB Kingston Memory KTL-TP3C DDR3 1600 MHz, Mini Dock Plus, Series 3 433810U, Two external Philips 23″ monitors connected to the docking station via DVI

Software

3.5.0-17-generic #28-Ubuntu SMP Tue Oct 9 19:31:23 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux, Qt: 4.8.3, KDE Development Platform: 4.9.5, kde4-config: 1.0

After removing Windows 8 by formatting the SSD and installing Kubuntu 12.10 I was struggling around with som weired problems regarding the NVIDIA Optimus card.

What happened so far (messed up)

I tried almost two days to get my two external monitors work together with the laptop display. But, unfortunately, I failed. Well, I even did mess up my system that much that I needed to re-install my system. This mostly is based on the proprietary NVIDIA driver – which broke during both the installation and the de-installation scripts. And I could not figure it out to remove all the NVIDIA stuff manually.

My sincerely advice: DO NOT USE the official NVIDIA drivers!
Even though NVIDIA might give you the impression that the specific grafic card will work fine with your specific system. But it won’t.

For those who might proove me wrong, please try it on your own (and please leave a comment if you succeed):
http://www.nvidia.com/object/linux-display-amd64-310.44-driver.html

BIOS settings

Luckily, the T530 provides an BIOS-option to chose a particular grafic card.

Integrated – Intel’s integrated grafic, NO NVIDIA
Discret - The NVIDIA card
Optimus – Both

In the latter case the OS decides when to switch between the integrated one and the NVIDIA card. Guess this should be fine running on Windows 7 or 8. But the Linux-support does just barely exist.

The idea behind the Optimus technology is to prevent the laptop from draining battery: The NVIDIA card gets activated only if it’s necessary. Great idea though.

Since I use my laptop always on AC (and have a 9-cell battery just for case) I do not care very much about batterie’s lifetime. This is why I’m satisfied by chosing the discrete option.

Driver installation

So, the simplest yet most effective and promising way is to install nvidia-current and nvidia-settings.
Contrary to various recommendations to enable the repository ppa:ubuntu-x-swat/x-updates
I got no luck with that. So I did not add or change any repositories.

sudo apt-get install nvidia-current nvidia-settings

After the installation you have to let NVIDIA configure the xorg.conf for you.

sudo nvidia-xconfig

Now you need to reboot your system.

Setup

Two external monitors

No you can run

nvidia-settings

to configure your monitors.

I configured my two external monitors as TwinView. The first (DFP-2) positioned absolutely, the second one (DFP-3) relatively to the first one.
The third display (laptop, DFP-0) was disabled by default – After playing around a couple of times I accepted that this was the only solution that will work.

When you are done just save the settings to the xorg.conf (create backup before!) and reboot your system (or just X).

Laptop display only

Well, the default scenario just works fine now. But what if you want to undock your laptop or use it without the external monitors.
Hm, I don’t want to disappoint you, but the former task gave me huge problems (=black screens), and I still can’t switch screens while the system is running. If you have any clue or even a solution please be so kind to leave a comment.

As you might have seen already the nvidia-settings take use of the metamodes options in the xorg.conf. This is pretty fine, since we can define multiple metamodes options which get handled in sort and as fallbacks.

So I configured it that way that the X-server will search for my two external monitors on startup, if they don’t exist the laptop’s display gets used.
These are my settings:

Option         "metamodes" "DFP-2: 1920x1080 +0+0, DFP-3: 1920x1080 +1920+0"
Option         "metamodes" "LVDS-0: 1920x1080 +0+0"

xorg.conf

This is my entire xorg.conf

# nvidia-settings: X configuration file generated by nvidia-settings
# nvidia-settings:  version 304.51  (buildd@batsu)  Fri Oct 12 12:53:54 UTC 2012

Section "ServerLayout"
    Identifier     "Layout0"
    Screen      0  "Screen0" 0 0
    InputDevice    "Keyboard0" "CoreKeyboard"
    InputDevice    "Mouse0" "CorePointer"
    Option         "Xinerama" "0"
EndSection

Section "Files"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Mouse0"
    Driver         "mouse"
    Option         "Protocol" "auto"
    Option         "Device" "/dev/psaux"
    Option         "Emulate3Buttons" "no"
    Option         "ZAxisMapping" "4 5"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Keyboard0"
    Driver         "kbd"
EndSection

Section "Monitor"
    # HorizSync source: edid, VertRefresh source: edid
    Identifier     "Monitor0"
    VendorName     "Unknown"
    ModelName      "Philips 234CL"
    HorizSync       30.0 - 83.0
    VertRefresh     56.0 - 76.0
    Option         "DPMS"
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "NVS 5400M"
EndSection

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "Stereo" "0"
    Option         "nvidiaXineramaInfoOrder" "DFP-2"
    Option         "metamodes" "DFP-2: 1920x1080 +0+0, DFP-3: 1920x1080 +1920+0"
    Option         "metamodes" "LVDS-0: 1920x1080 +0+0"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

Side note

I’m very open minded to mistakes I made, or clue’s to help the (un)docking problems, or better solutions.
PS: Jep, I played around with bumblebee, but did not end happy either.

Tagged with: , , , , ,
Posted in kubuntu, Lenovo, Linux, NVIDIA, Ubuntu
2 comments on “Lenovo T530, Kubuntu 12.10, NVIDIA Optimus, External Monitors
  1. Do My Essay says:

    Nvidia Optimus is utilized to spare vitality via naturally picking the “fitting” illustrations card for the present work being prepared, and enacting the overwhelming designs card for recreations, and so forth.

  2. Thank you a lot for sharing this submit. And also Recently I have skilled with , which is likewise a good aid for me. Just attempt it as soon as. I desire it is able to deliver valuable services to us.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

Anti-spam protection

Prove that you are Human by typing the emphasized characters:


Protected by Gab Captcha 2

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>