LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Blogs > linux-related notes
User Name
Password

Notices


Just annotations of little "how to's", so I know I can find how to do something I've already done when I need to do it again, in case I don't remember anymore, which is not unlikely. Hopefully they can be useful to others, but I can't guarantee that it will work, or that it won't even make things worse.
Rate this Entry

Ugly wrap-around to avoid high CPU and I/O on update-apt-xapian-index

Posted 06-16-2015 at 03:54 AM by the dsc
Updated 06-16-2015 at 04:01 AM by the dsc

I've read somewhere that someone else was also annoyed by this.

Here's what I did:

Code:
#!/bin/sh
cpulimit -l 5 -e updatep-apt-xapian-index.py & 

ionice -c 3 /usr/sbin/update-apt-xapian-index.py $@
That's my "/usr/sbin/update-apt-xapian-index", which is called by synaptic and whatever else. The ".py" file is the original script.

It still makes the CPU fan audibly accelerate, but it's no longer frightening.


It's probably totally against Debian's policies and recommendations, though. It will most likely be just erased when the original script is updated, but perhaps the update may complain of something wrong. And, if nothing happens, of course, with no warning, the original high CPU and I/O will be back. Perhaps the "ideal" is to have some sort of daemon that renices the script and cpulimits it, when it's run.
Posted in Uncategorized
Views 695 Comments 0
« Prev     Main     Next »
Total Comments 0

Comments

 

  



All times are GMT -5. The time now is 06:20 AM.

Main Menu
Advertisement
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration