Monitoring a file?

Robert Huff roberthuff at rcn.com
Sat Nov 22 17:58:18 PST 2003


> Problem description:
> ====================
>
>  A file, let's say, /path/to/a/file, is being modified by
>  an unknown process P(u) at random times. Unfortunately,
>  the name of the program ran by P(u) is unknown.
>
>  The goal is to catch P(u) "red-handed," just the moment
>  it accesses /path/to/a/file, e.g. by looking up in the
>  process table with ps(1).

	Have you tried moving the file elsewhere and seeing if anyone
complains about the absence?
	Or writing a program that locks the file?


				Robert Huff





More information about the freebsd-questions mailing list