After a recent upgrade to Fedora 15, I'm finding that a number of tools are failing with errors along the lines of:
tail: inotify resources exhausted
tail: inotify cannot be used, reverting to polling
It's not just tail
that's reporting problems with inotify, either. Is there any way to interrogate the kernel to find out what process or processes are consuming the inotify resources? The current inotify-related sysctl
settings look like this:
fs.inotify.max_user_instances = 128
fs.inotify.max_user_watches = 8192
fs.inotify.max_queued_events = 16384
Best Answer
It seems that if the process creates inotify instance via inotify_init(), the resulting file that represents filedescriptor in the /proc filesystem is a symlink to (non-existing) 'anon_inode:inotify' file.
Unless I misunderstood the concept, the following command should show you list of processes (their representation in /proc), sorted by number of inotify instances they use.
Finding the culprits
Via the comments below @markkcowan mentioned this: