FS#16518 - [man-db] and mlocate (package) 's cron job could use use ionice
Attached to Project:
Arch Linux
Opened by solsTiCe (zebul666) - Thursday, 08 October 2009, 11:42 GMT
Last edited by Andreas Radke (AndyRTR) - Monday, 15 March 2010, 12:01 GMT
Opened by solsTiCe (zebul666) - Thursday, 08 October 2009, 11:42 GMT
Last edited by Andreas Radke (AndyRTR) - Monday, 15 March 2010, 12:01 GMT
|
Details
Feature request!
i have seen a interesting idea in bug use ionice in cron job of man-db and mlocate. I have always found annoying those cronjob that hammer my harddisk just after i powered up my PC and had something more important to do than to wait for whatever apps you run to open because those cronjob take all the ressource on disk it's a desktop situtation with fcron (or cron+anacron) but i doubt a server need all ressource be taken to such a task at 00:00 either. so please use "nice -n 19 ionice -c 3" before man-db and mlocate (updatedb) in their cronjob like this # regenerate man database nice -n 19 ionice -c 3 /usr/bin/mandb --quiet packages : man-db mlocate may be it could benefit to other cron job too. |
This task depends upon
How about making it globally tunable:
* add conf.d/cron with NICE variable to all cron packages (dcron in Core, few others in Community)
* user can set NICE in conf.d/cron to something like "nice -n 19 ionice -c 3"
* source it from man-db, mlocate, etc. cron files
* run the required command from cron files with $NICE prepended
FS#15613. As I said there, the cron job is in the backup array for mlocate so you are free to modify it yourself.what backup array are you talking about ? in which file do you modify that ?
please elaborate
you mean the cron job file is in the backup array of the package so it is backed up by pacman before any upgrade of the package and i will not loose my change ?
thanks. i already made the change.
so i change it to 3 (IONICE_CLASS=3)
but then i got this line added to the email from cron about cron.daily
ionice: ignoring given class data for idle class
harmless but ...
dealing with that means removing the -n flags of ionice if IONICE_CLASS is different than 1 or 2.
nice -n 19 ionice -c 3
or
ionice -c 3 nice --n 19
?