** Description changed: [ Impact ] - * The indicator-keyboard-service process suffers from a memory leak + * The indicator-keyboard-service process suffers from a memory leak that quickly consumes the entire available memory of the system until the process is killed by the OOM daemon. Since indicator-keyboard is a session service it will be restarted and the process repeats, making the system unusable. On the system where I tested this indicator-keyboard- service started with ~2MB and quickly rose to consume all 64GB of memory. The session then appears to hang for about a minute until the OOM daemon kills the process. [ Test Plan ] - * Prerequisites: - - A running gnome-session-flashback XOrg session + * Prerequisites: + - A running gnome-session-flashback XOrg session - * Ensure you have multiple input sources configured, for example: - $ dconf read /org/gnome/desktop/input-sources/sources - [('xkb', 'us'), ('ibus', 'libpinyin')] + * Ensure you have multiple input sources configured, for example: + $ dconf read /org/gnome/desktop/input-sources/sources + [('xkb', 'us'), ('ibus', 'libpinyin')] - * Start indicator-keyboard-service via: - $ indicator-keyboard-service --use-gtk + * Start indicator-keyboard-service via: + $ indicator-keyboard-service --use-gtk - * Watch the memory consumption to raise quickly and consume all + * Watch the memory consumption to raise quickly and consume all available memory until it is being killed by the OOM daemon. + [ Where problems could occur ] - [ Regression Potential ] - - * The regression potential is very low since indicator-keyboard-service + * The regression potential is very low since indicator-keyboard-service is already suffering from a memory leak that is causing it to be killed by the OOM daemon every few minutes. It is unlikely that this change will make the problem worse. - * User base of indicator-keyboard is low. The main users of this + * User base of indicator-keyboard is low. The main users of this package are Unity and Gnome Flashback and both are not default desktops on Ubuntu. Gnome Shell does not depend on indicator-keyboard. So a potential regression would only affect users of these desktops. - * The source code changes include the removal of a redundant + * The source code changes include the removal of a redundant initialization of IBus in two functions of indicator-keyboard-service and instead move the initialization to the constructor of the indicator keyboard service. No new functionality is added and the existing behavior of the application is not changes except for consolidation of the redundant IBus initialization calls. - * On GNOME Flashback another workaround exists in case there is an + * On GNOME Flashback another workaround exists in case there is an unexpected regression due to this chaneg. In the unlikely event that the change has a side effect and prevents the indicator from working, users an switch to the newer "System Indicators" applet and remove the indicator-keyboard package completely. NEWS The fix is available in version 0.0.0+19.10.20240924-0ubuntu1 === Original Description === Description: The system was previously on 22.04, then upgraded to 23.10 to the current daily 24.04. System will freeze up a few minutes after startup (with no apparent related crashes). After various trial and error, the possible cause is isolated to indicator-keyboard when running gnome- session-flashback (freeze does not happen anymore with flashback interface, after indicator-keyboard package is removed). Not sure why this is not happening with vanilla gdm3. Also, the freeze was first observed after the upgrade to 23.10. **logs below taken from `sudo journalctl --since "3 hours ago" | grep indicator`** Feb 29 16:49:03 machine kernel: oom-kill:constraint=CONSTRAINT_NONE,nodemask=(null),cpuset=user.slice,mems_allowed=0,global_oom,task_memcg=/user.slice/user-1000.slice/user@1000.service/app.slice/indicator-keyboard.service,task=indicator-keybo,pid=5810,uid=1000 Feb 29 16:49:03 machine kernel: Out of memory: Killed process 5810 (indicator-keybo) total-vm:66620172kB, anon-rss:64296784kB, file-rss:768kB, shmem-rss:0kB, UID:1000 pgtables:129412kB oom_score_adj:200 Feb 29 16:49:03 machine kernel: oom_reaper: reaped process 5810 (indicator-keybo), now anon-rss:688kB, file-rss:768kB, shmem-rss:0kB Feb 29 16:48:56 machine systemd[5304]: indicator-keyboard.service: A process of this unit has been killed by the OOM killer. Feb 29 16:48:57 machine systemd[5304]: indicator-keyboard.service: Main process exited, code=killed, status=9/KILL Feb 29 16:48:57 machine systemd[5304]: indicator-keyboard.service: Failed with result 'oom-kill'. Feb 29 16:48:57 machine systemd[5304]: indicator-keyboard.service: Consumed 1min 11.913s CPU time. Feb 29 16:48:58 machine systemd[5304]: indicator-keyboard.service: Scheduled restart job, restart counter is at 1. Feb 29 16:48:58 machine systemd[5304]: Started indicator-keyboard.service - Indicator Keyboard Backend. Feb 29 17:00:40 machine dbus-daemon[1111]: [system] Activating via systemd: service name='org.freedesktop.login1' unit='dbus-org.freedesktop.login1.service' requested by ':1.9' (uid=0 pid=1588 comm="apt remove indicator-keyboard" label="unconfined")
** Also affects: indicator-keyboard (Ubuntu Noble) Importance: Undecided Status: New -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/2055388 Title: suspected memory leak with indicator-keyboard (causing gnome-session- flashback to freeze after startup) To manage notifications about this bug go to: https://bugs.launchpad.net/indicator-keyboard/+bug/2055388/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs