Automate replication to a standby deployment
Once you have created your primary and standby ArcGIS Enterprise deployments, you can automate replication from the primary to the standby using the Web GIS Disaster Recovery (WebGISDR) tool, separate properties files for full and incremental backups, and create a scheduled task using a cron job.
Once you have created your primary and standby ArcGIS Enterprise deployments, you can automate replication from the primary to the standby using the Web GIS Disaster Recovery (WebGISDR) tool, separate properties files for full and incremental backups, and create a scheduled task using Windows Task Scheduler.
To keep your primary and standby deployments more closely synchronized, create full backups on a regular schedule using the WebGISDR tool, but export incremental changes between full backups. For example, if the services and data in your ArcGIS Enterprise deployment change a fair amount in a day, you might create a full backup at midnight, and export incremental changes at 10:00 a.m., 2:00 p.m., and 6:00 p.m. to pick up changes that occurred throughout the workday.
To automate this, create four copies of the template properties file (webgisdr.properties) and four different scripts to complete the following tasks:
Export full backups from the primary deployment and copy files to the standby deployment.
Export incremental backups from the primary deployment and copy to the standby deployment.
Import full backups to the standby deployment.
Import incremental backups to the standby deployment.
Set a cron job to run each script at specific times.
Use Windows Task Scheduler to run each script at specific times.
When deciding how frequently to run the scripts, you need to account for the time it takes to complete the export and copy the data. You'll need to run through this manually first to get an idea of how long it takes to create a full backup and copy it over your network to the standby deployment, and how long it takes to create incremental backups and copy them over your network to the standby deployment. Include a buffer of 30 to 60 minutes to account for fluctuations in network and hardware performance.
For example, if it takes 20 minutes to create an incremental backup and 5 minutes to copy it to the standby, schedule the import of the incremental backup to take place an hour after the incremental backup script runs. So if the script to create an incremental backup runs at 10:00 a.m., schedule the import to run at 11:00 a.m.
Make a copy of the
webgisdr.propertiesfile and name itexpfullbackups.properties. Save the file in the same location as thewebgisdr.propertiesfile.The default location is
/arcgis/portal/tools/webgisdr.The default location is
C:\Program Files\Portal\tools\webgisdr.Open the
expfullbackups.propertiesfile in a text editor, and edit it to include information specific to your deployment. For more information, see WebGISDR tool properties file.Save changes and close the
expfullbackups.propertiesfile.Make a copy of the
expfullbackups.propertiesfile and name itexpincremental.properties.Open the
expincremental.propertiesfile in a text editor and change theBACKUP_RESTORE_MODEsetting toincremental.Save changes and close the
expincremental.propertiesfile.Create two scripts that will run the WebGISDR tool to export from your primary deployment. Set one to call the
expfullbackups.propertiesfile and set the other to call theexpincremental.propertiesfile.You create two scripts so you can schedule one to run at specific times to create full backups and one to run at other times to create the incremental backups.
For example, the line you put in the script to create full backups would contain something similar to the following:
webgisdr --export --file /arcgis/portal/tools/webgisdr/fullbackups.propertiesThe scripts you use to export backups need to include a way to copy the backup files to the standby deployment.
The account that installed ArcGIS Server, Portal for ArcGIS, and ArcGIS Data Store in the primary deployment must have write access to the
SHARED_LOCATIONset in the.propertiesfile. Additionally, the account running the WebGISDR tool must have read and write privileges on theSHARED_LOCATIONand the location to which you copy the backup files. The account that installed ArcGIS Server, Portal for ArcGIS, and ArcGIS Data Store in the standby deployment must have at least read privileges on these locations.The domain account that runs the ArcGIS Server, Portal for ArcGIS, and ArcGIS Data Store services on the primary deployment must have write access to the
SHARED_LOCATIONset in the.propertiesfile. Additionally, the account running the WebGISDR tool must have write access to theSHARED_LOCATIONand the location to which you copy the backup files. The domain account that runs the ArcGIS Server, Portal for ArcGIS, and ArcGIS Data Store services on the standby deployment must have at least read access to these locations.If your ArcGIS Enterprise deployment includes map service and hosted tile layer caches, the scripts also need to copy these from the cache director (or directories) of the ArcGIS Server sites in your primary deployment to the cache directory (or directories) on the standby deployment.
Copy the
expfullbackups.propertiesandexpincremental.propertiesfiles to the location of thewebgisdr.propertiesfile on the standby deployment (/arcgis/portal/tools/webgisdrby default), and rename the filesimpfullbackups.propertiesandimpincremental.properties, respectively.Copy the
expfullbackups.propertiesandexpincremental.propertiesfiles to the location of thewebgisdr.propertiesfile on the standby deployment (C:\Program Files\Portal\tools\webgisdrby default), and rename the filesimpfullbackups.propertiesandimpincremental.properties, respectively.Update the
SHARED_LOCATION,BACKUP_LOCATION(if theBACKUP_STORE_PROVIDERis set toFileSystem), andPORTAL_ADMIN_URLin the properties for the standby deployment's environment.Schedule the WebGISDR tool to run on the primary and standby deployments. You can do this using a cron job. Define your backup schedule and set up automated tasks to point to the appropriate properties file. The two scripts that will import the backups need to call the properties files you copied to the standby deployment.
Schedule the WebGISDR tool to run on the primary and standby deployments. You can do this using the Windows Task Scheduler. Define your backup schedule and set up automated tasks to point to the appropriate properties file. The two scripts that will import the backups need to call the properties files you copied to the standby deployment.
Tip:
As mentioned in the introduction, you'll need to estimate the time it takes to complete full and incremental backups and to copy the backup files, add a buffer time, and schedule your scripts to run accordingly.