Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision |
automation [2015/12/14 16:59] – ↷ Links adapted because of a move operation demiankatz | administration:automation [2016/05/13 19:39] – [Using cron] demiankatz |
---|
Once VuFind is running, you still need to do some work to keep it up to date and stable. The exact details of VuFind automation will vary significantly based on your ILS and operating system. However, these are the general common goals: | Once VuFind is running, you still need to do some work to keep it up to date and stable. The exact details of VuFind automation will vary significantly based on your ILS and operating system. However, these are the general common goals: |
| |
* Update VuFind's index with the latest changed and added records from your ILS. See the [[indexing:marc:export_notes]] for help with this. | * Update VuFind's index with the latest changed and added records from your ILS. See the [[indexing:marc:export_notes|MARC Export Notes]] for help with this. |
* Remove deleted and suppressed records from VuFind's index. VuFind is packaged with tools in the util directory that can help with this, but functionality may be limited depending on the capabilities of your ILS. | * Remove deleted and suppressed records from VuFind's index. VuFind is packaged with tools in the util directory that can help with this, but functionality may be limited depending on the capabilities of your ILS. |
* You may wish to make sure the Solr index is regularly optimized for minimal space usage and improved performance, though this is not as important for newer versions of Solr as it used to be. However, optimization can be a good way to ensure that all uncommitted changes become visible. There is a stand-alone optimize tool in the util directory. | * You may wish to make sure the Solr index is regularly optimized for minimal space usage and improved performance, though this is not as important for newer versions of Solr as it used to be. However, optimization can be a good way to ensure that all uncommitted changes become visible. There is a stand-alone optimize tool in the util directory. |
=== Why restart VuFind? === | === Why restart VuFind? === |
| |
The main reason to regularly restart the VuFind is to ensure system stability. Due to the way Java garbage collection works, Solr can eventually run out of memory and stop responding; periodic restarts are an easy way to avoid this problem. If you want to automatically detect garbage collection problems in a more sophisticated way, you can try this solution suggested by Erik Mitchell: | The main reason to regularly restart the VuFind is to ensure system stability. Due to the way Java garbage collection works, Solr can eventually run out of memory and stop responding; periodic restarts are an easy way to avoid this problem. It is also a good idea to investigate [[administration:performance#java_tuning|Java tuning]] to address the root cause -- but even with a well-tuned system, occasional restarts (such as, on a weekly basis) can help ensure long-term stability. |
| |
1. Modify the JAVA_OPTIONS to include Garbage Collector logging (Xloggc) | |
| |
<code> | |
JAVA_OPTIONS="-server -Xms1024m -Xmx3800m -XX:+UseParallelGC -XX:NewRatio=5 -Xloggc:/var/log/vufindr/gc.log" | |
</code> | |
| |
2. Create and cron a script that searches this log for the word Full. If it finds it, the GC has failed and it is only a matter of time before vufind bonks. | |
| |
<code> | |
if [[ $(grep -c 'Full' /var/log/vufind/gc.log) != 0 ]];then | |
exec /usr/local/vufind/vufind_cron.sh restart >> /home/vufind/cron.log | |
fi | |
</code> | |
| |
(File paths may need to be adjusted to match your own system). | |
==== Using mysqldump ==== | ==== Using mysqldump ==== |
| |