LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 12-10-2016, 09:35 AM   #1
taylorkh
Senior Member
 
Registered: Jul 2006
Location: North Carolina
Distribution: CentOS 6, CentOS 7 (with Mate), Ubuntu 16.04 Mate
Posts: 2,127

Rep: Reputation: 174Reputation: 174
Is ANYONE using separate X screens?


On CentOS 6 (Ubuntu 9.10 before that) I am running separate X screens on my two monitors with an nVidia card. I have also run on an ATI card in the past. Each monitor acts independently. That is, if I launch a program from the panel on the left monitor, it displays on the left monitor. If I launch from the panel on the right monitor it displays on that monitor. I can NOT mover applications between monitors - which is fine. Most importantly I can change workspaces INDEPENDENTLY on each monitor.

On CentOS 7... I am having a hard time and it is getting worse. Early in the year I had it working reasonably well. By summer the updates had killed the desktop background on the second monitor (X screen 1) but I could still launch an application from the panel on the monitor and it would run there. I just did another install and regardless of which panel I launch from the program runs on X screen 0.

Here is what I have installed:

CentOS 7 minimal, enabled CR repo and updated
Added epel, elrepo and nux-dextop repos.
yum priorities CentOS 1, elrepo 5, epel 10, nux 15
groupinstall "X Window system"
groupinstall mate-desktop-environment

I am using this configuration on several single monitor systems with great results. On my main dual monitor PC - NOT! I am hoping to find someone ACTUALLY running separate X screens on CentOS 7 successfully. Or even a different distro? I do not really care about the desktop - simple is better which is why I am running Mate but I am open to something else. HELP! Please!!

TIA,

Ken
 
Old 12-11-2016, 03:45 AM   #2
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,260

Rep: Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321
I'm using a fairly simple setup. I have (Not all together) a D-Sub & HDMI connection to a 1920x1080 monitor, and hdmi to a 1280x720 projector. X configures what I plug in. The config file is a bit long to post. I list each card and monitor, and have a server layout & 3 screen sections
Code:
Section "ServerLayout"
    Identifier     "X.org Configured"
    Screen      0  "Screen0" 0 0
    Screen      1  "Screen1" RightOf "Screen0"
    Screen      2  "Screen2" RightOf "Screen0"
