On Mon, 2007-12-17 at 20:32 +0100, Anders Johansson wrote:
On Monday 17 December 2007 19:58:18 JP Rosevear wrote:
Beagle already does nice itself and employ strategies for reducing work when the CPU is not idle. However I/O is a problem and non-root processes can't change their own I/O priority iirc.
Actually, they can. "All" they need is CAP_SYS_ADMIN
A bit silly to not allow a process to downgrade its own priority, with nice I can set myself to absolute rock bottom. Even sillier is it to have the capability baked in with some real admin capabilities. It should be more fine grained
I concur. And in fact the system wide index thats shared for documentation, apps, etc does run as a privileged user and takes advantage of ionice (/etc/cron.daily/beagle-crawl-system).
But what beagle could do is start as root (or CAP_SYS_ADMIN), run ioprio_set(), then immediately drop root perms.
Have you met our security team? :-)
All kidding aside, this sounds like an interesting idea, although
indexing happens in a shorter lived indexing processes rather than a
proper daemon so the indexer would have to do that itself.
-JP
--
JP Rosevear