gltext seems to leak memory eventually causing oom-killer to run

Bug #768032 reported by Gary Lyons
This bug affects 16 people
Affects Status Importance Assigned to Milestone
xscreensaver (Ubuntu)

Bug Description

Binary package hint: xscreensaver-gl

gltext is consuming large amounts of memory. Often being killed by oom-killer but eventually causing me not to be able to log into my computer disabling gltext from the list of possible screensavers caused the problem to go away.

Ubuntu Natty (development branch)
Release: 11.04
 Installed: 5.12-0ubuntu3
  Candidate: 5.12-0ubuntu3
  Version table:
 *** 5.12-0ubuntu3 0
        500 natty/main amd64 Packages
        100 /var/lib/dpkg/status

ProblemType: Bug
DistroRelease: Ubuntu 11.04
Package: xscreensaver-gl 5.12-0ubuntu3
ProcVersionSignature: Ubuntu 2.6.38-8.42-generic
Uname: Linux 2.6.38-8-generic x86_64
NonfreeKernelModules: nvidia
Architecture: amd64
Date: Wed Apr 20 22:56:35 2011
InstallationMedia: Ubuntu 10.10 "Maverick Meerkat" - Release amd64 (20101007)
SourcePackage: xscreensaver
UpgradeStatus: Upgraded to natty on 2011-04-17 (4 days ago)

Related branches

Revision history for this message
Gary Lyons (gllyons) wrote :
Revision history for this message
Tormod Volden (tormodvolden) wrote :

I guess you are using the nvidia proprietary driver? Does this happen if you use the open-source nouveau driver (you may need to install the libgl1-mesa-dri-experimental from universe)?

Changed in xscreensaver (Ubuntu):
status: New → Incomplete
Revision history for this message
Gary Lyons (gllyons) wrote :

I will try that as soon as I am back at that computer. I did want to point out that someone on Gentoo had a similar problem problem and there is a link to a patch. I am not sure if it is the same issue but it looks pretty similar

Revision history for this message
Gary Lyons (gllyons) wrote :

ok I switched to the nouveau driver and the exact same thing happened. I watched the memory usage in top and it just keeps rising pretty dramatically until oom-killer is invoked and kills it.

Revision history for this message
Tormod Volden (tormodvolden) wrote :

Thanks. The patch was included in upstream version 5.13.

Changed in xscreensaver (Ubuntu):
status: Incomplete → Confirmed
tags: added: bitesize patch
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package xscreensaver - 5.13-1ubuntu1

xscreensaver (5.13-1ubuntu1) oneiric; urgency=low

  * Merge with Debian unstable, remaining Ubuntu changes:
  * debian/control:
    - Build-Depend on ubuntu-artwork
    - Add Vcs-Bzr link
    - Move xli | xloadimage xscreensaver recommends to suggests
    - Add/Update replaces with Ubuntu versions
    - Update package descriptions to list Ubuntu screensavers
  * debian/rules:
    - Use /usr/share/backgrounds as image directory
    - Add translation domain to .desktop files
  * debian/
    - Add apport hook
  * debian/split-hacks.config:
    - Use different set of default hacks than Debian
  * debian/xscreensaver.dirs
    - Install /usr/share/backgrounds. By default, settings search in
      /usr/share/backgrounds and without it, it displays an error
  * debian/patches/
    - Use Ubuntu branding

xscreensaver (5.13-1) unstable; urgency=low

  * New upstream version 5.13
    - Passwords that contain UTF-8 non-Latin1 chars are now typeable
    - pt_BR translation (thanks Sérgio Cipolla!) (Closes: #586230)
    - Fix memory leak in gltext (LP: #768032)
  * Build without gdm and libgnome2-dev (Closes: #618165)
  * Add Suggests on gdm3 or kdm-gdmcompat because gdmflexiserver
    can be used for the "New Login" functionality (see bug #304406)
  * Remove obsolete gdmflexiserver options
  * xscreensaver.desktop changes:
    - Do not set StartupNotify.
    - Do not specify svg icon. Closes: #618723 (LP: #603222)
  * Fix installation path for xscreensaver-daemon.desktop
  * debian/xscreensaver.preinst: Check version before
    deleting obsolete configuration files (Closes: #588288)
  * Bump Standards-Version to 3.9.1 (no changes needed)
 -- Jeremy Bicha <email address hidden> Wed, 18 May 2011 15:39:48 +0200

Changed in xscreensaver (Ubuntu):
status: Confirmed → Fix Released
Revision history for this message
Tormod Volden (tormodvolden) wrote :

It looks like this was supposed to be fixed in natty as well, but 5.12-0ubuntu4 did not make it to the archives:

Revision history for this message
gpk (gpk-kochanski) wrote :

It crashes my computer in Natty. This is a serious bug, because it causes all kinds of havoc. Loss of data, for one thing.

However, this is not just a bug in gltext: it is a bug in xscreensaver. Xscreensaver should adjust the OOM killer to preferentially kill its subprocesses. A screensaver subprocess is *NOT* an important process -- it should not be allowed to run wild and endanger the operation of the rest of the system.

A simple manipulation in /proc/[pid]/oom_adj would solve the problem.

open("/proc/%d/oom_adj", "w").write("10\n")

would do the trick.

Changed in xscreensaver (Ubuntu Natty):
status: New → Confirmed
Revision history for this message
alfredo (alacis) wrote :

This leak occurs even when using the 'preview' dialog, see attachment.

Revision history for this message
Tormod Volden (tormodvolden) wrote :

Robert Ancell fixed this in the bazaar branch and prepared a natty package release. I assume he forgot to actually upload it?

dino99 (9d9)
Changed in xscreensaver (Ubuntu Natty):
status: Confirmed → Invalid
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers