Postgres Plus xDB Replication Server with Multi-Master User's Guide : 9.2 Upgrading Existing SMR Systems to xDB with Multi-Master

Previous PageTable Of ContentsNext Page

Postgres Plus Advanced Server xDB Replication Server User's Guide

 

9.2 Upgrading Existing SMR Systems to xDB with Multi-Master

If you are currently running an older version of xDB Replication Server with single-master replication systems that were created with Advanced Server 8.4 or later, you can install xDB Replication Server with Multi-Master and upgrade your existing single-master replication systems to run under the new version of xDB Replication Server with Multi-Master.

Note: Replication systems created using Postgres Plus Replication Server supplied with Postgres Plus Advanced Server 8.3 R2 or prior releases, cannot be upgraded to run under xDB Replication Server with Multi-Master.

Upgraded replication systems still run as single-master replication systems, but are managed by the xDB Replication Console, the xDB Replication Server CLI, and the publication and subscription servers of the new xDB Replication Server with Multi-Master product.

This section describes how to perform this upgrade.

Note: The process of upgrading from xDB Replication Server supplied with Advanced Server 8.4 differs in certain ways than upgrading from xDB Replication Server supplied with Advanced Server 9.0 or 9.1. Upgrading from xDB Replication Server supplied with Advanced Server 8.4 will simply be referred to as “upgrading from 8.4” in the remainder of this section. Upgrading from xDB Replication Server supplied with Advanced Server 9.0 or 9.1 will be referred to as “upgrading from 9.0/9.1”.

The following points should be noted about the upgrade process:

    ● The upgrade process consists of the following phases: 1) Install the new xDB Replication Server with Multi-Master product. 2) Upgrade your existing single-master replication systems so they run under the new xDB Replication Server with Multi-Master product. (Phases 1 and 2 can be done separately, or at the same time when upgrading from 9.0/9.1. When upgrading from 8.4, phases 1 and 2 occur simultaneously.) 3) Verify that the upgrade of your existing replication systems are successful. 4) After upgrading from 9.0/9.1, uninstall the old xDB Replication Server product. Upgrading from 8.4 replaces the old xDB Replication Server product with the new product so there is no need to perform an uninstall operation.

    ● In order to run your existing single-master replication systems using xDB Replication Server with Multi-Master, the xDB Control database and the metadata database objects in the publication databases of the existing replication systems must be upgraded. This upgrade is performed by the publication server of the new xDB Replication Server with Multi-Master product when it is started and connects for the first time to the xDB Control database containing the metadata of your existing replication systems.

    ● The upgrade results in the addition of new tables to the xDB Control database and to the metadata in the publication databases, as well as modifications to some of the existing database objects in this metadata. Once you have upgraded the xDB Control database and the metadata in the publication databases, you cannot revert back to using the old xDB Replication Server product with the replication systems of this upgraded xDB Control database.

    ● Only one xDB Replication Server product can be running on a host at any given time. The xDB Replication Server product in use must be connected to a compatible xDB Control database. Therefore, when you switch the xDB Replication Server products you are running, you must make sure the xDB Replication Configuration file contains the connection information for the correct version of the xDB Control database (see Section 2.3.1.4).

When upgrading from 9.0/9.1, the first consideration is to decide whether you want to: a) immediately upgrade existing single-master replication systems at the time you install xDB Replication Server with Multi-Master, or b) defer upgrading existing single-master replication systems to a later point in time after installing xDB Replication Server with Multi-Master.

If you choose option (b), any replication systems that you build with xDB Replication Server with Multi-Master before upgrading will not be able to run simultaneously with your old replication systems. Even after you upgrade your old xDB Control database and its replication systems, you will end up with two xDB Control databases with two sets of replication systems, and only one xDB Control database can be used at any given time by xDB Replication Server.

When upgrading from 8.4, option (a) is the only choice.

The next section describes upgrading from 8.4. Upgrading from 9.0/9.1 is described in Section 9.2.2.

9.2.1 Upgrading from Advanced Server 8.4 xDB Replication Server

