32

I have installed ubuntu 20.04 on my laptop specification are intel i3 6th gen with intel graphics card 520,screen resolution 1366×768. when i lock desktop to temporarily turn off the screen but when i press power button to wakeup the screen my screen flickers continuously, this issue occurs only when locking the desktop or when screen goes off automatically. I had same issue with ubuntu 18.04 version and kali linux. But when i downgrade ubuntu to 16.04 it was running fine and same with kali linux when i installed slightly older version of kali linux it was also running fine. I am having this issue with only newer versions of ubuntu and kali linux. I have tried solution of 1)reducing screen size 2)installing older kernels

And also when i installed ubuntu 20.04 on my friends laptop it was also running fine in his laptop, specs are i5 8th gen nvidia graphics card,screen resolution 1920×1080

  • I started experiencing screen flickering issues after I installed exodus desktop app[https://www.exodus.com/download/] – lordvcs Jul 07 '21 at 12:05
  • I personally only get this issue when I boot with one monitor and then add another. When I boot with two monitors it is fine. My config: Ubuntu 21.04 on Xorg using Intel CometLake-U GT2 [UHD Graphics]. Two monitors in total, resolution 1920x1080 each. – Johannes Lemonde Aug 05 '21 at 09:27
  • I don't have the reputation to add an answer, but adding GRUB_CMDLINE_LINUX_DEFAULT="quiet splash i915.enable_psr=0" on a Matebook and GRUB_CMDLINE_LINUX="i915.enable_dc=0 intel_idle.max_cstate=2" on a lenovo yoga 9i to /etc/default/grub fixed problems for me. Run 'sudo update-grub' and restart to check the results. – firescar96 Sep 13 '22 at 18:24

8 Answers8

18

I also had the same problem with a fresh install of Ubuntu 20.04 on my desktop with Intel Corporation UHD Graphics 630 graphic card and 2 Iiyama North America 27'' screens (see the attached image to have a feeling of the flickering I was experiencing).

My problem has been solved simply (thanks to Daniel Van Vugt) by using Wayland display server on the logging screen: Click your profile > Click the white wheel in lower right corner > Choose 'Ubuntu on Wayland'.

This change replaces the use of the xorg display server which seems to make a lot of arguing on the web. I have to admit that explaining exactly why this solves the problem is a bit out of my league, but I let this to other Linux experts in the community. You can also find deeper technical explanations of xorg/wayland by following these links:

Pablo Bianchi
  • 15,657
jerem2401
  • 316
  • 2
  • 6
  • 1
    This answer helped me to solve another issue where the screen was flickering as soon as an external VGA display was connected to the laptop. Xorg failed to manage this use case while Wayland worked just fine. HP laptop 6730b + Mobile Intel Graphics Media Accelerator 4500MHD + Ubuntu 20.04. – Joël Esponde Oct 14 '20 at 21:14
  • I am commenting and bookmarking just so I can update tomorrow. But for the last 15 minutes, there has been no problem with the screen. – lllrnr101 Apr 15 '21 at 15:52
  • 1
    I switched to Wayland and the problem was solved for a couple of days. But now it's back. What should I do? – Amirhosein Al Apr 27 '21 at 06:42
  • I switched to Wayland a few minutes ago and have already seen a flicker to black. – Ryan Jul 23 '21 at 16:02
  • In my case the flickering disappeared as soons as Wayland was activated. But of course, screen sharing is not supported by Microsoft Teams if Wayland activated. Too bad. – Rudy Vissers May 02 '22 at 14:18
  • @RudyVissers which Teams version are you using (3 dots in upper right corner > about > version)? Because for me on version 1.4.00.26453 (64-bit) I have no issue with screen sharing. – jerem2401 May 03 '22 at 15:11
11

Try this one it could help you out: flickering screen ubuntu 18.04.1 LTS

Create an empty file anywhere using right-click menu. Name it 20-intel.conf Open it using any text editor (like Gedit, Mousepad etc.) and add the following lines:-

Section "Device"

Identifier "Intel Graphics"
Driver "intel"
Option "AccelMethod" "sna"
Option "TearFree" "true"

EndSection

Now save the file. Open your file manager with root privilege (sudo -i nautilus for Ubuntu). Paste the file in /etc/X11/xorg.conf.d Create the requisite folders if they don’t exist. Restart the system after it’s done.

If you experience issues like pixelated graphics, corrupt text, etc. after this, replace the word sna with uxa within the text.

  • Nael.fridhi, i have tried this option it's not working for me !! I have tried options 1) reducing screen refresh rate 2) changing kernals i have tried this all but none of them is working i had same issue with ubuntu 18.04 and kali linux newer version but when i downgrade ubuntu to 16.04, then it was running fine without and issues and also when i installed older version of kali linux it was also running fine, i am having this flickering issue only with newer versions of ubuntu and kali – Rahul barate Apr 26 '20 at 16:08
  • 1
    perfect! I had issues of flickering and cut off windows (on dragging) , also a strange diagonal cut in chrome browser while scrolling down. This just fix it all. Thanks.

    Ubuntu 20.04 on Lenovo YOGA 910.

    – shmulik.r Apr 30 '20 at 20:24
  • I have a brand new Lenovo Thinkpad E15 with Ubuntu 20.04 dual-boot with Windows 10. It frequently flickers to black on my external USB-C monitor. Settings > About > Graphics shows "Mesa Intel® Xe Graphics (TGL GT2)". My /etc/X11/ directory existed. Then cd /etc/X11/ && sudo mkdir xorg.conf.d && cd xorg.conf.d && sudo vim 20-intel.conf and pasted your lines from above and save. Now I will restart and see whether flickering still sometimes happens. – Ryan Jul 23 '21 at 16:37
  • Unfortunately, it just flickered to black again. I'll also mention that I'm using Ubuntu Wayland as the display server (chosen during logon). I wonder if USB-C is the problem; I'll try using this same Dell U4320Q monitor with HDMI instead. – Ryan Jul 23 '21 at 16:44
  • Now nothing is plugged into the USB-C port, and I'm using HDMI instead. There seems to be less flickering, but when watching YouTube just now, it started flickering frequently. So the USB-C port or cable is not the problem. – Ryan Jul 23 '21 at 18:10
  • in Ubuntu 20.04 the folder for xorg.conf.d is: /usr/share/X11/xorg.conf.d/ – Gab Feb 23 '22 at 06:46
  • This worked in Ubuntu 18, thanks man! – Omar Dulaimi Aug 29 '22 at 09:05
  • Interestingly it fixed the problem but caused Skype to show weird dark-grey horizontal bars with rough edges, which is kinda distracting but less of a problem than not being able to watch YouTube for more than three seconds without it showing the frame from a second ago for a split-second. – Lampe2020 Oct 01 '23 at 17:22
  • Addition two hours later: I commented all the changes I made out again (Skype got buggier and buggier with each second it ran) but the problem with video playback on the second screen is gone, so I'll gladly take it but if a problem fixes itself it may unfortunately also appear again out of thin air at any time. – Lampe2020 Oct 01 '23 at 19:33
4

Changes on x11 parameters do not work. What works for me is to change the rasterization settings in chrome. Open the flags page in chrome: chrome://flags, then change the "GPU rasterization" flag to "enable". To be redone after each chrome update.

kik
  • 41
4

I was experiencing a continuous small-intensity flickering after a clean install of Xubuntu 20.04 on my laptop (nvidia-driver-455 installed from the graphics-drivers ppa). I think I have solved it by applying the settings below in NVIDIA X Server Settings (toggle first the Advanced view) and clicking Save to X Configuration File. Hopefully, it can be of help. enter image description here

Patol75
  • 141
  • 3
1

I had the same problem, but in my case I went to boot menu, I selected the same drive containing my ubuntu OS, then selected ubuntu boot advanced option, chose repair packages. This fixed the whole flickering issue.

1

I installed Xubuntu 20.04 on two seemingly identical Compaq CQ60 laptops, and it worked flawlessly on one of them. The second laptop had a flickering screen problem right away. I tried reinstalling, changing the resolution and refresh rate, using the Nvidia third party driver (even worse), installing gnome desktop, changing to Wayland vs Xorg, and nothing worked. Once my screen started flickering, I usually had to reboot.

The last thing I tried appears to have fixed the problem… Assuming these AMD Sempron laptops with 3GB of memory are very low on resources, I turned off the compositor by navigating to Settings Manager, Windows Manager Tweaks and unchecking Enable Display Compositing. So far, a week later, I have had no further problems.

0

In my case, switching to Wayland (on log-on screen) solved the problem completely.

Then again, as I use a USBC - HDMI adapter, I tried another Adapter (original Apple instead of the generic one I use) and there was no flickering whatsoever with either (nor XORG nor Wayno).

0

In my case, I realized i got the problem only when my computer was running on battery. Plugging my computer to the electrical socket solved my problem

Matt Dnv
  • 121