[nvidia] gnome-shell freezes randomly with "Window manager warning: MetaSyncRing: Sync object is not ready -- were events handled properly?"

Bug #1912246 reported by Ian Johnson
22
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Mutter
Fix Released
Unknown
mutter (Ubuntu)
Fix Released
High
Unassigned
Hirsute
Fix Released
High
Unassigned

Bug Description

I recently upgrading from Focal to Groovy, and use proprietary NVIDIA drivers with X11 with otherwise standard GNOME, but some extensions installed. I see frequently errors relating to the dash-to-dock extension which I'm not sure are related, but I also see that gnome-shell freezes up for a minute or so, and the logs have this to say: https://pastebin.ubuntu.com/p/trWJZfZ77Z/

BTW this is the error from the dash-to-dock extension if relevant:

Jan 18 07:50:24 gnome-shell[10186]: == Stack trace for context 0x565369c02220 ==
Jan 18 07:50:24 gnome-shell[10186]: #0 7ffc8e0a3c00 I /<email address hidden>/docking.js:2036 (e02dce21a0 @ 208)
Jan 18 07:50:24 gnome-shell[10186]: Object St.Bin (0x56537221ac80), has been already deallocated — impossible to set any property on it. This might be caused by the object having been destroyed from C code using something such as destroy(), dispose(), or remove() vfuncs.

however that seems to be an issue reported upstream at https://github.com/micheleg/dash-to-dock/issues/1360

ProblemType: Bug
DistroRelease: Ubuntu 20.10
Package: gnome-shell 3.38.1-1ubuntu1.1
ProcVersionSignature: Ubuntu 5.8.0-38.43-generic 5.8.18
Uname: Linux 5.8.0-38-generic x86_64
NonfreeKernelModules: zfs zunicode zavl icp zcommon znvpair nvidia_modeset nvidia
ApportVersion: 2.20.11-0ubuntu50.3
Architecture: amd64
CasperMD5CheckResult: skip
CurrentDesktop: ubuntu:GNOME
Date: Mon Jan 18 09:51:15 2021
DisplayManager: gdm3
InstallationDate: Installed on 2019-07-05 (563 days ago)
InstallationMedia: Ubuntu 19.04 "Disco Dingo" - Release amd64 (20190416)
ProcEnviron:
 TERM=xterm-256color
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=en_US.UTF-8
 SHELL=/bin/bash
RelatedPackageVersions: mutter-common 3.38.1-2ubuntu1
SourcePackage: gnome-shell
UpgradeStatus: Upgraded to groovy on 2021-01-16 (2 days ago)

Revision history for this message
Ian Johnson (anonymouse67) wrote :
description: updated
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

The error you mention is bug 1905519, but let's assume that's a different problem to the main freeze here...

Please start by uninstalling all of these extensions:

'<email address hidden>',
'<email address hidden>',
'<email address hidden>',
'<email address hidden>',
'freon@UshakovVasilii_Github.yahoo.com',
'snap-manager@fthx'

Eliminating extensions from the equation is the first thing we need to try because extensions cause so many bugs.

Changed in gnome-shell (Ubuntu):
status: New → Incomplete
Revision history for this message
Ian Johnson (anonymouse67) wrote :

Hi Daniel, I disabled all of these extensions, and then rebooted the machine and still a minute or two after logging in again experienced the freeze. Here are the logs from gnome-shell: https://pastebin.ubuntu.com/p/YKtMQ2qy4g/

Note, I only disabled the extensions located in ~/.local/share/gnome-shell/extensions, I didn't modify anything in /usr/share/gnome-shell/extensions, as I see there is at least one traceback related to the desktop-icons@csoriano extension (which I don't recall installing so I assume that is an Ubuntu provided extension?).

Changed in gnome-shell (Ubuntu):
status: Incomplete → New
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Thanks. I can't see anything definite in that log. The next thing to try is to disable all extensions (even the Ubuntu ones) via the Extensions app. Then log in again and tell us if the freeze persists.

Changed in gnome-shell (Ubuntu):
status: New → Incomplete
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Also, next time the freeze happens please reboot and then run:

  journalctl -b-1 > prevboot.txt
  lspci -kv > lspci.txt

and attach the resulting text files here.

