Page 1 of 2 12 LastLast
Results 1 to 10 of 12

Thread: Question on Multiple monitors - login screen only on "main" display

  1. #1

    Default Question on Multiple monitors - login screen only on "main" display

    Good evening,

    Scenario:
    I installed OpenSuse 42.3 today, everything fine.
    I installed the system with both monitors attached, call them "VGA" and "HDMI" from now on (by default, the installation went on the "HDMI" display).

    I'd like to have a specific display setup:
    * the VGA display works as the "main" and everything from the login screen to the desktop goes here by default
    * the HDMI display is switched on only when I want to use it (ex. I start a VirtualBox VM and move it to this HDMI display), or this display is connected to my laptop

    Questions:
    1) is this possible?
    2) if possible, I assume some manual configuration/editing is required - what should I do?

    Reason for such configuration:
    * the "VGA" display has only a VGA connection and cannot connect it to another system without disconnecting it from the desktop;
    * the HDMI display has multiple input ports, so I can share it with the desktop or my laptop or my Macbook;

    My actions until now:
    * Using "Settings -> Configure Desktop -> Display And Monitor" I set up the display position as I want (VGA on the left, HDMI on the right)
    * Plus, I set the VGA as "Primary Display".

    What I get now:
    * on boot, the system shows the same on both screens (POST, OpenSuse boot menu, login screen) [fine with this]
    * the login screen is on both, but the input focus is on the HDMI screen [NOT OK - input should be on the VGA]
    * KDE and taskbar are on the VGA display [OK]
    * desktop content (folders and links) are on both monitors [I can live with this]
    * most of the times application windows open on the HDMI screen [NOT OK - I'd like to have everything on "VGA"]
    * note that the "lock" screen asks for the login credentials on the "main"

    OS:
    * Leap 42.3, KDE

    HW:
    * Intel i7-7700, 32GB RAM
    * ASUS Prime Z270-K
    * Integrated Intel HD Graphics (multiple outputs: VGA, HDMI, DVI)
    * 2 monitors, one VGA other HDMI


    Best Regards.

  2. #2
    Join Date
    Dec 2008
    Location
    FL, USA
    Posts
    3,707
    Blog Entries
    1

    Default Re: Question on Multiple monitors - login screen only on "main" display

    What you want essentially involves designating the VGA output as primary, either using --primary in an xrandr startup instance, 'Option "Primary" "true"' in xorg.conf*, or a GUI tool that enables equivalent setup. Probably arandr can do it if you don't run Gnome or KDE and use their equivalents. When I want to run xrandr on startup in openSUSE I create /etc/X11/xinit/xinitrc.d/setup to do the job. Examples of some of my usages of both xorg.conf* and xrandr can be seen in setup and xorg.conf-intel-1920x1080overunder-120 among others at http://fm.no-ip.com/Share/Linux/ .

  3. #3

    Default Re: Question on Multiple monitors - login screen only on "main" display

    Thanks a lot for your prompt reply.

    My first attempt:
    * installed arandr, did the configuration of VGA (DP-1) as primary, saved the result in my home folder, checked the contents - seems ok:

    #!/bin/sh
    xrandr --output DP-1 --primary --mode 1920x1080 --pos 0x0 --rotate normal --output HDMI-2 --off --output HDMI-1 --mode 1920x1080 --pos 1920x0 --rotate normal

    * removed the #!/bin/sh from the text
    * copied it to etc/X11/xinit/xinit.d/setup ==> no effect (application windows go to HDMI-1)

    On a first try, it seemed to work but only because I forgot to remove the file saved in my home folder under ".screenlayout".

    As far as I understand, up to the login box a default or automatic configuration applies so that:
    * HDMI-1 is "left" at 0,0
    * DP-1 is "right" at 1920,0
    Just after login, my configuration applies:
    * DP-1 is "left" at 0,0
    * HDMI-1 is "right" at 1920,0

    Will try again.

  4. #4
    Join Date
    Dec 2008
    Location
    FL, USA
    Posts
    3,707
    Blog Entries
    1

    Default Re: Question on Multiple monitors - login screen only on "main" display

    Did you restart Xorg (sddm or lightdm or whatever login manager) or reboot rather than just logging out and back in after creating /etc/X11/xinit/xinit.d/setup? Did you make /etc/X11/xinit/xinit.d/setup executable? It may be that whatever setup you tried originally in KDE is undoing what /etc/X11/xinit/xinit.d/setup does and needs to be cleared. Same for arandr. Both make settings personal to the user, while /etc/X11/xinit/xinit.d/setup is a global setting that personal settings can override.

  5. #5
    Join Date
    Aug 2008
    Location
    Brazil
    Posts
    3,269

    Default Re: Question on Multiple monitors - login screen only on "main" display

    My experience with LEAP 42.3 KDE, nvidia graphics card:

    I've noticed that different cards (even from the same vendor) prioritize multiple displays differently. For example, a GTX 650 would only show the login screen in one monitor, a GTX 1050 shows on both. Some time ago the default output would be VGA, then it was DVI and now it appears to be HDMI in recent cards.

    Quote Originally Posted by alphapapa View Post
    * desktop content (folders and links) are on both monitors [I can live with this]
    Here I can have different content in each monitor, as the displays are set to Desktop. I think you have repeat displays if they as ser as Folder View. Right-click desktop>configure display>layout, choose Desktop (translated from pt_BR, so may not be the exact text).

    Quote Originally Posted by alphapapa View Post
    * most of the times application windows open on the HDMI screen [NOT OK - I'd like to have everything on "VGA"]
    There are some settings in KDE where you can choose where windows will be open - the can remember the last display/position, follow the cursor, etc. Mine is set to remember last position, but both monitors as permanently connected, you'd have to test after disconnecting and reconnecting an external monitor.

    Quote Originally Posted by alphapapa View Post
    * note that the "lock" screen asks for the login credentials on the "main"
    Here with a GTX 1050 on LEAP 42.3 the lock screen is shown on both displays *and* I can type the password in any one. With the GTX 650 on oS 13.2 it only showed in one - the wrong one, of course. This was the HDMI output with a HDMI>DVI cable.

  6. #6
    Join Date
    Aug 2008
    Location
    Brazil
    Posts
    3,269

    Default Re: Question on Multiple monitors - login screen only on "main" display

    Note: It's been a long time since I had to fuss with X config files or xrandr (thank $DEITY). Now it can all be done from the settings menus.

  7. #7

    Default Re: Question on Multiple monitors - login screen only on "main" display

    Quote Originally Posted by mrmazda View Post
    Did you restart Xorg (sddm or lightdm or whatever login manager) or reboot rather than just logging out and back in after creating /etc/X11/xinit/xinit.d/setup? Did you make /etc/X11/xinit/xinit.d/setup executable? It may be that whatever setup you tried originally in KDE is undoing what /etc/X11/xinit/xinit.d/setup does and needs to be cleared. Same for arandr. Both make settings personal to the user, while /etc/X11/xinit/xinit.d/setup is a global setting that personal settings can override.
    Yes, rebooted the system on every attempt

    Yes, setup is executable (I made it r-xr-xr-x just to be sure)

    I did some steps more:
    * creating another user: it goes with the "default" (HDMI-1 as primary)
    * setting HMDI1 --off in the xrandr command inside setup: no effect, HDMI1 is on at the login prompt

    I assume that there are other system settings overriding setup.

    Question: does xrandr generate an activity log? where? this could be a good source of information

    I looked around for xorg.conf - found nothing; other configuration items worth checking?


    Thanks in advance.

  8. #8

    Default Re: Question on Multiple monitors - login screen only on "main" display

    Quote Originally Posted by brunomcl View Post
    I've noticed that different cards (even from the same vendor) prioritize multiple displays differently. For example, a GTX 650 would only show the login screen in one monitor, a GTX 1050 shows on both. Some time ago the default output would be VGA, then it was DVI and now it appears to be HDMI in recent cards.
    Yep. That's really annoying even on Windows systems...


    Quote Originally Posted by brunomcl View Post
    There are some settings in KDE where you can choose where windows will be open - the can remember the last display/position, follow the cursor, etc. Mine is set to remember last position, but both monitors as permanently connected, you'd have to test after disconnecting and reconnecting an external monitor.
    Thanks. I found that setting. Now my windows open on the "active" screen - that's where I clicked with the mouse.

  9. #9
    Join Date
    Dec 2008
    Location
    FL, USA
    Posts
    3,707
    Blog Entries
    1

    Default Re: Question on Multiple monitors - login screen only on "main" display

    Quote Originally Posted by alphapapa View Post
    I looked around for xorg.conf - found nothing
    They are optional. You must create it/them if you want or need.

  10. #10

    Default Re: Question on Multiple monitors - login screen only on "main" display

    Hm.

    Until now, no luck with /etc/X11/xinit/xinitrc.d/setup:

    xrandr --output DP-1 --primary --mode 1920x1080 --pos 0x0 --rotate normal
    xrandr --output HDMI-1 --mode 1920x1080 --pos 1920x0 --rotate normal



    I tried it as a shell script too, no effect.

    #!/bin/sh
    xrandr --output DP-1 --primary --mode 1920x1080 --pos 0x0 --rotate normal
    xrandr --output HDMI-1 --mode 1920x1080 --pos 1920x0 --rotate normal


    This is the content of the folder, setup/setup.sh is rwxr-xr-x so it should be readable and executable by anyone.

    AlphaPapa:/etc/X11/xinit/xinitrc.d # ls -l
    total 16
    -rwxr-xr-x 1 root root 198 Jan 30 16:25 50-systemd-user.sh
    -rwxr-xr-x 1 root root 172 May 10 2017 libcanberra-gtk-module.sh
    -rwxr-xr-x 1 root root 154 Feb 12 23:29 setup.sh
    -rwxr-xr-x 1 root root 40 Mar 18 2017 xdg-user-dirs.sh
    AlphaPapa:/etc/X11/xinit/xinitrc.d # vi setup.sh
    AlphaPapa:/etc/X11/xinit/xinitrc.d #


    What's puzzling me is that:
    * user settings are more or less OK, when I log in DP-1 is the primary - so the settings I saved when running K Menu ==> Settings ==> Desktop settings are stored (somewhere)
    * system settings are either ignored or immediately overwritten - hard to tell

    Reading /var/log/xorg.log.0 I see the "default" settings (HDMI-1 left at 0,0, DP-1 right)

    [ 35.203] (II) modeset(0): Output HDMI-1 connected
    [ 35.203] (II) modeset(0): Output HDMI-2 disconnected
    [ 35.203] (II) modeset(0): Output DP-1 connected
    [ 35.203] (II) modeset(0): Using spanning desktop for initial modes
    [ 35.203] (II) modeset(0): Output HDMI-1 using initial mode 1920x1080 +0+0
    [ 35.203] (II) modeset(0): Output DP-1 using initial mode 1920x1080 +1920+0
    [ 35.203] (II) modeset(0): Using default gamma of (1.0, 1.0, 1.0) unless otherwise stated.
    [ 35.203] (==) modeset(0): DPI set to (96, 96)

Page 1 of 2 12 LastLast

Posting Permissions

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