'Sticky' or lagging windows after a few days of uptime

Has anyone experienced windows sort of ‘sticking’ or lagging when dragging after a few days of uptime?

I have a laptop and workstation with new Fedora 37 installs, it only happens on my workstation after 2-3 days of uptime I start noticing there’s a slight lag when clicking on a window, then dragging it. No lag after that initial ‘stick’ when swirling the window around. It gets progressively worse the longer the uptime. It doesn’t happen on my Windows partition, so I don’t think it’s hardware related.

5700x, ASUS B550-A, RX 6700 XT, Asus ThunderboltEX 4

At first I thought maybe something bonked on my system, so I freshly installed Fedora (Previously Arch). Nothing special about the install, a few extensions that are also used on my laptop. Tried not using the Thunderbolt card and directly connecting everything to the system and monitor directly to the GPU… shows up a few days later. Tried turning off adaptivesync on my monitors, didn’t make a difference. Tried turning off extensions, still there.

If I sign out and back in, the lag is gone. I’m at a loss of what to try now.

Look for some process that is using a lot of resources.
Do you have a CPU bound process?
Do you have a process using lots of memory and forcing swapping?
Use free -h to check swap use and top to fi d memory and cpu issues.
Maybe a web browser with lots of open tabs?

Hi, nothing using up the CPU.

No SWAP being used, I have 64GB of memory on this workstation so lots of room. All programs closed, but the ‘stickiness’ persists. Even if the system is restarted and left to idle without opening anything for a few days, it’ll start ‘sticking’.

I don’t think it’s insufficient resources as this isn’t happening to my laptop with much worse specs, almost exactly the same Fedora install, all the same programs and apps installed on both machines.

Which desktop software are you using?

Hi, I’m using Gnome

I’m bringing this back up again because I’ve found two things.

My workstation has 7 days uptime now on xorg, no more stutter.

This started happens on my laptop running Fedora Gnome Wayland, noticed it around 7-8 days uptime, it never happened when I was running Arch. I installed Fedora on the laptop right around when I did for my workstation, so it has very similar programs installed. Same ‘fix’ - I sign out and back in, the stutter/lag is gone.

Now that is has happened on a second machine, I can definitely rule out hardware issues… how can I try and figure out what’s happening?

I was running a number of programs on the laptop, but only 70% memory usage. After closing everything possible, turning off extensions, etc, the stutter continued until I logged out and back in.

2 Likes

Did you check for processes using high cpu?
What does top show when this happens?

Did you check dmesg it see if the kernel reported any issues?

Hi, left my laptop on for a week and the issue is very apparent now.

No obvious dmesg messages, should I post any logs that could narrow it down?

No high CPU usage on top at all.

    PID USER      PR  NI    VIRT    RES    SHR S  %CPU  %MEM     TIME+ COMMAND                                                                                 
 154775 nn        20   0 6110516 893248  88148 S   6.0   5.5  95:23.43 gnome-shell                                                                             
 177245 nn        20   0 5835496 761652 249600 S   4.0   4.7  97:45.76 firefox                                                                                 
 387567 nn        20   0 2836412 228696 104892 S   4.0   1.4   0:11.12 Isolated Web Co                                                                         
 387754 nn        20   0  803996  83348  52072 S   1.3   0.5   0:02.08 terminator                                                                              
 317043 nn        20   0 3438424 422204 114620 S   1.0   2.6  10:11.83 Isolated Web Co                                                                         
   1139 root      20   0    9776   5316   4112 S   0.3   0.0   4:48.90 bluetoothd                                                                              
   1187 root      20   0  456208   9084   8372 S   0.3   0.1   3:39.80 thermald                                                                                
 177448 nn        20   0   19.1g 230284 106996 S   0.3   1.4   6:32.97 WebExtensions                                                                           
 251064 nn        20   0   32.5g  21972  20916 S   0.3   0.1   0:02.99 @joplinapp-desk                                                                         
 274920 nn        20   0 3037668 253560 106900 S   0.3   1.6   2:44.62 Isolated Web Co                                                                         
      1 root      20   0  172636  12836   8644 S   0.0   0.1   0:16.52 systemd                                                                                 
      2 root      20   0       0      0      0 S   0.0   0.0   0:00.47 kthreadd                                                                                
      3 root       0 -20       0      0      0 I   0.0   0.0   0:00.00 rcu_gp                                                                                  
      4 root       0 -20       0      0      0 I   0.0   0.0   0:00.00 rcu_par_gp                                                                              
      5 root       0 -20       0      0      0 I   0.0   0.0   0:00.00 slub_flushwq      

