lkml.org 
[lkml]   [2006]   [Mar]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [OT] inotify hack for locate
Hi!

> >That's not the point. It usually does. I'm interested to know if
> >anyone has written a daemon that can sit and just do this
> >synchronously on my desktop - then not only do I /not/ have to run
> >updatedb every day but I can also have a locate that is always up to
> >the minute.
> >
> >
> I haven't heard about anyone doing this. You could modify
> the VFS to notify you everytime a file is created, moved or deleted.
> That should give you what you want, but at the cost of delaying
> those operations.
>
> Another option would be to make a filesystem that stores its
> directory structure (or a copy of it) in a single file, so that
> a locate-like program can do quick lookups of the always-correct
> data.

Better way is probably to create M-RECURSIVE-TIME field in inode --
similar to MTIME but counting modifications in directories. There are
many applications that would like to watch file modifications, and
some of them (like locate) are not running all the time.
Pavel
--
Web maintainer for suspend.sf.net (www.sf.net/projects/suspend) wanted...
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-03-06 23:02    [W:0.138 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site