Results 1 to 2 of 2

Thread: Multiple monitor setups & xorg.conf - need help

  1. #1
    Join Date
    May 2008
    Beans
    162

    Multiple monitor setups & xorg.conf - need help

    I use three different monitor setups, depending on where I am located:
    1. Dual 1920x1080 monitors (at work", Dell 6510 in a dock)
    2. 1920x1080 + 1440x900 monitors (at home, same Dell 6510 in a dock)
    3. 1920x1080 laptop screen alone (on the go, out of dock)

    My xorg.conf file worked out OK until I upgraded to 11.04, and now it fouls me up when using the laptop screen by itself (thinks it's a 3840x1080 layout and only shows the right-hand half). The external monitor setups work, but displays this error message while starting X:

    http://dl.dropbox.com/u/2924774/Metamodes%20Error.png

    Any help would be greatly appreciated. NVIDIA Server setting app doesn't help me get this right - and I wish I understood what Metamodes were supposed to do here. My xorg.conf file text:

    # nvidia-settings: X configuration file generated by nvidia-settings
    # nvidia-settings: version 270.29 (buildd@allspice) Fri Feb 25 14:42:07 UTC 2011

    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 "DELL SE198WFP"
    HorizSync 30.0 - 83.0
    VertRefresh 56.0 - 75.0
    Option "DPMS"
    EndSection

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

    Section "Screen"
    Identifier "Screen0"
    Device "Device0"
    Monitor "Monitor0"
    DefaultDepth 24
    Option "TwinView" "1"
    Option "TwinViewXineramaInfoOrder" "DFP-1"
    Option "metamodes" "DFP-0: nvidia-auto-select +1920+0, DFP-1: nvidia-auto-select +0+0"
    SubSection "Display"
    Depth 24
    EndSubSection
    EndSection
    Last edited by windfix; May 6th, 2011 at 08:22 PM.

  2. #2
    Join Date
    May 2008
    Beans
    162

    Metamodes, how-to

    OK, I fixed this through several hours of fiddling. A big F You to NVIDIA settings app for making this undocumented (that I could find) and a PIA.

    Learned:

    You can define multiple Metamodes in the Screen section of xorg.conf. They can either be sequentially defined in the same option line (separated by a semicolon ; ) OR you can add a new option line for each one (which reads a little easier). Important: the sequence of metamodes is crucial. Each will be tried in sequence, and failing success will move to the next one.

    So, for my example of 3 locations (work, home, laptop undocked), I need to define the dual HD monitors (work) first. If I am docked at home, where one monitor can not do HD (1920x1080), then the 1st metamode fails and the 2nd metamode succeeds. My 2nd metamode defines the first flat panel display (DFP-0) as HD and the second (DFP-1) as 1440x900.

    If I am undocked, the 1st and 2nd metamodes both fail because they include dual monitors, and the 3rd metamode succeeds (where only one, DFP-0) is defined.

    Notes:
    • To my knowledge nvidia settings app can NOT set you up for three metamodes. You have to edit xorg.conf directly
    • Make darn sure you backup your xorg.conf files before messing with them. And once you get this right, save a copy in your home folder in case you need it later after a complete system reinstall or you will be doing this all over again.
    • Logging out to restart Xserver does not succeed in getting me laptop-only when I undock the laptop. Do a full restart to get the 3rd metamode. When docked, the laptops monitor gets identified as DFP-2 and that does not change just by logging out.
    • The Option line, just above metamodes, that has "TwinViewXineramaInfoOrder" defines which of the displays is primary. This determines which one Unity launcer or gnome2 panels are assigned to.
    • I guess that nvidia-auto-select can be used in place of a screen resolution so that the highest available is used. Nvidia settings application uses this when it creates an xorg.conf file for you
    • I still get that error message (linked file in first post), but it works anyway.
    • You can define a metamode with just screen resolutions (omitted the specific display lable, ie DFP-0 or DFP-1). Example "1920x1080, 1920x1080" for dual monitors. However, since my laptop screen can also do this resolution, it grabs one external monitor and adds my laptop screen. Not what I wanted.


    My revised, and now successful, xorg.conf file is pasted below:

    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 "DELL SE198WFP"
    HorizSync 30.0 - 83.0
    VertRefresh 56.0 - 75.0
    Option "DPMS"
    EndSection

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

    Section "Screen"
    Identifier "Screen0"
    Device "Device0"
    Monitor "Monitor0"
    DefaultDepth 24
    Option "TwinView" "1"
    Option "TwinViewXineramaInfoOrder" "DFP-0"
    Option "metamodes" "DFP-0: nvidia-auto-select +0+0, DFP-1: nvidia-auto-select +1920+0"
    Option "metamodes" "DFP-0: 1920x1080 +0+0,DFP-1: 1440x900 +1920+0"
    Option "metamodes" "DFP-0: nvidia-auto-select +0+0"
    SubSection "Display"
    Depth 24
    EndSubSection
    EndSection




    Update: Still works with Oneiric!
    Last edited by windfix; October 20th, 2011 at 09:03 PM. Reason: Update

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •