You are not logged in.

#1 2012-04-25 15:09:31

Euphoria
Member
Registered: 2012-01-04
Posts: 8

Dual-head on NVIDIA

Hello, I'm trying to configure a dual-head setup (NVIDIA proprietary drivers). I've tried both Xinerama and Twinview, but the screen is always treated as one big virtual screen and window managers spread fullscreen windows over both monitors.

Here's what I've tried (they all resulted in the above):
- # nvidia-xconfig
- These instructions
- # nvidia-xsettings
- These instructions (I might've misunderstood them, they were fairly vague)

In addition, Xinerama seems to disable the randr extension, which makes me unable to use xrandr or arandr, so the preferred option is to use Twinview.

For clearance, when I open arandr, I see one big, wide screen called default. How do I set it up so that it shows 2 different screens?

Offline

#2 2012-04-25 15:18:18

lifeafter2am
Member
From: 127.0.0.1
Registered: 2009-06-10
Posts: 1,332

Re: Dual-head on NVIDIA

Using simple 'nvidia-settings' and TwinView works just fine here. arandr shows the same thing here, but it's definitely not working as one big screen in my WM. (never used arandr before, so don't know much about it)


#binarii @ irc.binarii.net
Matrix Server: https://matrix.binarii.net
-------------
Allan -> ArchBang is not supported because it is stupid.

Offline

#3 2012-04-25 16:11:15

Gusar
Member
Registered: 2009-08-25
Posts: 3,607

Offline

#4 2012-04-25 16:38:19

pekka
Member
Registered: 2011-07-21
Posts: 104

Re: Dual-head on NVIDIA

Use GUI Nvidia X Server Settings

Seperate X screen

Offline

#5 2012-04-25 19:16:51

Euphoria
Member
Registered: 2012-01-04
Posts: 8

Re: Dual-head on NVIDIA

Hm, if I were to follow those instructions, and replace all Monitor, Screen and Device section with the Device section that you gave, what should my ServerLayout section look like?


pekka wrote:

Use GUI Nvidia X Server Settings

Seperate X screen

When I do that, and enable Xinerama, it gives me the same result. If I disable it, the second monitor will not be used. It doesn't go to standby, but my window manager will not use it, and a new, separated instance of the window manager must be run to use it, which I do not want.

Last edited by Euphoria (2012-04-25 19:17:14)

Offline

#6 2012-04-25 19:31:45

Gusar
Member
Registered: 2009-08-25
Posts: 3,607

Re: Dual-head on NVIDIA

Euphoria wrote:

Hm, if I were to follow those instructions, and replace all Monitor, Screen and Device section with the Device section that you gave, what should my ServerLayout section look like?

What ServerLayout section? Use what I wrote and *only* that.

Offline

#7 2012-04-26 18:14:04

Euphoria
Member
Registered: 2012-01-04
Posts: 8

Re: Dual-head on NVIDIA

Gusar wrote:
Euphoria wrote:

Hm, if I were to follow those instructions, and replace all Monitor, Screen and Device section with the Device section that you gave, what should my ServerLayout section look like?

What ServerLayout section? Use what I wrote and *only* that.

I've the idea that xorg.conf.d with multiple files is the preferred method, but I don't know how to set that up. Using the files that are there right now don't work (though they used to, I'm not sure what that is), so I use the single xorg.conf file as produces by nvidia-xconfig

Using an xorg.conf with only that, produces this error. Essentially, no screens are found.

The xorg.conf produced by nvidia-xconfig after having deleted any previous xorg.conf, results in this file. However, that config only uses one of the monitors. The xorg.conf that has Xinerama enabled, with the bug as described in the OP, looks like this.

Offline

#8 2012-04-26 18:23:48

BurntSushi
Member
From: Massachusetts
Registered: 2009-06-28
Posts: 362
Website

Re: Dual-head on NVIDIA

You should be using TwinView with nvidia-settings. You should not have to modify any configuration files by hand.

You should not be using Xinerama.

