The approach to backup and restore is to ensure that the repository is backed up before the Sync Service, so that a subsequent restore can simply remove any tracked repository changes that occurred after the repository backup.
-
To perform a backup of your Sync Service database, follow these steps:
-
Backup your repository database. See Back up and restore).
-
After you have successfully backed up the repository, wait for a couple of minutes to ensure that the synchronization server has correctly tracked the repository after the repository backup.
-
Alternatively, ensure that all undelivered events in the event queue,
Consumer.<guid>.VirtualTopic.alfresco.repo.events.nodeshave been delivered such thatMessages Dequeued == Number Of Pending Messages. Here,guidis the synchronization server id, which can be determined from thesyncServiceIdCheckin the health check response,https://localhost:9090/alfresco/healthcheck. -
Backup your synchronization service database using your database vendor's backup/restore tools.
-
-
To perform a restore, follow these steps:
-
Use the ActiveMQ console to check that all the events in the event queue,
Consumer.<guid>.VirtualTopic.alfresco.repo.events.nodeshave been consumed. Using the ActiveMQ console, you can either:- Remove any undelivered events in the Virtual Topic,
VirtualTopic.alfresco.repo.events.nodesand associated queue,Consumer.<guid>.VirtualTopic.alfresco.repo.events.nodes. - Delete the Virtual Topic,
VirtualTopic.alfresco.repo.events.nodesand associated queue,Consumer.<guid>.VirtualTopic.alfresco.repo.events.nodes.
Here,
guidis the synchronization server id, which can be determined from thesyncServiceIdCheckin the health check response,https://localhost:9090/alfresco/healthcheck.Note that the Virtual Topic and associated queue will be recreated automatically.
- Remove any undelivered events in the Virtual Topic,
-
Restore the repository database. See Back up and restore the repository.
-
Restore the Sync Service database using your database vendor's backup/restore tools.
-
Restart the Sync Service with the following additional command line parameter:
-Drecover=<repo admin username>:<repo admin password>The Sync Service will ensure that it and the repository are in sync during bootstrap, before becoming available for requests.
-