Due to tons of variations of Linux environment, the recently introduced native file system watcher for Linux may refuse to function properly. Here are some simple steps which may help to track down a problem.

Update

Make sure you are using the latest versions (download them from Git repository), they are named fsnotifier and fsnotifier64, placed into bin/ directory of IDEA, and granted execution rights.

Self-test

Execute watcher in self-diagnostics mode:

$ ./fsnotifier --selftest

It should print something like this:

fsnotifier[5661]  info: started (self-test mode)
fsnotifier[5661] debug: inotify fd: 4
fsnotifier[5661]  info: inotify watch descriptors: 524288
fsnotifier[5661]  info: updating roots (curr:0, new:1)
...
fsnotifier[5661]  info: registering root: /home/sher/Tools/idea-IU-dev/bin
fsnotifier[5661] debug: watching /home/sher/Tools/idea-IU-dev/bin: 1
...
fsnotifier[5661]  info: unregistering root: /home/sher/Tools/idea-IU-dev/bin
fsnotifier[5661] debug: unwatching /home/sher/Tools/idea-IU-dev/bin: 1 (0x9795068)
fsnotifier[5661]  info: finished

Examine its output for any errors or warnings.

Warning: fsnotifier will try to set up a watch for directory tree starting from the current directory – if a hierarchy is deep, there will be lots of output.

Activate logging

The next step is to activate logging for watcher and see what's happening in real.

Watcher utilizes "user" facility of syslog(3) – messages usually can be found in /var/log/user.log. Verbosity is regulated via FSNOTIFIER_LOG_LEVEL environment variable, possible values are: debug, info, warning, error, off.

By default, logging is switched off. To activate it, set FSNOTIFIER_LOG_LEVEL to an appropriate value before starting IDEA, e.g.:

$ FSNOTIFIER_LOG_LEVEL=info idea.sh

Warning: "debug" verbosity level may produce a really huge amount of messages – use with care.

If you see something suspicious in logs please feel free to post it here as a comment (or as an attachment).