With the growing need for organizations to distribute their data in remote locations, geodatabase replication can help to manage the changes made between geodatabases in different locations. When working with distributed and remote geodatabases it is often asked, “What is the best method to create and setup replicas?”
Working over a WAN (wide area network) or the Internet in disconnected environments is often simplified by using a geodata service to create replicas and synchronize edits for replicas. Using the Create Replica from Servertool can be useful when needing to create replicas on smaller datasets, but because this tool processes the data and replica registration in one step, it may not be a good fit for larger datasets. What is a suitable workflow to follow when the datasets to be replicated are very large?
Due to the size of data it is often not possible to create the replica using a geodata service where the data is being created and transported to the relative replica geodatabase during this replica creation process. In these cases it is better to manually transport the data from the parent geodatabase to the child location and then register the replica with the register with existing data option. The option of replicating with a disconnected workflow by creating the replica and transporting using a geodatabase or an XML workspace document is another option. Keep in mind this XML file has the potential of being very large as it will contain the data and the replica registration.
It may be better just to copy the data to the remote location first, and then create the replica registration by using the Create Replica wizard saved to an XML document that uses the 'Register with existing data' option. Then, this XML document can be imported to the child geodatabase to finalize the replica registration (use the data option on the Import XML workspace document when importing to the child geodatabase.)
In this workflow there will be an example of first transporting the data to be replicated to the destination geodatabase and then creating the replica registration via a geodata and map service with the register with existing data option.
When using the register with existing data option during the replica creation, there are several things to keep in mind.
Geoprocessing tools like Create Replica from Server and Create Replica cannot be used with this option as it is only available in ArcMap via the Distributed Geodatabase toolbar.
There are several requirements or prerequisites for the data when using the 'Register with existing data option' during the replica creation / registration:
GlobalIDS must exist on the data that will be included in the replica prior to copying to the destination geodatabase.
The data must match exactly on parent and child geodatabase.
Map services and geodata services must have their data sources registered as data stores prior to publishing. Please see the About registering your data with server help reference for more information about registering data stores.
Create/Register the Replica via a Geodata/Map Service
This workflow assumes that the data has previously been copied to the destination geodatabase and uses tools to register the data that are included in the replica to start tracking the changes between parent and child replica geodatabases. This data may already exist in both locations or can be easily transferred via database restore, etc. The steps use a map service to specify the exact datasets that will be registered within the replica and a geodata service component to communicate with the remote geodatabase to create/register the replica. Using the geodata enabled map service allows for the Distributed Geodatabase toolbar to become enabled to use the Create Replica tool with the register with existing data option.
Copy data to the destination geodatabase and follow all the prerequisites for distributed data/replication.
Register data stores for the geodatabase that the geodata and map services will be published from.
On the parent geodatabase server, create a map document with the data that will be included in the replica and publish this as a map service. Note: Make sure to use the same name as the geodata service and place the map service in the same location as the geodata service. (Publishing a map service)
On the child geodatabase server, browse to the GIS Servers and add the previously created map service to a new ArcMap document. On the Distributed Geodatabase toolbar, launch the Create Replica tool and create a replica using the specific replica type needed (for example, two-way).
Within the ‘What do you want to replicate?’ section, select ‘Register with existing data only’.
Select the local child geodatabase within the ‘Which geodatabase do you want to replicate data to?’ section.
Provide the replica with a name.
Optionally, select ‘Show advanced options for overriding replica defaults when I click next’ to change the geodatabase model to full or simple and to select the Spatial extent for the replica.
After this process completes, the Replica Manager can be accessed from parent and child replica geodatabases to ensure that the replica has registered properly. The geodata service can then be used to synchronize changes when needed.
Check out the ArcGIS Resource center for help topics working with Geodatabase Replication and Distributed data to learn more about different scenarios of using replication based on your organization’s needs.