Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SAP Sybase SQL Anywhere 16.0 » SQL Anywhere 16 - Changes and Upgrading » How to upgrade to SQL Anywhere 16 » Upgrades and rebuilds in a database mirroring system

 

Updating the database server software to a major version for a mirroring system without rebuilding the database

Update the software of the database servers in a mirroring system by installing the software, stopping each database server, and starting the databases on servers running the new software. The database itself is not upgraded or rebuilt.

Prerequisites

You must have the BACKUP DATABASE system privilege. You must be the owner of the database, or have the VALIDATE ANY OBJECT system privilege.

By default, you must have the SERVER OPERATOR system privilege to stop network database servers.

Context and remarks

Test the following steps in non-production environment with your application before performing the steps in a production environment.

All database servers in a database mirroring system must use the same minor release of SQL Anywhere. So, the mirroring system stops temporarily during the update.

 Apply a SQL Anywhere major version to a database mirroring system
  1. Make a backup of the primary database, copy the backup, and validate the copy of the backup.

    For example, the following command backs up a database named mydb.db:

    dbbackup -c "DBN=mydb;ENG=myserver;UID=DBA;PWD=sql" backup-dir

    To create a copy of the backup and apply the transaction logs to the copy of the backup, run the following commands:

    xcopy backup-dir\mydb.db validatebackup-dir
    xcopy backup-dir\mydb.log validatebackup-dir
    

    Validate this copy.

    dbvalid -c "DBF=validatebackup-dir\backupmydb.db;UID=DBA;PWD=sql"

    If the copy of the backup does not validate, then fix the problems that cause the validation to fail before proceeding. Otherwise, you risk losing data.

  2. Install the new software on the primary, mirror, and arbiter servers.

  3. If the mirroring system is involved in read-only scale-out, install the software on the copy nodes.

  4. Stop the servers in the following order:

    1. copy nodes

    2. mirror server

    3. primary server

    4. arbiter server

    For example, run the Stop utility (dbstop):

    dbstop -y -c "UID=DBA;PWD=sql;Server=myserver"
  5. (Optional) Upgrade or rebuild the databases.

  6. Start the databases on the new servers in the following order:

    1. arbiter server, primary server, and mirror server

    2. copy nodes

Results

The databases in the mirroring system run on the new version of the software.

Next

Examine the database mirroring system to confirm that the update completed properly, and test the database mirroring system with your application.

 See also