Revision history for this message
Ian Johnson (anonymouse67) wrote :

Well for the short bit that I've been using the system after disabling all the extensions through the Extensions app, I have not experienced any freeze. I will report back after the end of the day if I see any more freezes though.

Interestingly, after disabling all Extensions, I have no more dock unless I press the "super" button in which case it momentarily appears on the left, is this intended? I guess I seem to remember "stock gnome" had a dock that was permanently on the screen...

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

That's correct behaviour. The stock GNOME dock is hidden.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

If you set:

  gsettings set org.gnome.desktop.interface enable-hot-corners true

then the dock will appear by just moving the mouse to the top-left corner of the screen.

Revision history for this message
Ian Johnson (anonymouse67) wrote :

So after a full day of usage yesterday I did not see the freeze/crash at all, so it does indeed appear to be caused by one of the extensions bundled with Ubuntu. Should I try just enabling them one-by-one using the Extensions app?

I can't remember what all Extensions are enabled by default, but I am fairly confident the "Desktop Icons" extension was enabled so I'll start with enabling that one today and see if the freezes reproduce.

Revision history for this message
Ian Johnson (anonymouse67) wrote :

So indeed after enabling _only_ the Desktop Icon extension I experienced a freeze. Here are the logs: https://pastebin.ubuntu.com/p/XwJS7N4tF5/

Changed in gnome-shell (Ubuntu):
status: Incomplete → New
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Thanks. We released an update to gnome-shell-extension-desktop-icons this week with some fixes that might help. Please update your system:

  sudo apt update
  sudo apt full-upgrade

and then reboot.

If the freeze still happens after that then when it does, please reboot and run:

  journalctl -b-1 > prevboot.txt
  lspci -kv > lspci.txt

and attach the resulting text files here.

affects: gnome-shell (Ubuntu) → gnome-shell-extension-desktop-icons (Ubuntu)
Changed in gnome-shell-extension-desktop-icons (Ubuntu):
status: New → Incomplete
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Please also check you have the latest version installed:

  dpkg -s gnome-shell-extension-desktop-icons | grep Version

It should say:

  Version: 20.04.0+git20200908-5~ubuntu20.10.0

Revision history for this message
Ian Johnson (anonymouse67) wrote :

Unfortunately, I seem to be on that version of gnome-shell-extension-desktop-icons and still experience the freeze when I enable the desktop icons extension. Here's the dpkg output and gnome-shell logs: https://pastebin.ubuntu.com/p/yqDTV5KBmC/

Changed in gnome-shell-extension-desktop-icons (Ubuntu):
status: Incomplete → New
tags: added: nvidia
summary: - gnome-shell freezes randomly after upgrading to groovy
+ [nvidia] gnome-shell freezes randomly after upgrading to groovy
Revision history for this message
Daniel van Vugt (vanvugt) wrote : Re: [nvidia] gnome-shell freezes randomly after upgrading to groovy

In bug 1916029 you mentioned ubuntu-dock. Does the freeze happen if you disable that extension?

affects: gnome-shell-extension-desktop-icons (Ubuntu) → gnome-shell-extension-ubuntu-dock (Ubuntu)
Changed in gnome-shell (Ubuntu):
status: New → Incomplete
Changed in gnome-shell-extension-ubuntu-dock (Ubuntu):
status: New → Incomplete
Revision history for this message
Ian Johnson (anonymouse67) wrote :

So I disabled both ubuntu-dock and the desktop icons extensions and still see the freezes, here's a log of gnome-shell: https://pastebin.ubuntu.com/p/CXCfTVtkMJ/

Changed in gnome-shell-extension-ubuntu-dock (Ubuntu):
status: Incomplete → New
Changed in gnome-shell (Ubuntu):
status: Incomplete → New
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Thanks. That log shows gnome-shell (for the login screen?) died because Xorg went away:

Feb 23 07:30:15 gnome-shell[3625]: gnome-shell: Fatal IO error 11 (Resource temporarily unavailable) on X server :0.

Also there is evidence of a common freezing problem that happens with the Nvidia driver:

Feb 23 08:31:40 gnome-shell[8333]: Window manager warning: MetaSyncRing: Sync object is not ready -- were events handled properly?
Feb 23 08:31:40 gnome-shell[8333]: Window manager warning: MetaSyncRing: Sync object is not ready -- were events handled properly?

