Using cron to automate indexing

The most common way to set up indexing is to have a cron task execute it every night. For example the following crontab entry would do it every day at 3:30AM (supposing recollindex is in your PATH):

        30 3 * * * recollindex > /some/tmp/dir/recolltrace 2>&1

Or, using anacron:

        1  15  su mylogin -c "recollindex recollindex > /tmp/rcltraceme 2>&1"

As of version 1.17 the Recoll GUI has dialogs to manage crontab entries for recollindex. You can reach them from the PreferencesIndexing Schedule menu. They only work with the good old cron, and do not give access to all features of cron scheduling.

The usual command to edit your crontab is crontab -e (which will usually start the vi editor to edit the file). You may have more sophisticated tools available on your system.

Please be aware that there may be differences between your usual interactive command line environment and the one seen by crontab commands. Especially the PATH variable may be of concern. Please check the crontab manual pages about possible issues.