Problem with second monitor

Manjaro uses MHWD so when installing the driver, the /etc/X11/mhwd.d/nvidia.conf is generated automatically, and even tho is generic works on most installs by default. That is the file you want to alter if you are going for a different layout.
xorg.conf should not exist, so remove it.

Edit the /etc/X11/mhwd.d/nvidia.conf and make it like this:

Section "ServerLayout"
    Identifier     "Layout0"
    Screen      0  "Screen0"
    InputDevice    "Keyboard0" "CoreKeyboard"
    InputDevice    "Mouse0" "CorePointer"
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      "XMI Mi Monitor"
    HorizSync       160.0 - 160.0
    VertRefresh     48.0 - 144.0
    Option         "DPMS"
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    Option         "TripleBuffer"  "On"
    Option  "ConnectToAcpid"    "Off"
    Option "metamodes" "nvidia-auto-select +0+0 {ForceCompositionPipeline=On}"
EndSection

Section "Screen"
    Option         "Coolbits" "31"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

Section "Extensions"
    Option         "COMPOSITE" "Enable"
EndSection

 
Section "InputClass"
    Identifier          "Keyboard Defaults"
    MatchIsKeyboard        "yes"
    Option              "XkbOptions" "terminate:ctrl_alt_bksp"
EndSection
 

If the Option "TripleBuffer" "On" under the Section "Device" creates issues, remove that line …
Save it and then open up terminal and run:
sudo mhwd-gpu --setmod nvidia --setxorg /etc/X11/mhwd.d/nvidia.conf

If you want to make a fixed layout from Nvidia X Server Settings, both monitors need to be set to Absolute and you have to define both connectors and the nvidiaXineramaInfoOrder to start with the correct one.

Also you might have to enable early KMS

1 Like