Next please follow the instructions in comments #5 and #11 and attach the resulting text files here in full. Please also check for crashes from the system using these instructions: https://wiki.ubuntu.com/Bugs/Responses#Missing_a_crash_report_or_having_a_.crash_attachment

Changed in gnome-shell (Ubuntu):
status: New → Incomplete
Changed in gnome-shell-extension-ubuntu-dock (Ubuntu):
status: New → Incomplete
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Also, that "common freezing problem that happens with the Nvidia driver" is being tracked upstream in https://gitlab.gnome.org/GNOME/mutter/-/issues/1516

Revision history for this message
Ian Johnson (anonymouse67) wrote :

Hey so sorry I missed that you wanted me to run those commands before, but it happened again this morning and here are the requested logs and lspci output. Note that I stripped out all the messages from snapd since I have debug mode enabled and it's extremely noisy, but if you think snapd could be at all at fault here I would love to know how and can share more info about that :-D

Revision history for this message
Ian Johnson (anonymouse67) wrote :

Here's lspci

Changed in gnome-shell (Ubuntu):
status: Incomplete → New
Changed in gnome-shell-extension-ubuntu-dock (Ubuntu):
status: Incomplete → New
Revision history for this message
Daniel van Vugt (vanvugt) wrote : Re: [nvidia] gnome-shell freezes randomly

Since you said in comment #18 when it happened again, and your log shows upstream issue mutter#1516 happened around that time, I am going to assume that's the problem and will link it to https://gitlab.gnome.org/GNOME/mutter/-/issues/1516

However, to be sure we're not looking at the wrong problem, please next time:

1. Confirm the exact time of day the problem occurred; and

2. Check for crashes using these instructions: https://wiki.ubuntu.com/Bugs/Responses#Missing_a_crash_report_or_having_a_.crash_attachment

affects: gnome-shell (Ubuntu) → mutter (Ubuntu)
no longer affects: gnome-shell-extension-ubuntu-dock (Ubuntu)
summary: - [nvidia] gnome-shell freezes randomly after upgrading to groovy
+ [nvidia] gnome-shell freezes randomly
Changed in mutter (Ubuntu):
status: New → Incomplete
Revision history for this message
Ian Johnson (anonymouse67) wrote :

Okay, so this time when it happened at Sun Mar 7 02:44 AM UTC 2021, here are the logs. I did not find any crash files in /var/crash, and there were no results for my whoopsie-id either.

The journalctl output is attached

Revision history for this message
Ian Johnson (anonymouse67) wrote :

Here's lspci

Revision history for this message
Ian Johnson (anonymouse67) wrote :
Revision history for this message
Ian Johnson (anonymouse67) wrote :
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Thanks. That log is a little bit confusing because it starts on 7 Mar and ends on 6 Mar. Clearly the time zone changed. Regardless, it looks like the same problem again (with incorrect timestamp):

Mar 06 20:44:52 gnome-shell[8104]: Window manager warning: MetaSyncRing: Sync object is not ready -- were events handled properly?
Mar 06 20:44:52 gnome-shell[8104]: Window manager warning: MetaSyncRing: Sync object is not ready -- were events handled properly?

Coincidentally, a fix has been proposed upstream that looks very encouraging: https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1754

Once it is accepted into GNOME 40 it will also be backported to 3.38.

summary: - [nvidia] gnome-shell freezes randomly
+ [nvidia] gnome-shell freezes randomly with "Window manager warning:
+ MetaSyncRing: Sync object is not ready -- were events handled properly?"
Changed in mutter (Ubuntu):
importance: Undecided → High
status: Incomplete → Triaged
tags: added: performance
Changed in mutter (Ubuntu):
status: Triaged → Fix Committed
tags: added: fixed-in-3.38.4 fixed-upstream
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

It appears Marco snuck the fix for this bug into: https://launchpad.net/ubuntu/+source/mutter/3.38.3-3ubuntu2

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

mutter (3.38.3-3ubuntu2) hirsute; urgency=medium

Changed in mutter (Ubuntu):
status: Fix Committed → Fix Released
Changed in mutter:
status: Unknown → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.