EndSection
[Snip cards & Monitor sections - 3 of each

Section "Screen"
    Identifier "Screen0"
    Device     "Card0"
    Monitor    "Main"
    Option   "Primary" 
    Option "PreferredMode"  "1600x900"
    Option "Position" "0 0"
    DefaultDepth    24
    SubSection     "Display"
#        Modes     "1600x900" "1440x900" 1280X720" "1280x720"  
        Depth       24
    EndSubSection   
EndSection

Section "Screen"
    Identifier "Screen1"
    Device     "Card1"
    Monitor    "HDMI1"
    Option "Position" "1601 0"
    DefaultDepth    24
    SubSection     "Display"
        Depth       24
        Modes      "1280x720"
        Virtual  2880 720   
    EndSubSection   
    SubSection     "Display"
        Depth       24
        Modes      "1920x1080"
        Virtual  3520 1080
    EndSubSection
EndSection
Section "Screen"
    Identifier "Screen2"
    Device     "Card2"
    Monitor    "VGA1"
    Option "Position" "1601 0"
    Option "RightOf" "Screen0"
    DefaultDepth    24
    SubSection "Display"
        Depth     24
        Modes  "1280x720" 
    EndSubSection
EndSection
Screen 0 is a 1600x900 laptop panel, 1 is hdmi, & 2 is a projector. It functions for me. Try something like that
 
1 members found this post helpful.
Old 12-11-2016, 10:04 AM   #3
taylorkh
Senior Member
 
Registered: Jul 2006
Location: North Carolina
Distribution: CentOS 6, CentOS 7 (with Mate), Ubuntu 16.04 Mate
Posts: 2,127

Original Poster
Rep: Reputation: 174Reputation: 174
Thanks business_kid. I do not think that the issue is with my xorg.conf. It is as simple as nvidia-settings can produce. The left monitor is rotated left to put it in portrait mode. It is also the primary monitor. The right monitor is in landscape mode. All of this works. I can mouse between them fine. I think something in the "X Window system" package group has changed since January when I built a successful install. I have tried stripping "extra" stuff from xorg.conf, using the working config from my CentOS 6 install (same hardware) etc. No luck.

I have a Clonezilla snapshot of an old January install which works. However, I am unable to update it today - it hangs on the fontconfig package which seems to be required by almost everything. A brand new install as described in the original post does not work.

May I ask you what distro, version, desktop etc. you are running on your system?

Thanks again,

Ken

p.s. I just finished an install substituting xfce for Mate. Same issue. Programs launch to the primary monitor only. I cannot move them to the other monitor which makes the separate X screens configuration worse than Xinerama - one giant display
 
Old 12-11-2016, 10:39 AM   #4
wpeckham
LQ Guru
 
Registered: Apr 2010
Location: Continental USA
Distribution: Debian, Ubuntu, RedHat, DSL, Puppy, CentOS, Knoppix, Mint-DE, Sparky, VSIDO, tinycore, Q4OS,Manjaro
Posts: 5,597

Rep: Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691
Quote:
Originally Posted by taylorkh View Post
Thanks business_kid. I do not think that the issue is with my xorg.conf. It is as simple as nvidia-settings can produce.
I think that is your problem. The updates have disabled the 'simple' options, and you need to take control: perhaps in the way described by business_kid.
 
Old 12-11-2016, 12:25 PM   #5
taylorkh
Senior Member
 
Registered: Jul 2006
Location: North Carolina
Distribution: CentOS 6, CentOS 7 (with Mate), Ubuntu 16.04 Mate
Posts: 2,127

Original Poster
Rep: Reputation: 174Reputation: 174
Thanks wpeckham. I guess you mean I should pare down the xorg.conf. I have tried that in the past but let me try again. I need to shut down my PC and swap hard drives - well SSDs anyhow - so it will be a little while until I post my findings.

Ken
 
Old 12-11-2016, 02:25 PM   #6
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,260

Rep: Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321
That nvidia-settings thing sounds like a pain, but I would scrap what settings you have if they don't work. Describe the bits you're going to plug in, and if X doesn't find them it will ignore them. There's plenty to copy & paste from. What I have (video.conf) is the video section of xorg.conf. Make sure no other config file references the video.

I'm on Slackware-14.1 & XFCE. The setup is from early 2015, and I'm not rushing to fiddle it due to health reversals.

EDIT: Just noticed you're on Centos, and compiling. I come to grief inevitably when I do that; something I compile clashes with something Centos updates. Can't help you there. Slackware you promote yourself to, and it's more DIY but it stays put for you and they don't try beta software out on you!

Last edited by business_kid; 12-11-2016 at 02:31 PM.
 
Old 12-11-2016, 02:46 PM   #7
taylorkh
Senior Member
 
Registered: Jul 2006
Location: North Carolina
Distribution: CentOS 6, CentOS 7 (with Mate), Ubuntu 16.04 Mate
Posts: 2,127

Original Poster
Rep: Reputation: 174Reputation: 174
Thanks again business_kid,

I am on CentOS but not compiling - at least not on this install. I am piling the desktop (Mate) on top of the X system on top of the CentOS minimal install. The desktop and X are from the epel repo, not compiled from source. I will build a stripped down xorg.conf as you recommend - and if it works I will just not touch it with nvidia-settings.

Ken
 
Old 12-12-2016, 02:10 PM   #8
taylorkh
Senior Member
 
Registered: Jul 2006
Location: North Carolina
Distribution: CentOS 6, CentOS 7 (with Mate), Ubuntu 16.04 Mate
Posts: 2,127

Original Poster
Rep: Reputation: 174Reputation: 174
Well here we go again... I built a new install from scratch as described earlier. While still on a single X screen configuration I rotated my left monitor to the portrait orientation and made it the primary display. Once this was all working and after a fresh reboot I switched to two X screens. After rebooting I had two screens with two panels on each. I can create a new launcher on the right monitor (X screen 1) but it launches the application on the left monitor (X screen 0).

Thinking back to a different issue I had some time ago I decided to see if I could force the application to run on the right monitor.
Code:
DISPLAY=":0.1" pluma
issued from a terminal will in fact launch the text editor on the right monitor However, I am unable to create a launcher to do the same thing. I will ask here and perhaps post a new question on a different forum. How do I create a Mate (Gnome 2) launcher which specifies the display on which it is to launch the application?

For anyone interested the xorg.conf looks like this
Code:
# nvidia-settings: X configuration file generated by nvidia-settings
# nvidia-settings:  version 340.98  (buildmeister@swio-display-x86-rhel47-06)  Mon Sep 19 18:06:10 PDT 2016

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"
    FontPath        "/usr/share/fonts/default/Type1"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Mouse0"
    Driver         "mouse"
    Option         "Protocol" "auto"
    Option         "Device" "/dev/input/mice"
    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 U2412M"
    HorizSync       30.0 - 83.0
    VertRefresh     50.0 - 61.0
    Option         "DPMS"
EndSection

Section "Monitor"
    # HorizSync source: edid, VertRefresh source: edid
    Identifier     "Monitor1"
    VendorName     "Unknown"
    ModelName      "DELL U2412M"
    HorizSync       30.0 - 83.0
    VertRefresh     50.0 - 61.0
    Option         "DPMS"
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "Quadro K420"
    BusID          "PCI:1:0:0"
    Screen          0
EndSection

Section "Device"
    Identifier     "Device1"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "Quadro K420"
    BusID          "PCI:1:0:0"
    Screen          1
EndSection

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "Stereo" "0"
    Option         "nvidiaXineramaInfoOrder" "DFP-2"
    Option         "metamodes" "DP-1: nvidia-auto-select +0+0 {rotation=left}"
    Option         "SLI" "Off"
    Option         "MultiGPU" "Off"
    Option         "BaseMosaic" "off"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

Section "Screen"
    Identifier     "Screen1"
    Device         "Device1"
    Monitor        "Monitor1"
    DefaultDepth    24
    Option         "Stereo" "0"
    Option         "metamodes" "DVI-I-1: nvidia-auto-select +0+0"
    Option         "SLI" "Off"
    Option         "MultiGPU" "Off"
    Option         "BaseMosaic" "off"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection
I found only two differences between this one and the "working" install back in January. The differences are highlighted. The first has to do with relative positioning of the screens vs. absolute positioning and the second a seemingly meaningless Xinerama option as Xinerama is disabled. I have modifed this file to match the old one. No change.

It seems to me that some upgrade during the year "broke" something in X. If I can get the specify display functionality to work from within a launcher I think I have a workable workaround.

Ken
 
Old 12-13-2016, 05:19 AM   #9
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,260

Rep: Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321
Unless you hear others saying it, you can take it the breakage is probably confined to your system. This is all established stuff, not under great active development afaik.

I would specify PreferredModes, and position clearly. For my main screen, I have a PreferredMode of 1600x900; The auxiliary screens have a Position of 1601 0. Also provide at least one Virtual setting, more if you're messing with modes like I was.

Many WMs have a setup that starts with several apps open. Look up how to do it in your wm. If I want something to open on the right screen, I set it to open on 1601, 0. There will be a similar logic for you.
 
Old 12-13-2016, 08:07 AM   #10
wpeckham
LQ Guru
 
Registered: Apr 2010
Location: Continental USA
Distribution: Debian, Ubuntu, RedHat, DSL, Puppy, CentOS, Knoppix, Mint-DE, Sparky, VSIDO, tinycore, Q4OS,Manjaro
Posts: 5,597

Rep: Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691
What you are driving now is a fairly standard multi-monitor setup. What you WERE running was a separate X for each monitor, which is very doable but non-standard.
My preference would be for the single X multi-monitor setup, as I really like the ability to slide application windows over to the other monitor. I guess the question now is "how happy are YOU with the new setup?". If you can take control of your shortcuts and get them to start on the proper monitor, will this make you happy?
 
Old 12-13-2016, 08:44 AM   #11
Shadow_7
Senior Member
 
Registered: Feb 2003
Distribution: debian
Posts: 4,137
Blog Entries: 1

Rep: Reputation: 874Reputation: 874Reputation: 874Reputation: 874Reputation: 874Reputation: 874Reputation: 874
I tend to use Xephyr if I need to segment out the X sessions. Which I oddly use to "scale" the output from a webcam that is streamed from a RPi B. Using cvlc only crops if you scale it. Where doing vlc in a small Xephyr window and going full screen scales to the size of the Xephyr window (smaller than the native video res). Aside from that niche case, I use Xephyr and Xdmx to break my screen into two or three parts and stack them vertically to see a lot of things at once on one screen. Like a full manpage, the complete output of top, or just a lot of lines of code in an xterm.

It's been getting harder and harder to keep each screen it's own X session. The last time I had independent screens natively was when I had a laptop with VGA output. As I wonder if Xephyr, Xnest (older cousin of Xephyr), and Xdmx work under wayland (or mir). The number of lines of code I could put on a 4K display, Hmmmm...

8 * 80 == 640
3840 / 640 == 6
2160 / 9 == 240
6 * 240 == 1,440

So an 80x1440 xterm session with an 8x9 bitmap font. Only 80x360 lines with the same on a single 1080p display. Although 80x405 with an 8x8 bitmap font on a 1080p. It's so much easier to debug things when you don't have to memorize the code 25 lines at a time.
 
Old 12-13-2016, 08:50 AM   #12
taylorkh
Senior Member
 
Registered: Jul 2006
Location: North Carolina
Distribution: CentOS 6, CentOS 7 (with Mate), Ubuntu 16.04 Mate
Posts: 2,127

Original Poster
Rep: Reputation: 174Reputation: 174
Good morning business_kid,

Yes, the breakage might be on my system. Unfortunately I have only one system with a discrete video card. All the rest of my machines have built in Intel graphics. I spent a couple of months earlier this year attempting to setup separate X screens on the Intel graphics "cards" which DO support two monitors but which have no configuration software which I could find. I had a heck of a time finding anyone on the various forums who even understood what separate X screens referred to. I finally came across a web page which showed the various dual monitor configuration. The author of the page concluded that separate X screens was the most efficient for getting work done. I concur. However, I think the trend is to make the PC desktop look like a large smart phone or tablet. Consider the Unity desktop on Ubuntu. And consier wpeckham's reply which just popped in which I will address in a moment.

I will try tweaking the PreferredModes option but I have not had any issues with the displays having the proper resolution. I have changed the
Code:
"Screen      1  "Screen1" RightOf "Screen0"
line back to absolute positioning but nothing changed.

As to a possible workaround... From the Ubuntu Mate forum I got the tip to make create the launchers on my :0.1 panel thusly
Code:
sh -c 'DISPLAY=":0.1" pluma'
This allows me to launch pluma from the panel on the right monitor to the right monitor even though the "desktop" on that monitor is black and does not respond to mouse activity (e.g. right click).

Thanks wpeckham,

Launching an application WHERE I want it on a single large display spanning two monitors... a possibility. Please allow me to explain why I like separate X screens and how I have my two 24" monitors setup.

The left monitor is pivoted to Portrait orientation. On the top half I have Thunderbird connected to several email accounts on my ISP's email server. The lower half is dedicated to a VMWare virtual machine which runs 5 instances of Firefox in 5 workspaces. Each instance is connected to a different email account on an secure email service in Switzerland (protonmail.ch - check it out). These two applications are ALWAYS running. I usually call up Firefox (on the host machine) on the left monitor as most web pages are tall and narrow. I always close out this Firefox instance when I am done with it for privacy/security reasons (clear cache, cookies etc.) I occasionally run something else on this monitor when I do not want to cover what is running on the right monitor - short term only.

The right monitor is in landscape mode. This is my main "working" display. I make use of 4 workspaces on this display. I may run a virtual machine, remote machine viewer (vinagre or Tigervnc client), gnome-commander, another instance of Firefox, etc..... I can split these between workspaces and change between the WITHOUT disturbing the left display. If I have a single display and I change workspaces I would disappear the two always on applications on the left monitor. That is the deal killer with a single X screen.

As far as sliding applications between monitors... The first time I saw that done (a fellow at work had two monitors on an Windoze XP machine) I though that was FANTASTIC. The first time I tried it I thouht it was TEDIOUS. Personal preference I guess.

Thanks again folks,

Ken
 
Old 12-13-2016, 11:48 AM   #13
taylorkh
Senior Member
 
Registered: Jul 2006
Location: North Carolina
Distribution: CentOS 6, CentOS 7 (with Mate), Ubuntu 16.04 Mate
Posts: 2,127

Original Poster
Rep: Reputation: 174Reputation: 174
Thanks Shadow_7,

I hate it when working things are "improved" into unusability.

Ken
 
Old 12-14-2016, 09:17 AM   #14
taylorkh
Senior Member
 
Registered: Jul 2006
Location: North Carolina
Distribution: CentOS 6, CentOS 7 (with Mate), Ubuntu 16.04 Mate
Posts: 2,127

Original Poster
Rep: Reputation: 174Reputation: 174
It boggles the mind... I had this setup working reasonably well except that I had the primary display on the left (portrait) monitor and I needed it to be on the right (landscape) monitor. The portrait monitor ALWAYS is covered with my email windows so the fact that the Desktop on the secondary monitor (X screen 1) is blank would not be a concern. I tried tweaking the working xorg.conf to swap the monitors. Wrong!

I have saved 9 versions of xorg.conf as I went step by step towards my "almost what I want" configuration. I had to go back to #4 and walk my way through versions 10, 11, 12 to finally 13 which has the second X screen in portrait on the left monitor. I ran a text compare between that file and my attempt to fix the darned thing by hand - I am confused. I have a metamodes option on the X screen 1 monitor as long as my arm
Code:
"metamodes" "DP-1: nvidia-auto-select +0+0 {rotation=left}; DP-1: 1920x1080 +0+0 {rotation=left}; DP-1: 1680x1050 +0+0 {rotation=left}; DP-1: 1600x1200 +0+0 {rotation=left}; DP-1: 1280x1024 +0+0 {rotation=left}; DP-1: 1280x960 +0+0 {rotation=left}; DP-1: 1024x768 +0+0 {rotation=left}; DP-1: 800x600 +0+0 {rotation=left}; DP-1: 640x480 +0+0 {rotation=left}; DP-1: nvidia-auto-select +0+0 {rotation=left, viewportin=900x1440}; DP-1: nvidia-auto-select +0+0 {rotation=left, viewportin=768x1366, viewportout=1920x1079+0+60}; DP-1: nvidia-auto-select +0+0 {rotation=left, viewportin=800x1280}; DP-1: nvidia-auto-select +0+0 {rotation=left, viewportin=720x1280, viewportout=1920x1080+0+60}"
The old X screen 1 said simply
Code:
metamodes" "DP-1: nvidia-auto-select +0+0 {rotation=left}"
I wonder what all this crap means? I wonder if I should wonder what all this crap means? I guess I can pare it down until it breaks - just because.

That said I now need to configure my ancient Brother MFC printer, scanner. faxer box to work on CentOS 7 and I need to install my home made 32 bit Wine environment so that I can run 3 critical 32 bit Windoze programs. I have one of them running on another CentOS 7 PC but have not tested the other two. And then I have to see if I remember how to install a 16 bit DOS program which I wrote before Y2K. I can't find dosemu in the repos. This might be fun.

Ken
 
Old 12-14-2016, 09:23 AM   #15
wpeckham
LQ Guru
 
Registered: Apr 2010
Location: Continental USA
Distribution: Debian, Ubuntu, RedHat, DSL, Puppy, CentOS, Knoppix, Mint-DE, Sparky, VSIDO, tinycore, Q4OS,Manjaro
Posts: 5,597

Rep: Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691Reputation: 2691
Quote:
Originally Posted by taylorkh View Post
And then I have to see if I remember how to install a 16 bit DOS program which I wrote before Y2K. I can't find dosemu in the repos. This might be fun.

Ken
1. It should be still possible to run two X instances side by side. You would have to hand-tune the configurations (yes, two of them) so that each would use ONLY the one monitor (possibly the interface as well) and ignore the other. Then start them with two different command lines forcing each to use only the desired conf file.

2. dosemu should be there, but if you do not find it try dosbox. It takes some tuning, but I have made it work for MANY DOS applications and games that would run no other way.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Two monitors - separate X screens taylorkh Linux - Hardware 4 12-14-2015 11:42 PM
Want separate screens for my desktop resetreset Linux - Desktop 1 07-04-2012 04:06 PM
[SOLVED] separate x screens with nvidia SeRi@lDiE Slackware 11 04-21-2011 09:36 PM
trouble between twinview and separate screens Tuttle Linux - Desktop 3 02-22-2008 07:51 AM
Twinview as separate screens, not stretched degraffenried13 Linux - General 3 06-06-2004 03:30 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 05:37 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration