Screen changing resolution without input by me

I have an annoying situation on my TW KDE system. I use a KVM switch to allow me to switch between this system and another small PC. Sometimes when it is switched to the other PC the TW system alters the screen resolution but with no action or input by me. So when I switch back the display is 1024x768 and not 1920x1080 which is how it is set up. Also when I try to use System Settings Display & Monitor I am unable to increase the resolution as the maximum available shows as 1024x768. The only way I’ve been able to reset it is to logout and login again which is intensely annoying. Incidentally the other PC which is running Windows 7 does not change resolution at all no matter how long the monitor is switched away from it.

So something is doing this while the monitor is switched away from the TW system. Is there any way I can prevent this or perhaps at a push at least reset it by command rather than having to logout/in?

Stuart

Hi, your initial post is from 2018, no answer, but maybe now :slight_smile:

I have exactly the same behaviour with Leap 15.5, KDE/Plasma on Wayland, ā€œMesa IntelĀ® HD Graphicsā€

My Monitor (Dell 2720D) is connected to the Leap 15.5 box via DisplayPort, screen resolution 2560*1440, as it should be.

Also connected to this Monitor, but via HDMI, is an NVR. When I change input source of Monitor to HDMI, NVR works fine, but when I then switch back to DisplayPort, screen resolution is reduced to FullHD, and settings show this as available maximum resolution.
Workaround, as you said, logout/login, or reboot. A little annoying as I often have pretty much stuff opened in parallel…

QUESTION: Is there any chance to trigger a ā€œrereadā€ of max. screen resolution in a runnning Wayland / Plasma session, via bash? Or set it ā€œhardā€ via bash?

Other then the zombie thread you awoke :dizzy_face:

Most likely the KVM switch does not respond to the handshaking needed to determine the screens capabilities.

1 Like

Does the NVR support and use 2560x1440? Is a firmware update available for the 2720D?

Possible workarounds for Xorg/X11 use:

  1. xrandr --auto (simply xrandr might be enough)
  2. xrandr --output DP-1-8 --auto (use appropriate output name supplied from #1 output or name found in Xorg.0.log or its Wayland equivalent)
  3. xrandr --output DP-1-8 --mode 2560x1440 (use appropriate output name supplied from #1 output)
  4. Switch to any of vttys not in use by X (e.g. Ctrl-Alt-F4), then switch back (Alt-F7, Alt-F1, Alt-F2 - whichever works)
  5. Create configuration logically connecting the two outputs in use to the respective displays, and include monitor HorizSync and VertRefresh values for the problem display in ā€˜Section ā€œMonitorā€ā€™, via /etc/X11/xorg.conf.d/. As alternative to the H & V specs, providing a 2560x1440 modeline might work. The sax3 utility might be able to do all this, much easier than manually, if it works at all.
  6. Create an xrandr script that creates and applies a 2560x1440 modeline.

I suspect if #1 fails, so would #2 & #3, resulting in a mode not found error. I suppose in Wayland #4 should work and #5 might work. My personal experience using Wayland remains null.

HTH

@mrmazda Thanks for your answer!! I’ve the strong feeling that this issue is related to my DELL’s ā€œautoā€ input mode feature, as not 100%, but somewhat reproducible:

When I have input mode set to ā€œautoā€, means DP or HDMI, and plug in NVR’s HMDI cable, DELL monitor switches to the NVR, (which, you’ve asked, supports and is set to 2K/2560*1440) automatically. When I then switch back manually to PC/OpenSUSE, I have the ā€œlost resolution issueā€. NOT always, but quite often. When I’ve set the input mode to DP or HDMI instead of auto, AFAIK until now the modes are staying stable. Writing now from 1280*1024, as current max, funny on a 27’ monitor :slight_smile:

To your suggestions:

  1. xrandr --auto does nothing.

(xrandr without params shows ā€œXWAYLAND0ā€ as output name)

  1. … does nothing
  2. … says ā€œxrandr: cannot find mode 2560x1440ā€
  3. … is interesting: Even the vttys are ā€œsqueezedā€, other (much bigger characters) resolution… But: Switch to and switch back (to Wayland) does not change anything

5 and 6:

As I’m not very familiar with X11 config files etc., never heard about sax3, I’ve tried your ā€œcreate and apply modelineā€ idea following this Linux MINT hint: How to enable 2560x1440 option for display in Linux Mint? - Unix & Linux Stack Exchange

means:

$> cvt 2560 1440 
# 2560x1440 59.96 Hz (CVT 3.69M9) hsync: 89.52 kHz; pclk: 312.25 MHz
Modeline "2560x1440_60.00"  312.25  2560 2752 3024 3488  1440 1443 1448 1493 -hsync +vsync

$> xrandr --newmode "2560x1440_60.00"  312.25  2560 2752 3024 3488  1440 1443 1448 1493 -hsync +vsync

$> xrandr --addmode XWAYLAND0  2560x1440_60.00

which leads to this error in the final step:

$> xrandr --output XWAYLAND0 --mode 2560x1440_60.00 
X Error of failed request:  BadValue (integer parameter out of range for operation)
  Major opcode of failed request:  141 (RANDR)
  Minor opcode of failed request:  21 (RRSetCrtcConfig)
  Value in failed request:  0x0
  Serial number of failed request:  22
  Current serial number in output stream:  22

No idea what this means, will have to reboot to get my 2560x1440 back now :slight_smile:

I have no idea to what extent xrandr may be supported, if it is at all, when Wayland is involved. To achieve any benefit from any of my xrandr suggestions probably requires you be running a plasma-x11 session.

Note that personally I have never achieved success by supplying CVT or GTF-generated modelines that I was not able to achieve otherwise. I’m sure it’s been well over a decade since I last tried solving problems by supplying modelines via xorg.con*. I offered the suggestion because I often see others make the suggestion, and wanted my suggestions to be as complete as I could make them.

Auto input selection from Dell displays for me has been somewhat hit or miss going back more than two decades. The last one I had that kind of trouble with went stone dead at about age 5. The two in current use mostly only get used with DVI input from one PC on one and DVI input on the other from a large collection of test PCs variously using or not a HDMI/DVI adapter.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.