Bug 28772

Summary: After 8 migration, error opening a plasma session with an external display connected
Product: Mageia Reporter: Antonio Pessoa <a.pessoa>
Component: Release (media or process)Assignee: KDE maintainers <kde>
Status: NEW --- QA Contact:
Severity: minor    
Priority: Normal CC: fri, rolfpedersen, sysadmin-bugs
Version: 8   
Target Milestone: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Source RPM: kwin-5.20.4-3.mga8.src.rpm CVE:
Status comment:
Attachments: Screen ok
Screenshot corrupted
Screenshot enlightenment
Xorg.0.log opening a session and after connect the external screen
Xorg.0.log connect the external screen then open the session

Description Antonio Pessoa 2021-04-13 11:26:29 CEST
Description of problem:
After a successful migration from 7.1 to 8, I have this problem. 
If I open the session with an external monitor connected there are some problems: no mageia menu, no panels, the size of the icons is not the one chosen, no background picture. The context menu is correct, the rest looks correct.
If I open the session without a monitor connected, and after the opening I connect the external monitor, everything works normally.
The test with a new user created with version 8 gives the same result.

Version-Release number of selected component (if applicable):
Mga 8

How reproducible:
Every time I open a session after having connected an external monitor

Steps to Reproduce:
1. boot or logout the current session
2. connect an external monitor
3. log in a new session
Rolf Pedersen 2021-04-13 15:54:07 CEST

CC: (none) => rolfpedersen

Comment 1 Lewis Smith 2021-04-13 22:10:32 CEST
Thank you for the report.
In order to tell us something about your system, please post the output of:
 $ inxi -MSGxx

Can we take it that this did not happen before the upgrade from M7 to M8?

What happens if, with the corrupt external monitor display, you (first power it off) disconnect it; and re-connect it (and power it on)? Does it stay corrupted, or correct itself?

Assuming the external monitor is additonal to the normal one, are you able to attach screenshots (with the external monitor already connected at start) of:
- The normal screen
- the external monitor [showing its corruption]

Please also attach /var/log/Xorg.0.log of such a corrupted session (external monitor pre-connected).
And the same file from a session where you connect the external monitor after the system is running - after connecting it [display correct].
If the files are large, copy them, then compress those with 'xz' before attaching them to the bug, like:
 $ cp /var/log/Xorg.0.log xlog.txt
 $ xz xlog.txt                     [creates xlog.txt.xz, to attach]

Status: NEW => NEEDINFO
CC: (none) => lewyssmith

Comment 2 Lewis Smith 2021-04-13 22:12:34 CEST
I forgot to ask also: do you have another desktop than Plasma, to try that also? To identify whether the problem is Plasma, or wider.
Morgan Leijström 2021-04-13 22:56:04 CEST

CC: (none) => fri

Comment 3 Antonio Pessoa 2021-04-14 11:29:12 CEST
Created attachment 12620 [details]
Screen ok
Comment 4 Antonio Pessoa 2021-04-14 11:30:15 CEST
Created attachment 12621 [details]
Screenshot corrupted
Comment 5 Antonio Pessoa 2021-04-14 11:30:52 CEST
Created attachment 12622 [details]
Screenshot enlightenment
Comment 6 Antonio Pessoa 2021-04-14 11:32:03 CEST
Created attachment 12623 [details]
Xorg.0.log opening a session and after connect the external screen
Comment 7 Antonio Pessoa 2021-04-14 11:32:52 CEST
Created attachment 12624 [details]
Xorg.0.log connect the external screen then open the session
Comment 8 Antonio Pessoa 2021-04-14 11:42:52 CEST
Hi
First of all, thank you all for your efforts.

> post the output of:  $ inxi -MSGxx
(sorry I don't know how to format it)

$ inxi -MSGxx
System:    Host: localhost Kernel: 5.10.27-desktop-1.mga8 x86_64 bits: 64 compiler: gcc v: 10.2.1 Desktop: KDE Plasma 5.20.4 
           tk: Qt 5.15.2 wm: kwin_x11 dm: SDDM Distro: Mageia 8 mga8 
Machine:   Type: Laptop System: TOSHIBA product: PORTEGE R930 v: PT330E-01Y00GFR serial: <superuser required> Chassis: 
           type: 10 v: Version 1.0 serial: <superuser required> 
           Mobo: TOSHIBA model: PORTEGE R930 v: Version A0 serial: <superuser required> BIOS: TOSHIBA v: Version 6.80 
           date: 06/25/2013 
Graphics:  Device-1: Intel 3rd Gen Core processor Graphics vendor: Toshiba driver: i915 v: kernel bus ID: 00:02.0 
           chip ID: 8086:0166 
           Device-2: Sunplus Innovation TOSHIBA Web Camera - HD type: USB driver: uvcvideo bus ID: 1-1.3:3 chip ID: 1bcf:288e 
           Display: x11 server: Mageia X.org 1.20.10 compositor: kwin_x11 driver: intel,v4l resolution: 2560x1080~60Hz 
           s-dpi: 96 
           OpenGL: renderer: Mesa DRI Intel HD Graphics 4000 (IVB GT2) v: 4.2 Mesa 21.0.1 compat-v: 3.0 direct render: Yes

> Can we take it that this did not happen before the upgrade from M7 to M8?
Yes, I never noticed that kind of problem before the upgrade

> What happens if, with the corrupt external monitor display, you (first power it off) disconnect it; and re-connect it (and power it on)? Does it stay corrupted, or correct itself?
I did exactly the steps you mention in this order, and no change, it stays corrupted

> Assuming the external monitor is additonal to the normal one, are you able to attach screenshots (with the external monitor already connected at start) of:
> - The normal screen
> - the external monitor [showing its corruption]

Yes it is, it's a quite large screen. I attached a screenshot of this screen when it's ok (if I plug it after the session opening) and when it's corrupted (connect before opening the session).

> Please also attach /var/log/Xorg.0.log 
I attached the two files 

> I forgot to ask also: do you have another desktop than Plasma, to try that also? 
I tried enlightenment and attached the screenshot in the same situation where plasma gets corrupted. I don't know much enlightenment, but it seems ok to me, so no problem with another desktop than plasma.

Thanks a lot for your help. 
Please feel free to ask for some more information.
Comment 9 Lewis Smith 2021-04-14 21:21:08 CEST
Thank you for all the information asked for. The screenshots make the picture clear (sic).

Enlightenement is a 'window manager', not a desktop like Plasma, XFCE etc. No matter, the comparison is interesting. You did not say what situation its screenshot was taken from (external screen; connected before or after session start). It is unfamiliar to me, but may be correct. If it *is* correct, and is of the 'bad case': external monitor, connected *before* session; this might narrow the field to kwin.
If you can easily reproduce this situation with Enlightenement: external screen connected before start, it shows a correct display; please do (for comparison with comment 8), it is already formatted:
 $ inxi -SGxx

To save others peering, the two Xorg log files are identical except that the first (comment 6, connect external screen *after* session started, display correct, comment 3) has these 3 extra lines at the end:

[  1553.367] (II) intel(0): resizing framebuffer to 1366x768
[  1567.837] (II) intel(0): resizing framebuffer to 2560x1080
[  1567.844] (II) intel(0): switch to mode 2560x1080@60.0 on HDMI1 using pipe 0, position (0, 0), rotation normal, reflection none

which are simply not present in the bad case (comment 7, external screen connected *before* starting the session, display wrong, comment 4).

I wonder whether the system journal for the bad case might show something. Need another opinion.
Comment 10 Antonio Pessoa 2021-04-14 22:19:02 CEST
Thank you for the clarification about desktop/'window manager". 
I did the Enlightenment Screenshot as when plasma gets corrupted: I first have connected the external screen  then I have opened the session. I'll try the other case for comparison tomorrow, because the screen is at my worK

I'll do:
 $ inxi -SGxx
tomorrow too 

About Xorg logs, I had a look at both but didn't noticed anything that looked strange. Since the problem seems much related to plasma, maybe errors could appear in the plasma log file instead ? I don't know if such a file exists though. 
If you need the system journal, I can get it tomorrow too.
Regards
Antonio
Comment 11 Lewis Smith 2021-04-15 09:01:45 CEST
> I did the Enlightenment Screenshot as when plasma gets corrupted:
> I first have connected the external screen  then I have opened the session
Thank you for these clarifications. For the moment, apart from the inxi output when Enlightenement is running in this situation which upsets Plasma, please add nothing more for the moment.

kwin looks a likely suspect.

Source RPM: (none) => kwin-5.20.4-3.mga8.src.rpm

Comment 12 Antonio Pessoa 2021-04-15 11:21:04 CEST
Hi Lewis,
Below the output of inxi with enlightenment

inxi -SGxx
System:
  Host: localhost Kernel: 5.10.27-desktop-1.mga8 x86_64 bits: 64
  compiler: gcc v: 10.2.1 Desktop: Enlightenment 0.24.2 dm: SDDM
  Distro: Mageia 8 mga8
Graphics:
  Device-1: Intel 3rd Gen Core processor Graphics vendor: Toshiba
  driver: i915 v: kernel bus ID: 00:02.0 chip ID: 8086:0166
  Device-2: Sunplus Innovation TOSHIBA Web Camera - HD type: USB
  driver: uvcvideo bus ID: 1-1.3:3 chip ID: 1bcf:288e
  Display: x11 server: Mageia X.org 1.20.10 compositor: enlightenment
  driver: intel,v4l resolution: 1: 1366x768~60Hz 2: 2560x1080~60Hz s-dpi: 96
  OpenGL: renderer: Mesa DRI Intel HD Graphics 4000 (IVB GT2)
  v: 4.2 Mesa 21.0.1 compat-v: 3.0 direct render: Yes

Thank you very much
Regards
Antonio
Comment 13 Antonio Pessoa 2021-04-15 11:22:17 CEST
By the way, with enlightenment there is no difference between opening the session before or after having connected the external display.
Thank you, have a good day
Comment 14 Lewis Smith 2021-04-15 20:50:28 CEST
Thank you for the last information ; and for your patience in providing it all.

Assigning this to the KDE team, since the problem seems to be kwin related.

CC: lewyssmith => (none)
Status: NEEDINFO => NEW
Assignee: bugsquad => kde