====================================
Verifying and tuning search indexing
====================================


For search indexing to work correctly, a compute node must be
able to communicate with the server. To verify this:

#. Run:

   .. code-block:: bash

      curl -m 5 $AEN_SERVER > /dev/null

#. Verify that there are sufficient inotify watches available for
   the number of subdirectories within the project root file
   system:

   .. code-block:: bash

      cat /proc/sys/fs/inotify/max_user_watches

   NOTE: Some Linux distributions default to a low number of
   watches, which may prevent the search indexer from monitoring
   project directories for changes.

#. If necessary, increase the number of watches:

   .. code-block:: bash

      echo fs.inotify.max_user_watches=100000 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p



#. Verify that there are sufficient inotify user instances
   available---at least one per project:

   .. code-block:: bash

      cat /proc/sys/fs/inotify/max_user_instances

#. If necessary, increase the number of inotify user instances:

   .. code-block:: bash

      echo fs.inotify.max_user_instances=1000 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p
