Chapter 9. Deploying and Synchronizing Databases

Synchronizing databases

What is synchronization? SQL Remote replication is carried out using the information in the transaction log, but there are two circumstances where SQL Remote deletes all existing rows from those tables of a remote database that form part of a publication, and copies the publication’s entire contents from the consolidated database to the remote site. This process is called synchronization.

When to synchronize Synchronization is used under the following circumstances:

When a subscription is created at a consolidated database a synchronization is carried out, so that the remote database starts off with a database in the same state as the consolidated database.

If a remote database gets corrupt or gets out of step with the consolidated database, and cannot be repaired using SQL passthrough mode, synchronization forces the remote site database back in step with the consolidated site.

How to synchronize Synchronizing a remote database can be done in the following ways:

Use the database extraction utility This utility creates a schema for a remote Adaptive Server Anywhere database, and synchronizes the remote database. This is generally the recommended procedure.

Manual synchronization Synchronize the remote database manually by loading from files, using the PowerBuilder pipeline, or some other tool.

Synchronize over the message system Synchronize the remote database via the message system using the SYNCHRONIZE SUBSCRIPTION statement (Adaptive Server Anywhere ) or sp_subscription synchronizeprocedure (Adaptive Server Enterprise).

Caution

Do not execute SYNCHRONIZE SUBSCRIPTION or sp_subscription synchronizeat a remote database.

Mixed operating systems and database extraction

In many installations, the consolidated server will be running on a different operating system than the remote databases.

Adaptive Server Anywhere databases can be copied from one file or operating system to another. This allows you flexibility in how you carry out your initial synchronization of databases.

189

Page 207
Image 207
Sybase DC38133-01-0902-01 manual Synchronizing databases, Mixed operating systems and database extraction