Artix Linux Forum

Artix Linux => Applications & Software => Topic started by: Kintaro on 15 January 2021, 22:24:54

Title: [SOLVED] Blackscreen whe reopening the lid of a laptop during Xorg session
Post by: Kintaro on 15 January 2021, 22:24:54
Hi,
I've got a fresh install of Artix with runit, I've added dwm on that.
When I'm closing the lid of my laptop outside Xorg everything is normal when reopening it.
But when I do it within the dwm session and reopen it I've got a gray/black screen without the possibility to do anything.

I don't know how to point out the problem.
Title: Re: Blackscreen whe reopening the lid of a laptop during Xorg session
Post by: alium on 15 January 2021, 22:43:03
hi, is the system up-to-date? you not wrote which ISO you used
another DE (offcicially supported by archlinux or artixlinux) works without problem?  If they work, you may have something set up wrong.
Title: Re: Blackscreen whe reopening the lid of a laptop during Xorg session
Post by: Kintaro on 15 January 2021, 23:27:00
Yep sorry I've forgotten
I've done the installation recently with the following iso artix-base-runit-20210101-x86_64.iso.
I've not tested any DE, but I could install another WM in order to test that, I will try installing xnomad to see if the problem persist.
Title: Re: Blackscreen whe reopening the lid of a laptop during Xorg session
Post by: alium on 15 January 2021, 23:30:57
some logs would come in handy if it doesn't work in another DE either
see https://forum.artixlinux.org/index.php/topic,1923.0.html

P.S. make sure you have installed elogind 246.9.2-1
Title: Re: Blackscreen whe reopening the lid of a laptop during Xorg session
Post by: Kintaro on 16 January 2021, 00:22:06
I've fixed the error thanks to this topic

https://forum.artixlinux.org/index.php/topic,1639.msg11220.html#msg11220

The following code fixed the problem
Code: [Select]
#!/bin/sh

case "$1" in
    pre)
        /usr/bin/nvidia-sleep.sh "suspend"
        sleep 2
        ;;

    post)
        (sleep 2; /usr/bin/nvidia-sleep.sh "resume";)&
        ;;
esac

I will test without the sleep command. I don't know if it's a workaround that hide the main issue, but it seems to work ::)
Thanks