This section describes how to upgrade the xDB Replication Server product supplied with Advanced Server 8.4 to xDB Replication Server with Multi-Master.

The upgrade process completely replaces the old xDB Replication Server product with the new xDB Replication Server with Multi-Master product.

Step 1: Install Java runtime version 1.6 or later if it is not already installed on your host. Any Java product such as Oracle Java or OpenJDK may be used. (xDB Replication Server with Multi-Master requires version 1.6 or later. xDB Replication Server supplied with Advanced Server 8.4 uses version 1.5.)

Step 2: Stop the subscription server and the publication server of the old xDB Replication Server product using the stop option of the Linux scripts or Windows services described in Step 1 of Section 5.3.1 for the subscription server and Step 1 of Section 5.2.1 for the publication server.

Be sure to use the proper script names for your old version of xDB Replication Server, as these script names may change from version to version.

Step 3: In the XDB_HOME/etc directory of your xDB Replication Server product, save a copy of the publication and subscription server configuration files if they exist, in case there are non-default settings you wish to carry over to the new configuration files after the new product installation completes. The old configuration files are overwritten by new configuration files during the installation process, and any non-default settings must be changed in the new files.

Note: The earlier versions of xDB Replication Server with Advanced Server 8.4 did not have publication and subscription server configuration files. These were added in later versions of xDB Replication Server.

Step 4: Install the new xDB Replication Server with Multi-Master product. See Chapter 3 for complete instructions on installing xDB Replication Server, but note the following differences.

Step 5: Following the acceptance of the license agreement in Step 11 of Section 3.1, the Select Components screen appears, but with the entries grayed out. The old xDB Replication Server components are replaced by the new ones in the old xDB Replication Server’s directory location. Click the Next button.

Figure 248 - Select components

Step 6: Depending upon whether you are using Stack Builder or StackBuilder Plus, the Account Registration screen may appear at this point. Select the appropriate choice in the Account Registration screen and enter your EnterpriseDB user account information or create a new account to complete the registration process.

Figure 249 - Account registration

Step 7: The Existing Installation screen confirms that the xDB Replication Server supplied with Advanced Server 8.4 was found. Click the Next button to proceed with the upgrade.

Figure 250 - Existing installation

Step 8: On the Ready to Install screen, click the Next button.

Figure 251 - Ready to install

Step 9: The remaining screens that appear confirm completion of the installation process and allow you to exit from Stack Builder or StackBuilder Plus.

After installation completes, the publication server and subscription server of the new xDB Replication Server product should be running, connected to the upgraded xDB Control database containing your upgraded replication systems.

You can verify that the upgrade was successful by examining the following:

    ● In the xDB Control database, five new tables should be present under the _edb_replicator_pub schema: erep_conflicts, erep_conflicts_options, erep_events, erep_events_status, and erep_mmr_pub_group.

    ● In the metadata in each publication database, five new tables should be present: rrep_mmr_pub_group, rrep_mmr_txset, rrep_properties, rrep_publication_subscriptions, and rrep_txset_health.

If these tables are not present, verify that the xDB Replication Configuration file contains the correct connection information to the xDB Control database. Also, check the publication server log file for errors (see Section 9.3.2.4).

Step 10: Configure the new xDB Replication Server product.

In the XDB_HOME/etc directory of your xDB Replication Server product, update the publication server and subscription server configuration files with any non-default settings you may have used in your old configuration files. Do not completely replace the new configuration files with your old files as the new configuration files contain new options added for the new version of xDB Replication Server. See Section 9.4.1 for information on the publication and subscription server configuration options and configuration files.

Step 11: Verify that the publication server and subscription server are running. If they are not running, or if you have changed any configuration options, restart the publication server and the subscription server (see sections 5.2.1 and 5.3.1).

Step 12: Check the publication server and subscription server log files to verify that no errors have occurred (see Section 9.3.2.4).

Step 13: You are now ready to begin using xDB Replication Server with Multi-Master to create and manage replication systems.

Follow the directions in Chapter 5 to create single-master replication systems. Follow the directions in Chapter 6 to create multi-master replication systems.

