Leap 15.4 laptop display is black but external shows up

at one point the laptop was configured to have an external monitor and now with the upgrade to 15.4 few weeks ago i encounter this problem which i remember that i have seen it before maybe with 15.3, not important. couldn’t find any settings to change it so i assume is a driver.
currently display is dark (device 1 and monitor 1)and external monitor is working:


sudo inxi -Ga 
**Graphics:**
  **Device-1:** Intel Haswell Integrated Graphics **vendor:** Lenovo **driver:** i915 **v:** kernel 
    **arch:** Gen-7.5 **process:** Intel 22nm **built:** 2013 **ports:****active:** VGA-1,eDP-1 **empty:** HDMI-A-1 
    **bus-ID:** 00:02.0 **chip-ID:** 8086:0406 **class-ID:** 0300 
  **Device-2:** Acer Lenovo Integrated Webcam **type:** USB **driver:** uvcvideo **bus-ID:** 2-5:3 
    **chip-ID:** 5986:0295 **class-ID:** 0e02 
  **Display:****server:** X.org **v:** 1.20.3 **with:** Xwayland **v:** 21.1.4 **compositor:** kwin_wayland 
    **driver:****X:****loaded:** modesetting **unloaded:** fbdev,vesa **alternate:** intel **gpu:** i915 **tty:** 95x16 
  **Monitor-1:** VGA-1 **model:** Lenovo L1951p Wide **serial:** 6V6FW429 **built:** 2010 **res:** 1440x900 
    **dpi:** 90 **gamma:** 1.2 **size:** 408x255mm (16.06x10.04") **diag:** 481mm (18.9") **ratio:** 16:10 **modes:**
    **max:** 1440x900 **min:** 720x400 
  **Monitor-2:** eDP-1 **size-res:** N/A in console **modes:** 1024x768 
  **Message:** GL data unavailable in console for root. 

xrandr --listproviders --listmonitors  
Providers: number : 0 
Monitors: 2 
 0: +*XWAYLAND1 1440/410x900/260+1024+0  XWAYLAND1 
 1: +XWAYLAND2 1024/271x768/203+0+0  XWAYLAND2


any suggestions appreciated. thank you for your time

Inxi -Ga information is incomplete unless run from within an X session.

From within Plasma, does Ctrl-Alt-F3, then Alt-F7 light up both displays?

From Konsole in your X session, does xrandr --output eDP-1 --auto change anything? What about xrandr --output eDP-1 --primary?

Does the problem remain if you run Plasma in an Xorg session instead of Wayland?

Install if necessary, then run xdriinfo from Konsole. Which does it report i965, or crocus?

The next kernel update, due soon, is expected to solve multiple graphics troubles.

Plasma is fraught with multiple problems with multiple displays that upstream is currently working to solve, and should show up in TW before very long, but won’t make 15.4 without enabling optional repo repositories/KDE:/Frameworks5. On mine, I disable KScreen 2 in systemsettings5 startup, then configure displays as required via xrandr and/or arandr.

here are my answers. thank you

it was executed from an Xsession[/quote]GL data unavailable in console for root is a message inxi -Ga provides when run from a vtty (aka console). Unless and until you run it without getting this message, and show us that output, we may be missing information we need to help us help you.