Which window manager are you using? Even though TwinView is not Xinerama, the information about your monitors is still reported through the Xinerama extension (this also happens if you're using RandR).

If you're using TwinView, xrandr and its associated GUI utilities will not work. They will show one big screen.

To sum up: if your window manager reads Xinerama information, simply using TwinView should be enough.


Education is favorable to liberty. Freedom can exist only in a society of knowledge. Without learning, men are incapable of knowing their rights, and where learning is confined to a few people, liberty can be neither equal nor universal.

Tu ne cede malis sed contra audentior ito

Offline

#9 2012-04-26 18:35:34

Gusar
Member
Registered: 2009-08-25
Posts: 3,607

Re: Dual-head on NVIDIA

xorg.conf is equivalent to a file in the xorg.conf.d/ dir. Think of "xorg.conf" as "xorg.conf.d/99-something.conf". It's exactly the same. And in any case, you put into a conf file only the section where you're actually configuring something. All the extra stuff these old configurators (like nvidia-xconfig) put in there don't interfere in the best case scenario, but at times they mess things up.

That log you've provided doesn't show the nvidia driver loading anywhere, all I see is that the vesa driver is being made to run for some Card0. So you're not using what I've provided at that link. I'm guessing you have a mess of conf files in xorg.conf.d/. Remove all of them except 10-evdev.conf and 10-quirks.conf, also remove xorg.conf. Then create a new file with what I've provided at that link.

Offline

#10 2012-04-26 20:02:38

Euphoria
Member
Registered: 2012-01-04
Posts: 8

Re: Dual-head on NVIDIA

Gusar wrote:

xorg.conf is equivalent to a file in the xorg.conf.d/ dir. Think of "xorg.conf" as "xorg.conf.d/99-something.conf". It's exactly the same. And in any case, you put into a conf file only the section where you're actually configuring something. All the extra stuff these old configurators (like nvidia-xconfig) put in there don't interfere in the best case scenario, but at times they mess things up.

That log you've provided doesn't show the nvidia driver loading anywhere, all I see is that the vesa driver is being made to run for some Card0. So you're not using what I've provided at that link. I'm guessing you have a mess of conf files in xorg.conf.d/. Remove all of them except 10-evdev.conf and 10-quirks.conf, also remove xorg.conf. Then create a new file with what I've provided at that link.

Thanks, I thought an xorg.conf file served as a replacement for the xorg.conf.d directory.

However, I've tried exactly that, and it still resulted in the same thing.

Offline

#11 2012-04-26 21:43:23

Gusar
Member
Registered: 2009-08-25
Posts: 3,607

Re: Dual-head on NVIDIA

What exactly is "the same thing"?

Offline

#12 2012-04-27 08:27:24

Ffeiofewpoj
Member
Registered: 2012-01-26
Posts: 9

Re: Dual-head on NVIDIA

Gusar wrote:

What exactly is "the same thing"?

I'm not at my home computer and I don't know my password, but so I'm replying with this account.

"The same thing" means that the screen is treated as one big virtual screen and window managers spread fullscreen windows over both monitors. This happens with i3 and notion.

Offline

#13 2012-04-27 08:30:30

Ffeiofewpoj
Member
Registered: 2012-01-26
Posts: 9

Re: Dual-head on NVIDIA

I just realized that I kind of overlooked the "Adjust the display names appropriately" part. How do I know which names to use?

Offline

#14 2012-04-27 08:33:23

Gusar
Member
Registered: 2009-08-25
Posts: 3,607

Re: Dual-head on NVIDIA

The problem is the window managers then. That arandr sees one big screen is normal, because twinview isn't xrandr1.2. They work very similarly though, so this doesn't make a difference for window managers. If i3 and notion don't work properly with twinview, they wouldn't work properly with xrandr1.2 either.

Offline

#15 2012-04-27 09:02:06

Ffeiofewpoj
Member
Registered: 2012-01-26
Posts: 9

Re: Dual-head on NVIDIA

Gusar wrote:

The problem is the window managers then. That arandr sees one big screen is normal, because twinview isn't xrandr1.2. They work very similarly though, so this doesn't make a difference for window managers. If i3 and notion don't work properly with twinview, they wouldn't work properly with xrandr1.2 either.

Right here I'm using i3 on a dual-head setup, and it works as expected. Arandr does show multiple screens here, so I guess that means it uses Xinerama, and i3 works with it (notion also did).

The difference here is that I'm using an ATI video card. I configured it with the aticonfig command, and adding the line

Virtual 2400 1920

to my "Screen" Section. But that was only because it said the sum of the resolutions was too big for the virtual screen (something along those lines).

I can't test it right now, but do you think adding something like that could solve it?

Offline

#16 2012-04-27 09:13:46

Gusar
Member
Registered: 2009-08-25
Posts: 3,607

Re: Dual-head on NVIDIA

arandr (as it's name implies) does randr, not xinerama.

What arandr shows with twinview is irrelevant. And I still maintain that the problem is i3, not twinview. Try another window manager, say openbox. If openbox won't work, something else is screwy on your machine. If this was Gentoo, I'd tell you to activate a USE flag many people forget to activate, but this isn't Gentoo.

Offline

#17 2012-04-27 11:33:36

Ffeiofewpoj
Member
Registered: 2012-01-26
Posts: 9

Re: Dual-head on NVIDIA

Gusar wrote:

arandr (as it's name implies) does randr, not xinerama.

Well, the randr extension is irrelevant when Twinview is used, but arandr and xrandr work like normally, so that's why I figured Xinerama is in use here. Can randr serve as a replacement to Twinview/Xinerama? If so, how?

Offline

#18 2012-04-27 11:39:03

Gusar
Member
Registered: 2009-08-25
Posts: 3,607

Re: Dual-head on NVIDIA

Ffeiofewpoj wrote:

Can randr serve as a replacement to Twinview/Xinerama?

If a driver supports it, sure. Nvidia doesn't though, they support xrandr up to 1.1, but 1.2+ is needed for multiple displays. They wouldn't need twinview if they had xrandr1.2 support.

Have you tested other window managers? Openbox works perfect with twinview, as do plenty of other window managers.

Offline

#19 2012-04-27 11:55:29

lifeafter2am
Member
From: 127.0.0.1
Registered: 2009-06-10
Posts: 1,332

Re: Dual-head on NVIDIA

Gusar wrote:
Ffeiofewpoj wrote:

Can randr serve as a replacement to Twinview/Xinerama?

If a driver supports it, sure. Nvidia doesn't though, they support xrandr up to 1.1, but 1.2+ is needed for multiple displays. They wouldn't need twinview if they had xrandr1.2 support.

Have you tested other window managers? Openbox works perfect with twinview, as do plenty of other window managers.

I've personally used XMonad, dwm, and Awesome ... which all work perfectly.


#binarii @ irc.binarii.net
Matrix Server: https://matrix.binarii.net
-------------
Allan -> ArchBang is not supported because it is stupid.

Offline

#20 2012-04-27 14:40:54

Ffeiofewpoj
Member
Registered: 2012-01-26
Posts: 9

Re: Dual-head on NVIDIA

Thanks for all the help, at least I understand it now.

I really thought testing it with i3 and Notion was enough, I will test Awesome and XMonad when I get home.

Offline

#21 2012-04-27 14:54:21

pekka
Member
Registered: 2011-07-21
Posts: 104

Re: Dual-head on NVIDIA

Separate X sessions on dual screens (both monitors have own x sessions )

no xrandr

only
GUI Nvidia X Server Settings

# nvidia-settings: X configuration file generated by nvidia-settings
# nvidia-settings:  version 295.40  (buildmeister@swio-display-x86-rhel47-06.nvidia.com)  Thu Apr  5 22:40:34 PDT 2012


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

Section "Files"
EndSection

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

Section "InputDevice"
    Identifier     "Keyboard0"
    Driver         "kbd"
EndSection

Section "Monitor"
    Identifier     "Monitor0"
    VendorName     "Unknown"
    ModelName      "FUS SL3220W"
    HorizSync       30.0 - 83.0
    VertRefresh     56.0 - 75.0
    Option         "DPMS"
EndSection

Section "Monitor"
    Identifier     "Monitor1"
    VendorName     "Unknown"
    ModelName      "NEC LCD22WV"
    HorizSync       31.0 - 83.0
    VertRefresh     56.0 - 76.0
    Option         "DPMS"
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "GeForce GTS 250"
    Option         "RegistryDwords" "PerfLevelSrc=0x2222"
    BusID          "PCI:1:0:0"
EndSection

Section "Device"
    Identifier     "Device1"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "GeForce 9600 GT"
    Option         "RegistryDwords" "PerfLevelSrc=0x2222"
    BusID          "PCI:2:0:0"
EndSection

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "TwinView" "0"
    Option         "TwinViewXineramaInfoOrder" "DFP-0"
    Option         "metamodes" "nvidia-auto-select +0+0"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

Section "Screen"
    Identifier     "Screen1"
    Device         "Device1"
    Monitor        "Monitor1"
    DefaultDepth    24
    Option         "TwinView" "0"
    Option         "TwinViewXineramaInfoOrder" "CRT-0"
    Option         "metamodes" "nvidia-auto-select +0+0"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

Tested Kde,Xfce,Lxde.Awesome

Offline

#22 2012-04-27 15:17:20

Gusar
Member
Registered: 2009-08-25
Posts: 3,607

Re: Dual-head on NVIDIA

That's one weird setup you have there. Two graphic cards for just two displays? You could save yourself the power and only use one card.

Further weirdness: Having TwinViewXineramaInfoOrder in there makes no sense considering you're not using twinview. The metamodes lines make no sense either, or they do but they're totally redundant. And finally, those InputDevice sections do nothing. See kids, that's why you don't use those automatic configurators, all sorts of craziness comes with them.

Anyway, while Xinerama works, you don't get composite support and GL performance (also probably performance of xrender) is lower with it. It only makes sense to use it with two graphic cards and three displays - in this case you use twinview for two displays on the first card and then use Xinerama to stitch them together with the third display on the second card.

And starting with Kepler, four displays are supported with twinview (which is now wrongly named smile)

Offline

#23 2012-04-27 20:25:23

Euphoria
Member
Registered: 2012-01-04
Posts: 8

Re: Dual-head on NVIDIA

Well, it seems like I've picked exactly the wrong window managers: it's worked as expected on XMonad, Awesome, and an old gem I kind of forgot about: Stumpwm, which I'm going with.

And I'm using it with Xinerama now, so that I can rotate one of my pivot screens. All works well, again, thanks.

Offline

#24 2012-05-01 02:16:33

BurntSushi
Member
From: Massachusetts
Registered: 2009-06-28
Posts: 362
Website

Re: Dual-head on NVIDIA

You need to enable the 'force_xinerama' option in i3. See the i3 multi monitor situation.


Education is favorable to liberty. Freedom can exist only in a society of knowledge. Without learning, men are incapable of knowing their rights, and where learning is confined to a few people, liberty can be neither equal nor universal.

Tu ne cede malis sed contra audentior ito

Offline

Board footer

Powered by FluxBB