That’s just on idle with firefox and thunderbird on. I tried quitting all problems like before and turning off all gnome extensions… the issue persists.

What is this joplinapp process?
Its using lots of virtual memory.
Is that process using less memory when you reboot and start again?

That was a grab from when I was using the laptop normally, it’s a note taking app.

Here is top from just now, after I quit all programs running and disabled extensions. Only Firefox and terminator are running (quit and re-opened to make this post)

The problem still persists after quitting everything.

    PID USER      PR  NI    VIRT    RES    SHR S  %CPU  %MEM     TIME+ COMMAND                                  
 154775 nn        20   0 6137000 932192  74328 S  14.0   5.8  99:18.30 gnome-shell                              
   1299 root     -51   0       0      0      0 S   6.0   0.0   9:22.62 irq/145-rmi4_smbus                       
 396895 nn        20   0 2832828 215140 104328 S   4.3   1.3   0:10.12 Isolated Web Co                          
 396587 nn        20   0 3599328 428096 206944 S   4.0   2.7   0:17.58 firefox                                  
 396411 nn        20   0  797576  77216  47616 S   2.7   0.5   0:01.26 terminator                               
   1139 root      20   0    9776   5444   4240 S   0.7   0.0   4:51.40 bluetoothd                               
   1110 systemd+  20   0   16416   6972   6780 S   0.3   0.0  13:30.96 systemd-oomd                             
 154999 nn        20   0  528576  10040   6668 S   0.3   0.1   0:41.64 ibus-daemon                              
 155134 nn        20   0  708028  30008  27988 S   0.3   0.2   0:00.79 flameshot                                
 391856 root       0 -20       0      0      0 I   0.3   0.0   0:01.28 kworker/u17:0-hci0                       
 394088 root      20   0       0      0      0 I   0.3   0.0   0:00.04 kworker/1:1-events                       
 395354 root      20   0       0      0      0 I   0.3   0.0   0:00.24 kworker/0:2-events                       
 395561 root       0 -20       0      0      0 I   0.3   0.0   0:00.24 kworker/u17:1-i915_flip                  
 396572 nn        20   0  225064   3840   2944 R   0.3   0.0   0:00.31 top                                      
      1 root      20   0  172636  13092   8900 S   0.0   0.1   0:16.68 systemd       

Can you include the header of top that shows cpu and memory usage please?

Hi, here you go

top - 12:47:55 up 20 days, 17 min,  1 user,  load average: 1.07, 0.50, 0.32
Tasks: 348 total,   1 running, 346 sleeping,   0 stopped,   1 zombie
%Cpu(s):  0.4 us,  1.0 sy,  0.0 ni, 98.3 id,  0.1 wa,  0.2 hi,  0.0 si,  0.0 st
MiB Mem :  15741.9 total,   5795.9 free,   3329.8 used,   6616.2 buff/cache
MiB Swap:   8192.0 total,   6508.3 free,   1683.7 used.  11882.1 avail Mem 

    PID USER      PR  NI    VIRT    RES    SHR S  %CPU  %MEM     TIME+ COMMAND                                  
   1299 root     -51   0       0      0      0 D   5.6   0.0   9:27.52 irq/145-rmi4_smbus                       
 154775 nn        20   0 6123832 929880  67076 S   3.0   5.8 100:35.79 gnome-shell                              
   1110 systemd+  20   0   16416   6972   6780 S   0.3   0.0  13:33.37 systemd-oomd                             
   1139 root      20   0    9776   5444   4240 S   0.3   0.0   4:52.69 bluetoothd                               
   1187 root      20   0  456208   9084   8372 S   0.3   0.1   3:43.18 thermald                                 
 157451 nn        20   0  796008  31580  29032 S   0.3   0.2   1:46.18 vmware-tray                              
 399578 nn        20   0  797252  76940  47228 S   0.3   0.5   0:00.93 terminator                               
      1 root      20   0  172636  13092   8900 S   0.0   0.1   0:16.71 systemd                                  
      2 root      20   0       0      0      0 S   0.0   0.0   0:00.48 kthreadd                                 
      3 root       0 -20       0      0      0 I   0.0   0.0   0:00.00 rcu_gp                                   
      4 root       0 -20       0      0      0 I   0.0   0.0   0:00.00 rcu_par_gp                               
      5 root       0 -20       0      0      0 I   0.0   0.0   0:00.00 slub_flushwq                             
      6 root       0 -20       0      0      0 I   0.0   0.0   0:00.00 netns      

