Comment 3 for bug 493852

Revision history for this message
Andrey Bondarenko (abone) wrote :

As of version 1.52ubuntu2 popularity-contest started as a regular process. I suppose changing IO and CPU scheduling priorities Idle should place less load to the system, but I cannot notice the change in my environment. Both cases works on my P4-3GHz 3GiB or RAM with two 7200 RPM disks equally well.

Anyway, I agree that system with less RAM or slower disk may suffer from popcon activity. But we have to test things to decide if nice/ionice is enough or we should limit IO with some other means. Please try to do some job while popularity contest is running to check how much it slows down your system.

The following test should simulate current situation:

sudo sh -c "echo 3 > /proc/sys/vm/drop_caches; sync"
time popularity-contest

The next test should run popularity-contest as a low-priority background task

sudo sh -c "echo 3 > /proc/sys/vm/drop_caches; sync"
time ionice -c 3 nice popularity-contest

In case, changing priority is enough, patch it really trivial:

=== modified file 'debian/cron.daily'
--- debian/cron.daily 2011-05-23 15:38:47 +0000
+++ debian/cron.daily 2011-06-10 15:35:17 +0000
@@ -50,7 +50,7 @@

 run_popcon()
 {
- su -s /bin/sh -c "/usr/sbin/popularity-contest" nobody
+ su -s /bin/sh -c "/usr/bin/ionice -c 3 /usr/bin/nice /usr/sbin/popularity-contest" nobody
 }

 do_sendmail()