inotify.7: Mention cache rebuilding to handle overflow events

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
Michael Kerrisk 2014-04-02 13:37:14 +02:00
parent 264276c6b0
commit 94d52c1529
1 changed files with 7 additions and 0 deletions

View File

@ -622,6 +622,13 @@ Note that the event queue can overflow.
In this case, events are lost.
Robust applications should handle the possibility of
lost events gracefully.
For example, it may be necessary to rebuild part or all of
the application cache.
(One simple, but possibly expensive,
approach is to close the inotify file descriptor, empty the cache,
create a new inotify file descriuptor,
and then re-create watches and cache entries
for the objects to be monitored.)
The inotify API identifies affected files by filename.
However, by the time an application processes an inotify event,