# inxi -Gaz
Graphics:
  Device-1: Intel 4th Generation Core Processor Family Integrated Graphics
    vendor: Micro-Star MSI driver: i915 v: kernel arch: Gen-7.5
    process: Intel 22nm built: 2013 ports: active: HDMI-A-1,HDMI-A-2
    empty: VGA-1 bus-ID: 00:02.0 chip-ID: 8086:041e class-ID: 0300
  Display: x11 server: X.Org v: 21.1.4 driver: X: loaded: modesetting
    unloaded: fbdev,vesa alternate: intel dri: crocus gpu: i915 display-ID: :0
    screens: 1
  Screen-1: 0 s-res: 3840x1200 s-dpi: 120 s-size: 812x254mm (31.97x10.00")
    s-diag: 851mm (33.5")
  Monitor-1: HDMI-A-1 mapped: HDMI-1 pos: primary,left
    model: Samsung SMS24A850 serial: <filter> built: 2012 res: 1920x1200 hz: 60
    dpi: 94 gamma: 1.2 size: 518x324mm (20.39x12.76") diag: 611mm (24.1")
    ratio: 16:10 modes: max: 1920x1200 min: 720x400
  Monitor-2: HDMI-A-2 mapped: HDMI-2 pos: right model: NEC EA243WM
    serial: <filter> built: 2011 res: 1920x1200 hz: 60 dpi: 94 gamma: 1.2
    size: 519x324mm (20.43x12.76") diag: 612mm (24.1") ratio: 16:10 modes:
    max: 1920x1200 min: 640x480
  OpenGL: renderer: Mesa Intel HD Graphics 4400 (HSW GT2) v: 4.6 Mesa
    22.2.0 direct render: Yes

[quote]Does the problem remain if you run Plasma in an Xorg session instead of Wayland?

not sure how to do this[/quote]On your SDDM or LightDM login screen there is a place to select session type. If you have auto-login enabled, then to get there requires logging out without shutting down or rebooting.

[quote]run xdriinfo from Konsole. Which does it report i965, or crocus?
it reports i965[/quote]It’s possible a switch to crocus could help. To do so, add export MESA_LOADER_DRIVER_OVERRIDE=crocus to ~/.profile, log out, then log back in to see if it has any effect. Alternatively to ~/.profile, it can be enabled globally via /etc/X11/xinit/xinitrc.d/45-crocus.sh (new file you create, name not important, though “45” could be).

i enabled the repo for Frameworks5
I suggest it’s too soon to see improvement. You could encounter other bugs, but it’s your laptop to do with as you wish.

thank you mrmazda. it is an old laptop which i just keep using it once in a while since i had some hardware problems with it. the battery shows as not charging and i was trying to get some pictures to the manufacturer the other day when i encountered the black screen. to my surprise the battery was charging while trying to find a way for the black screen on it. i left by mistake the laptop on battery and of course this morning was drained so connecting to the cable i restarted the laptop and the black screen lit up and is working now. didn’t do anything else other than the commands you provided and maybe some updates that popped up. so now both screens are working but my battery doesn’t show as charging? i guess i will have to open a new post for that. so i have no ideea what corrected my system or more like went back to a previous state when battery was not charging and screen was working.
here is the output now(executed from my user instead of root via sudo) so few changes but it might be because the way i executed initially):


xxx@curacao:~> inxi -Gaz 
**Graphics:** 
  **Device-1:** Intel Haswell Integrated Graphics **vendor:** Lenovo **driver:** i915 
    **v:** kernel **arch:** Gen-7.5 **process:** Intel 22nm **built:** 2013 **ports:** 
    **active:** VGA-1,eDP-1 **empty:** HDMI-A-1 **bus-ID:** 00:02.0 **chip-ID:** 8086:0406 
    **class-ID:** 0300 
  **Device-2:** Acer Lenovo Integrated Webcam **type:** USB **driver:** uvcvideo 
    **bus-ID:** 3-5:3 **chip-ID:** 5986:0295 **class-ID:** 0e02 
  **Display:** wayland **server:** X.org **v:** 1.20.3 **with:** Xwayland **v:** 21.1.4 
    **compositor:** kwin_wayland **driver:** **X:** **loaded:** modesetting 
    **unloaded:** fbdev,vesa **alternate:** intel **gpu:** i915 **d-rect:** 3040x900 
    **display-ID:** 0 
  **Monitor-1:** VGA-1 **pos:** primary,left **res:** 1440x900 **size:** N/A **modes:** N/A 
  **Monitor-2:** eDP-1 **pos:** right **res:** 1600x900 **size:** N/A **modes:** N/A 
  **OpenGL:** **renderer:** Mesa DRI Intel HD Graphics (HSW GT1) **v:** 4.5 Mesa 21.2.4 
    **compat-v:** 3.0 **direct render:** Yes

the variable **MESA_LOADER_DRIVER_OVERRIDE **is empty right now. please let me know if you like to see any output which might give a clue of what happened. thank you

There are bugs lurking various places that surface to vex multiple display users, especially in Wayland, which is still rather new in terms of user acceptance. I have yet to open a Wayland session even once, among hundreds of installations.

# pinxi -Gaz
Graphics:
  Device-1: Intel 4th Generation Core Processor Family Integrated Graphics
    vendor: Micro-Star MSI driver: i915 v: kernel arch: Gen-7.5
    process: Intel 22nm built: 2013 ports: active: HDMI-A-2,VGA-1
    empty: HDMI-A-1 bus-ID: 00:02.0 chip-ID: 8086:041e class-ID: 0300
  Display: x11 server: X.Org v: 21.1.4 driver: X: loaded: modesetting
    unloaded: fbdev,vesa alternate: intel dri: crocus gpu: i915 display-ID: :0
    screens: 1
  Screen-1: 0 s-res: 3600x1200 s-dpi: 120 s-size: 762x254mm (30.00x10.00")
    s-diag: 803mm (31.62")
  Monitor-1: HDMI-A-2 mapped: HDMI-2 pos: right model: Dell P2213
    serial: <filter> built: 2012 res: 1680x1050 hz: 60 dpi: 90 gamma: 1.2
    size: 473x296mm (18.62x11.65") diag: 558mm (22") ratio: 16:10 modes:
    max: 1680x1050 min: 720x400
  Monitor-2: **VGA**-1 pos: **primary**,left model: NEC EA243WM serial: <filter>
    built: 2011 res: 1920x1200 hz: 60 dpi: 94 gamma: 1.2
    size: 519x324mm (20.43x12.76") diag: 612mm (24.1") ratio: 16:10 modes:
    max: 1920x1200 min: 640x480
  OpenGL: renderer: Mesa Intel HD Graphics 4400 (HSW GT2) v: 4.6 Mesa
    22.1.7 direct render: Yes

You should be able to note several things in common between mine and yours, among them, the VGA display is labeled “primary”. Primary is typically where apps open by default, and the default tool panel appears. It often happens that when anything occurs to make X decide only one display is attached, and one of them is VGA connected, VGA is the one it picks to keep alive.

Other than not using Wayland, I have nothing to suggest that you could do to keep it from happening again. Similar goes for if and when it happens again. If all else fails, try simply logging out then back in. First check if in desktop settings > display a second display is present. Try also arandr, which you may need to install first.

If it happens again any time soon, before logging out, do cat /var/log/Xorg.0.log | susepaste and post the resulting URI here so we can look for clues.

thank you for your reply and i will try to keep it in mind for next time it happens. i will try to learn a bit more about the arandr command(so i remember it next time). i also a bit about inxi command which helped me with my battery which for some reason gets drained with voltage less than minimum, i got the battery out and then back in and with the command inxi -Bx i was able to see that it started to charge slowly at the beginning until it got to 100%. i will have to be careful if it goes very low so as not to get to 0. appreciated your help.