updating locate database only when disk activity low
Updating the slocate database slows the computer a lot (stupid IDE bus), so I'm looking for a way to do it only when the cpu load AND disk activity are low--basically, when I'm not trying to do anything else.
Cron really doesn't help because I use my computer at all kinds of weird times. I can't have it run at any set time without it getting in my way sometimes. There must be some tool I don't know about, but I can't seem to come up with the right search terms. Thanks! |
i'm not aware of a nicer way to do this, it may well exist, but google doesn't say so...
i'd say you could set a cron job to update every so often using a command like Code:
if [ `uptime | cut -c 60,62-63` -le 10 ]; then nice -19 updatedb; fi |
All times are GMT -5. The time now is 05:52 PM. |