File system changes notification
Most of the applications in FreeBSD currently use polling because of limitations of kevent-based file change monitoring (gamin, kde). Kevent approach has the same limitation as Linux' dnotify once had: file or directory should be opened to monitor changes, preventing file system unmounting. I propose to develop a kernel level file system changes notification mechanism for FreeBSD overcoming this limitation.
- Very simple notification mechanism. Create user space utility for debugging printing all events. Pass all events to user space, attach to all vnodes on creation
- Create a library based on the utility. Add client sessions, distribute events to all clients. Add main operations to the library (initialization, addition notification, deletion of notification)
- Add cookies to VFS_KNOTE_LOCKED to make several notifications during move or rename part of single operation. Add path caching necessary to return previous path expected by rename and delete operations.
- Clean and test code before mid-term evaluation. Code is to be useful but with limitations.
- Filter events. Attach to vnodes client is interested in. Attach not only on vnode creation but also to already existing vnodes.
- Add access permissions checks. Add sysctl to enable access permissions check. Run benchmark to measure its overhead.
- Ensure source level compatibility with inotify. Interface is to be very similar from the beginning. Reuse tests from linux.
- Add linuxulator support. Linuxulator support is just a wrapper mapping linux' syscalls to native device ioctls.