Monitor consuming loads of CPU

Bug #203647 reported by Gustavo Niemeyer
4
Affects Status Importance Assigned to Milestone
Landscape Server
Fix Released
Critical
Gustavo Niemeyer
Twisted
Won't Fix
Unknown

Bug Description

landscape-monitor is consuming a lot of CPU in Ubuntu Hardy.

The problem seems to be related to a bug in Twisted's getProcessOutput()
function, which is misbehaving badly in that environment, as may be seen
by executing the attached test case.

Revision history for this message
Gustavo Niemeyer (niemeyer) wrote :
Changed in landscape:
importance: Undecided → Critical
milestone: none → mthood-pre-2
Changed in twisted:
status: Unknown → New
Revision history for this message
Andreas Hasenack (ahasenack) wrote :

With these packages in hardy, the problem happens:
libglib2.0-0_2.16.1-1ubuntu3_i386.deb
python-gobject_2.14.1-2_i386.deb

Downgrading them to the ones from gutsy fixes it:
python-gobject_2.14.0-0ubuntu1_i386.deb
libglib2.0-0_2.14.1-1ubuntu1_i386.deb

I'm now going to test some releases in between to see if I can pinpoint the exact version where this started happening.

Revision history for this message
Andreas Hasenack (ahasenack) wrote :

Issue found:

<seb128> niemeyer: my first guess is that's it's due to this:
<seb128> * Backport signal.set_wakeup_fd from the trunk, requested by desktop team.
<seb128> niemeyer: http://bugzilla.gnome.org/show_bug.cgi?id=481569 is the corresponding pygobject bug
<seb128> and I didn't have the issue on this machine but just upgrade to the current pygobject, which is basically just fixing the -dbg variant
<seb128> and now I get the bug
<seb128> and the only obvious difference is that the new bug was with a python which has this change
<seb128> s/bug/built
<seb128> confirmed
<seb128> building pygobject without using PySignal_SetWakeupFd makes the testcase not eat cpu

Revision history for this message
Andreas Hasenack (ahasenack) wrote :

If needed by someone in an emergency (customer, for example), seb128 has provided an updated package which fixes the problem on Hardy:

http://people.ubuntu.com/~seb128/python-gobject_2.14.1-2ubuntu1_i386.deb

It should appear in Hardy very soon now:
<seb128> slangasek: ^ uploaded to hardy, I've just reverted the configure.ac change and ran autoconf to update the configure
<slangasek> seb128: ok, cheers

Changed in twisted:
status: New → Won't Fix
Revision history for this message
Andreas Hasenack (ahasenack) wrote :

This has been fixed and released for Hardy:

2.14.1-2ubuntu1
Published in hardy-release 4 hours ago

pygobject (2.14.1-2ubuntu1) hardy; urgency=low

  * debian/patches/61_dont_use_setwakeupfd.patch:
    - don't use SetWakeupFd, it creates abnormal cpu usage in some situations

 -- Sebastien Bacher < <email address hidden>> Wed, 19 Mar 2008 22:17:53 +0100

Changed in landscape:
status: New → Fix Released
Changed in landscape:
assignee: nobody → niemeyer
Revision history for this message
Andreas Hasenack (ahasenack) wrote :

This happened again in intrepid and is being tracked at bug #250876

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

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