Bug 427056 - Memory Leak in applet.py
Memory Leak in applet.py
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: system-config-printer (Show other bugs)
7
All Linux
low Severity high
: ---
: ---
Assigned To: Tim Waugh
Fedora Extras Quality Assurance
:
Depends On:
Blocks: F7Update
  Show dependency treegraph
 
Reported: 2007-12-30 13:50 EST by Ken Tanzer
Modified: 2008-01-31 04:26 EST (History)
1 user (show)

See Also:
Fixed In Version: 0.7.74.10-2.fc7
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-01-31 04:26:18 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Ken Tanzer 2007-12-30 13:50:12 EST
Description of problem:

We have a machine with 12GB RAM that is used by multiple users.  Several times
recently (last two weeks?) all the available RAM has been used up, and the
culprit seems to be the applet.py from system-config-printer.

This happened on Friday, and I killed all our running applet.pys, which freed up
almost all the RAM.  Today we were out of RAM again, with only 9 running
applet.pys.  Below is output indicating memory usage.  I'm reasonably sure those
numbers are in kilobytes, indicating that each process was using a gigabyte or
so of RAM.

Please note that probably none of our users actually use the applet, so the
leakage is happening while the applet just sits.

Version-Release number of selected component (if applicable):

system-config-printer-0.7.74.4-1.fc7

How reproducible:
Right now, seems pretty easy.

Steps to Reproduce:
1.  Verify you have plenty of memory, and one or more users are logged in &
running applet.py
2.  Either watch the amount of RAM used grow, or just wait until the machine
doesn't work any more.
  
Actual results:
The applets use all your available memory

Expected results:
Each applet uses an amount of memory that does not grow inexorably over time,
and an amount more commensurate with being an "applet". :)

Additional info:

More detail below, but is there a good suggested workaround for this until it is
fixed?

Here was the memory usage for our 9 applets:

[ktanzer@lyon ~]$ ps aux | grep pyth | grep config-printer
xxxxxxxx  3335  0.5 11.0 1515320 1383600 ?     S    Dec28  17:29 python
/usr/share/system-config-printer/applet.py
xxxxxxxx  3336  0.5 10.9 1515192 1369548 ?     S    Dec28  17:27 python
/usr/share/system-config-printer/applet.py
xxxxxxxx  3342  0.5 11.6 1515320 1452156 ?     S    Dec28  17:31 python
/usr/share/system-config-printer/applet.py
xxxxxxxx  3817  0.5 10.1 1504744 1271768 ?     S    Dec28  16:43 python
/usr/share/system-config-printer/applet.py
xxxxxxxx  3833  0.5 10.7 1504732 1345500 ?     S    Dec28  16:59 python
/usr/share/system-config-printer/applet.py
xxxxxxxx  3852  0.4 11.1 1504668 1385476 ?     S    Dec28  14:31 python
/usr/share/system-config-printer/applet.py
xxxxxxxx 12857  0.5 10.9 1486372 1362196 ?     D    Dec28  16:21 python
/usr/share/system-config-printer/applet.py
xxxxxxxx 16299  0.4  6.3 1096856 797272 ?      S    Dec28  14:29 python
/usr/share/system-config-printer/applet.py
xxxxxxxx 21289  0.5  8.4 1474740 1052156 ?     S    Dec28  15:51 python
/usr/share/system-config-printer/applet.py

I killed all our applets about 30 minutes ago.  One user now has an applet
running.  Here is usage (same command as for output above) from the last few
minutes:

10:37:31 23432 11604
10:38:56 23812 11756
10:40:31 23944 11932
10:44:44 24412 12408
10:47:54 24744 12732
Comment 1 Tim Waugh 2008-01-02 08:19:26 EST
Please try the current test update, 0.7.74.8-1.fc7:

  yum --enablerepo=updates-testing update 'system-config-printer*'

Several memory leaks have been fixed in the pycups module included in that package.

Does this fix the problem?
Comment 2 Nathan Tain 2008-01-07 18:23:53 EST
Re comment 1:
Installed the suggested update last week and that seemed to fix it.  The
processes seem to top out at 50MB of memory use.  Certainly none grew to the
huge size they did previously.

#ps aux | grep pyth | grep config-printer
50156 24692 11:25
23320 11216 12:28
50152 24912 13:10
50156 24848 14:22
23312 11236 15:00
50136 24688 15:03
50152 24904 15:49

Note You need to log in before you can comment on or make changes to this bug.