The publication and subscription database nodes, and their publications and subscriptions that were created under the old xDB Replication Server product should be visible in the replication tree of the xDB Replication Console after you register the publication server and subscription server.

Note: Be sure to enter the port number in the Register Publication Server dialog box used by the publication server in the 8.4 replication system, which is 9011 by default. xDB Replication Server supplied with Advanced Server 8.4, used a default port number of 9011 for the publication server. (For xDB Replication Server with Multi-Master the default port number is 9051.)

Figure 252 - Register Publication Server with 8.4 default port number

Similarly, in the Register Subscription Server dialog box, enter the port number used by the subscription server in the 8.4 replication system, which is 9012 by default. In xDB Replication Server supplied with Advanced Server 8.4, the default port was 9012 for the subscription server. (For xDB Replication Server with Multi-Master the default is 9052.)

9.2.2 Upgrading from Advanced Server 9.0/9.1 xDB Replication Server

This section describes how to upgrade your replication systems built with the xDB Replication Server product supplied with Advanced Server 9.0 or 9.1 to run under xDB Replication Server with Multi-Master.

The following describes how you can make the choice of whether or not to upgrade your existing replication systems while installing xDB Replication Server with Multi-Master.

Section 9.2.2.2 contains directions for upgrading your existing replication systems at a later time if you choose to install xDB Replication Server with Multi-Master without upgrading your existing replication systems.

9.2.2.1 Upgrading While Installing xDB with Multi-Master

Step 1: Stop the subscription server and the publication server of the old xDB Replication Server product using the stop option of the Linux scripts or Windows services described in Step 1 of Section 5.3.1 for the subscription server and Step 1 of Section 5.2.1 for the publication server.

Be sure to use the proper script names for your old version of xDB Replication Server, as these script names may change from version to version.

Step 2: Install the new xDB Replication Server with Multi-Master product. See Chapter 3 for complete instructions on installing xDB Replication Server.

In general, specify the same options as used for your old xDB Replication Server product with the exceptions noted by the following.

In the Installation Directory window of Step 12 in Section 3.1, be sure to specify a new, different directory location than where your old xDB Replication Server product is installed.

In the Postgres Plus Installation Details window of Step 15 in Section 3.1, if you decided to immediately upgrade the existing xDB Control database and its replication systems, specify the same connection information as used by this existing xDB Control database. If you decided to defer upgrading of the existing xDB Control database and its replication systems, specify connection information that will result in the creation of a new xDB Control database, such as specifying a new Control database name.

After installation completes, the publication server and subscription server of the new xDB Replication Server product should be running, connected to the xDB Control database whose connection information you specified in the Postgres Plus Installation Details window. Thus, if you chose to upgrade existing replication systems, the servers are connected to the upgraded xDB Control database containing your upgraded replication systems. If you chose not to upgrade existing replication systems, the servers are connected to a new, empty xDB Control database.

For Linux only: The xDB Replication Configuration file, /etc/edb-repl.conf, is updated to contain the connection information you specified in the Postgres Plus Installation Details window. On Linux, there is one such file on the host. The prior connection information in the xDB Replication Configuration file is overwritten. If you later want to start the publication and subscription servers using the old, pre-upgrade xDB Control database, you must edit the connection information in the xDB Replication Configuration file to connect to the old xDB Control database.

For Windows only: The xDB Replication Configuration file, XDB_HOME\etc\edb-repl.conf, contains the connection information you specified in the Postgres Plus Installation Details window. On Windows systems unlike Linux, there is a separate xDB Replication Configuration file for each installed xDB Replication Server product. Thus, the connection information to the old xDB Control database is preserved in its own xDB Replication Configuration file, which is used when you start the publication and subscription services of the old xDB Replication Server product.

Step 3: If you chose to immediately upgrade your xDB Control database and existing replication systems in Step 2, you can verify that the upgrade was successful by examining the following:

    ● In the xDB Control database, five new tables should be present under the _edb_replicator_pub schema: erep_conflicts, erep_conflicts_options, erep_events, erep_events_status, and erep_mmr_pub_group.

    ● In the metadata in each publication database, five new tables should be present: rrep_mmr_pub_group, rrep_mmr_txset, rrep_properties, rrep_publication_subscriptions, and rrep_txset_health.

If these tables are not present, verify that the xDB Replication Configuration file contains the connection information to the xDB Control database you intended to upgrade. Also, check the publication server log file for errors (see Section 9.3.2.4).

If you did not choose to immediately upgrade your existing replication systems in Step 2, these tables do not appear in the old xDB Control database and in the publication databases. Instead, a new xDB Control database is created that includes the new tables listed in the first bullet point.

Step 4: Configure the new xDB Replication Server product.

In the XDB_HOME/etc directory of your new xDB Replication Server product, update the new publication server and subscription server configuration files with any non-default settings you may have used in your old configuration files. Do not completely replace the new configuration files with your old files as the new configuration files contain new options added for the new version of xDB Replication Server. See Section 9.4.1 for information on the publication and subscription server configuration options and configuration files.

For Oracle only: If you are using Oracle publication or subscription databases, copy the Oracle JDBC driver, ojdbc14.jar, to the XDB_HOME/lib/jdbc directory of the new xDB Replication Server product (see Section 5.1.1.1).

Step 5: Verify that the publication server and subscription server are running. If they are not running, or if you have changed any configuration options or added the Oracle JDBC driver in Step 4, restart the publication server and the subscription server (see sections 5.2.1 and 5.3.1).

Step 6: Check the publication server and subscription server log files to verify that no errors have occurred (see Section 9.3.2.4).

Step 7: You are now ready to begin using xDB Replication Server with Multi-Master to create and manage replication systems.

Follow the directions in Chapter 5 to create single-master replication systems. Follow the directions in Chapter 6 to create multi-master replication systems.

If you upgraded an existing xDB Control database and its replication systems, the publication and subscription database nodes, and their publications and subscriptions that were created under the old xDB Replication Server product should be visible in the replication tree of the xDB Replication Console after you register the publication server and subscription server.

Step 8: When you so choose, uninstall the old xDB Replication Server product.

For Linux only: Make a copy of the xDB Replication Configuration file, /etc/edb-repl.conf, before uninstalling xDB Replication Server. The uninstallation process deletes the xDB Replication Configuration file. As the root account, run script XDB_HOME/uninstall-replicationserver of the old xDB Replication Server product to uninstall it. After uninstalling the old product, copy the saved xDB Replication Configuration file back to the /etc directory.

For Windows only: In Control Panel, select Programs, then Uninstall a Program. Uninstall the old xDB Replication Server product.

9.2.2.2 Upgrading After Installing xDB with Multi-Master

If you have installed xDB Replication Server with Multi-Master and chose not to upgrade your old xDB Control database and its replication systems during the installation process, but are now ready to do so, perform the following steps.

Step 1: Stop the subscription server and the publication server using the stop option of the Linux scripts or Windows services described in Step 1 of Section 5.3.1 for the subscription server and Step 1 of Section 5.2.1 for the publication server.

Step 2: Modify the xDB Replication Configuration file (/etc/edb-repl.conf for Linux, XDB_HOME\etc\edb-repl.conf for Windows where XDB_HOME is the installation directory of xDB Replication Server with Multi-Master) so it contains the connection information of the old xDB Control database you wish to upgrade. See Section 2.3.1.4 for information on the xDB Replication Configuration file.

Step 3: Start the publication server and subscription server of the xDB Replication Server with Multi-Master product. See Step 1 of Section 5.2.1 for directions on starting the publication server. See Step 1 of Section 5.3.1 for directions on starting the subscription server.

Step 4: Verify that the upgrade was successful. See Step 3 of Section 9.2.2.1.

Step 5: Check the publication server and subscription server log files to verify that no errors have occurred (see Section 9.3.2.4).

Step 6: The publication and subscription database nodes, and their publications and subscriptions that were created under the old xDB Replication Server product should be visible in the replication tree of the xDB Replication Console after you register the publication server and subscription server.

Previous PageTable Of ContentsNext Page