In a previous post we talk about search
subsystems in Alfresco. There exists for each subsystem some
quartz jobs related to backup indices. In the case of Lucene
subsystem, Lucene backups are done at 3AM and their parameters are
configurable via alfresco-global.properties (or extending the
corresponding search subsystem).
subsystems in Alfresco. There exists for each subsystem some
quartz jobs related to backup indices. In the case of Lucene
subsystem, Lucene backups are done at 3AM and their parameters are
configurable via alfresco-global.properties (or extending the
corresponding search subsystem).
index.backup.cronExpression=0 0 3 * * ? dir.indexes=${dir.root}/lucene-indexes dir.indexes.backup=/backup-lucene-indexes
So you can always change these values, and then restart Alfresco
service for Community version.
service for Community version.
In the case of SOLR subsystem, SOLR backups are done at 2AM and 4AM
(for example in alfresco-global.properties)
(for example in alfresco-global.properties)
solr.backup.alfresco.cronExpression=0 0 2 * * ? solr.backup.archive.cronExpression=0 0 4 * * ? solr.backup.alfresco.numberToKeep=3 solr.backup.archive.numberToKeep=3 solr.backup.alfresco.remoteBackupLocation=${dir.root}/solrBackup/alfresco solr.backup.archive.remoteBackupLocation=${dir.root}/solrBackup/archive
And you can always change them too, and restart the service for
Community version.
Community version.
You can also invoke SOLR backups, from SOLR admin panel (with
browser.p12 certificate) you can go to the corresponding urls:
browser.p12 certificate) you can go to the corresponding urls:
https://alfserver:8443/solr/alfresco/replication?command=backup&location=/opt/alfresco/alf_data/solrBackup/alfresco&numberToKeep=3
https://alfserver:8443/solr/archive/replication?command=backup&location=/opt/alfresco/alf_data/archive/alfresco&numberToKeep=3
Even, it can be done via curl:
In Alfresco EE, we can also perform this operation with Alfresco
Admin Console (changing the cron expression). It is also possible to
change the same cron expression via JMX or even better to run JMX SOLR
backup trigger via jmxterm or your favourite JMX console. For example,
with jmxterm you can type:
Admin Console (changing the cron expression). It is also possible to
change the same cron expression via JMX or even better to run JMX SOLR
backup trigger via jmxterm or your favourite JMX console. For example,
with jmxterm you can type:
jmvs open <bootstrap-id> domain Alfresco bean Alfresco:Group=DEFAULT,Name=Schedule,Trigger=search.alfrescoCoreBackupTrigger,Type=MonitoredCronTrigger run executeNow
In the case of jmxterm, it is possible to write a shell script as
an alternative for the curl method. The script file should be like this:
an alternative for the curl method. The script file should be like this:
#! /bin/bash JMXTERM_CMD0="run -b Alfresco:Group=DEFAULT,Name=Schedule,Trigger=search.alfrescoCoreBackupTrigger,Type=MonitoredCronTrigger -d Alfresco executeNow" echo $JMXTERM_CMD0 | java -jar jmxterm-1.0-alpha-4-uber.jar -l service:jmx:rmi:///jndi/rmi://localhost:50500/alfresco/jmxrmi -p change_asap -u controlRole JMXTERM_CMD1="run -b Alfresco:Group=DEFAULT,Name=Schedule,Trigger=search.archiveCoreBackupTrigger,Type=MonitoredCronTrigger -d Alfresco executeNow" echo $JMXTERM_CMD1 | java -jar jmxterm-1.0-alpha-4-uber.jar -l service:jmx:rmi:///jndi/rmi://localhost:50500/alfresco/jmxrmi -p change_asap -u controlRole