3

I'm using the latest Nvidia graphics drivers. They're working very well, but sometimes when my desktop wakes up from suspend, I get a black screen, before and/or after I log in. The screen will light up and stay black. Sometimes the issue is resolved by pressing the power button on the monitor to restart it. If it doesn't work, I have to press F1 and restart lightdm the fix it. It's very annoying and I would really like to be able to fix it. I'm currently using elementary os 0.4.1 and I have a GTX 760 (OEM). With black screen I actually mean it looks like the screen fades out, it also happens sometimes when I close a fullscreen application.

Edit: I'm sorry for the late response. In my case this was related to a problem with the monitor. When I replaced it the problem was solved. It's worth considering your monitor might be bad.

2
  • (since i can't comment I'll ask in the form of an answer, then update accordingly) Is it on a laptop or Desktop? (specifically it's very nice to know if it's actually an GTX 760M, with optimus, as that changes the situation slightly ) also, could you please post the output of: find /lib/modules/$(uname -r) -name 'nvidia*.ko*'
    – rasmus91
    Dec 22, 2017 at 10:00
  • Here is the output: /lib/modules/4.11.7-041107-generic/kernel/drivers/video/fbdev/nvidia/nvidiafb.ko /lib/modules/4.11.7-041107-generic/extra/nvidia_387.ko /lib/modules/4.11.7-041107-generic/extra/nvidia_387_uvm.ko /lib/modules/4.11.7-041107-generic/extra/nvidia_387_drm.ko /lib/modules/4.11.7-041107-generic/extra/nvidia_387_modeset.ko And I'm on a desktop.
    – Danacus
    Dec 22, 2017 at 10:57

2 Answers 2

1

I had this problem not only with elementaryOS, but with Lubuntu as well. Its a driver problem.

Do not use the nvidia drivers included in the AppCenter, this is a known bug that happens with the legacy drivers included in most LTS variations of Ubuntu.

To fix just update your drivers using nvidia's driver repo.

sudo apt-get purge nvidia*

sudo add-apt-repository ppa:graphics-drivers
sudo apt-get update

Check your Graphics cards for a compatible Driver, for example, my GPU is Nvidia GeForce GTX 1050, so it's compatible with the Latest Short Lived branch which is nvidia-396 as the date this answer was originally written.

sudo apt-get install nvidia-XXX

For Elementary OS 5.0 (and other distros based on 18.04 LTS) the package name changed:

sudo apt-get install nvidia-driver-XXX

Replace XXX with the version your GPU is compatible with. The latest, the better.

Restart, the problem should be fixed.

Sources:

5
  • the final command wasn't working for me, but it worked when I replaced it with sudo apt-get install nvidia-driver-xxx
    – Bruno E
    Feb 10, 2020 at 13:31
  • Yes, AFAIK they changed to that naming convention from 18.xx onwards.
    – Gabriel I.
    Feb 12, 2020 at 14:58
  • did you guys were able to solve the black screen problem? Jan 27, 2021 at 18:55
  • It did not fix the black screen for me @ThiagoDias
    – Ceros
    Mar 8, 2022 at 13:58
  • same, I ended up switching to another distro. I'm currently using Fedora with gnome Mar 8, 2022 at 16:44
0

I have disabled the suspend option. Now if I leave the laptop on and don't do anything it will go to sleep after 15 min and asks for the password when woke up. After some idle time, the display will be turned off. Which is not the same as suspend I guess. I think suspend option in Linux systems is not the same as the sleep option in windows. I'm using elementary OS 6.0 ODIN

1
  • Disabling suspend will prevent the laptop from going into sleep mode, which means the CPU will stop and state will be stored to RAM. This is like sleep on Windows I think. However, there are other things that can happen: - Display Power Management Signaling (DPMS) may decide to turn of the screen. - The Desktop Environment may decide to lock the screen. This is not the same as suspend, the laptop will still be running. The lock screen will just be enabled and the display will be turned off. I think this is what's still happening in your case.
    – Danacus
    Aug 25, 2021 at 7:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.