Monitoring FS changes
Chris Stankevitz
chris at stankevitz.com
Thu Dec 31 07:24:08 UTC 2015
Hi,
I have a directory /foo that recursively contain ~250,000 files/directories.
I would like my application to know when a file is added, removed, or
modified under /foo. Is there a way to do that with FreeBSD?
I believe on linux a facility called iNotify accomplishes this.
On OSX a facility called FSEvents accomplishes this.
kqueue apparently requires me to open every file and/or directory in my
tree... which won't work because I have so many.
Is there any other option? Perhaps
i=0
while (true)
{
zfs snapshot pool/foo@${i}
zfs diff pool/foo@${i-1} pool/foo@${i}
++i
}
Thank you,
Chris
More information about the freebsd-fs
mailing list