[openbeos] Re: Tracker Task Loop

  • From: "Cyan" <cyanh256@xxxxxxxxxxxx>
  • To: openbeos@xxxxxxxxxxxxx
  • Date: Fri, 09 May 2008 04:21:13 +0100 BST

> Could someone please tell me what I can do to keep Tracker Taskloop 
> from spinning out of control and eating up tons of processor
> cycles?  I can't figure out what makes it go crazy, but it can
> literally bring the system to its knees sometimes.

I've had a similar issue here for years. It has never been much of
a problem, because the thread priority is "low" (5) -- even on a
single-processor machine this doesn't seem to impact system
responsiveness. Killing Tracker and restarting it stops the spinning.
It also seems to consume exactly 50% of one CPU, on both a
single-processor Athlon (1.33GHz) and a quad-core Core2 (2.4GHz),
which strikes me as very strange.

The 'FileTypes' application reports OpenTracker as version 5.2.1
-- it's quite old now, dated around Nov 2003 for all three files.
This is running under R5+BONE.

For some reason, it doesn't start spinning until quite some time
after booting, sometimes many hours. Maybe it only starts spinning
once something happens, such as performing a certain query, etc.,
but I haven't managed to trace it to anything yet.

One potential factor that could be involved is the number of files
and/or partition size. I suspect in both of our cases we may have
more files and/or larger partitions than the average BeOS/Haiku user.
In this case, there's around one million files (which are queried
several times a day), consuming about 150GB on several BFS 
partitions, one of which is over 200GB.
Block size is 2K, and the recommended adjustments to the disk cache
size (in the kernel settings file) have been made.

Also, some of the folders contain an unusually large number of files,
especially the dreaded 'Stuff' folder (over 1000 files).
Tracker seems to struggle displaying this many items (they "pour"
into the window over about 10+ seconds, like it's running inside
a PC emulator on a NES), so maybe one of these could be a trigger.

Also, I've noticed that occasionally some live queries will stop
updating; maybe this could be related to the task loop getting
locked up? It doesn't seem to impact anything else on the system
though -- hard disk access is still very fast, so it probably isn't
spinning inside a driver.

I'll keep an eye on it today to see if I can trace it any further,
assuming it starts (it hasn't started spinning yet).

What does this thread actually do?

- Cyan

Other related posts: