Re: [Tracker] [PATCH] Make tracker skip mountpoints



On 8/6/07, jamie <jamiemcc blueyonder co uk> wrote:
On Mon, 2007-08-06 at 13:36 +0200, Marcus Fritzsch wrote:
On 8/6/07, jamie <jamiemcc blueyonder co uk> wrote:
On Mon, 2007-08-06 at 04:03 +0200, Marcus Fritzsch wrote:
This patch prevents tracker from descending into mountpoints which is
a directory other than a watch- or crawl-root. I often have some fs
(sshfs, nfs) mounted under my $HOME and found tracker going down all
these trees. Also, there was a bug report on launchpad about this[1].

I am however not sure if this method works, also I haven't found much
references when searching for it by google or clusty. If there are
objections to this method of mount-point 'discovery' it would be
possible to read mtab and store it in struct Tracker for processing.

However as tracker is not that simple I am not aware of any side
effects this patch may have on tracker, I tested it - with mount
points in watched dirs and crawled ones, with fuse and nfs mounts.

Any comments?


yeah its a good idea

but take a look at tracker-utils.c:

tracker_file_is_no_watched
tracker_file_is_crawled

Thought of this too. The function signature needs a 'current' dir and
a 'testdir' to check wether testdir is a different device then current
- there is no problem with that? That would be faster - however I
could also implement it by checking against the crawl and watch
directory roots list. Which one do you prefer?

I would prefer the latter but can we store the device signature of the
watch and crawl dirs somewhere so we are not constantly stating them?

(Could use a GSList to store them and simply iterate over them)

Yes, that's no problem I think.

OK, getting to code now.

Marcus



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]