Your system did ru out if memory at some point.
You can see that swap has been used.

I might be that your systems starts slowing down when swap starts being used.
A small amount of swap is not an issue, but lots of swap will make your system slow.

That note taking app using 32GiB virtual on a 16GiB system does look bad to me.

Yes, if I have lots of firefox windows, it’ll start going into swap before actual memory runs out. that’s normal.

So the question still remains, after I close all applications and free up memory, why does the sticking issue persist? It’s not a slow system, it’s just windows have a stutter or stale when I start to drag them, after that initial stutter, it’s fine.

The only way to reproduce this is to leave my system idling, so it’s a factor of time, doesn’t seem like a high cpu/high memory issue.

Edit : Like I also said previously, it only happens on Wayland. If I switch to xorg, it no longer happens. Yes, that’s a workaround, but I’d like to figure out why it only happens on wayland.

I’m having what may be the same problem, it’s noooooooooooooot yet clear from the description. In my case, everything on the system is exhibitingggggggggggggggggggggggggggggggg “micro-freezes”, right down to theeeeeeeeeeeeeeeeee input level — like, those repeated characters (which I’d normally delete) are the result of one of those freezes hitting wwwwwwwwwwwwwwwwwwwhile I’m typing; if there’s a key down during the freeze, the system interppppppppppppppppprets it as me holding down the key for the length of the freeze. The display output is also completely static for the length of the freeze, including the mouse pointer. The freezes don’t occur with annnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnny set timing, it can be anywhere from under a second to several seconds between them.

There’s no sign in the dmesg output, or in anyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy of the journals (system or user) that anything odd is going on. If I have a video playing in VLC, and open its Messages window with the verbosity set to Warnings, each freeze will be accompanied by a flurry of these messages:

main warning: picture is too late to be displayed (missing nn ms)

But other than the visible freezes and repeated characters, that’s the only indication the system is even noticing these “time-skips”.

This would happen occasionally under F37, but only seemed to crop up with load so I assumed it was a swap/context-switch issue. (My machine isn’t particularly new or fast.) But now unnnnnnnnnnnnnnnnnnnnder F38 it’s a constant thing, even on a completely unloaded system immediately after startup.

I posted this as a separate thread, as well, but I wanted to throw it out there in case it’s a similar / related issue. I’m running on an El Cheapo Nvidia GT 710 GPU, using nouveau on Wayland. I haven’t tried Xorg yet, to see if it occurs there as well.

My GPU will occasionally “freak out” and dump a storm of errors into dmesg (it doesn’t seem to be perfectly supported under nouveau), but this issue isn’t predicated on that happening and doesn’t seem to be directly related.

Actually, I take that back. Sometimes (but far from every time), a typing freeze will result in a bunch of these messages in my user journal:

May 10 13:40:38 gnome-shell[131259]: Key repeat discarded, Wayland compositor doesn’t seem to be processing events fast enough!

So, there is some indication, and it seems Wayland is being fingered as the culprit.