Upgrade the primary database, and then copy the upgraded database and transaction log to the mirror. The mirroring system is temporarily stopped. Upgrading databases is generally performed when updating to a major version or minor release of the software.
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 start or stop network database servers.
To upgrade a database, you must have the ALTER DATABASE system privilege, and must be the only connection to the database
To rebuild (unload/reload) a database using the Unload utility (dbunload), you must have the SELECT ANY TABLE system privilege. For an unload with a reload, you must also have the SERVER OPERATOR system privilege.
Test the following steps in non-production environment with your application before performing the steps in a production environment.
Install the new version of the software on each computer in the system. All database servers in a database mirroring system must use the same maintenance version of SQL Anywhere.
Make a backup of the primary database, copy the backup, and validate the copy of the backup.
For example, run the following command to back up a database named mydb.db:
dbbackup -c "DBN=mydb;ENG=myserver;UID=DBA;PWD=sql" backup-dir
Create a copy of the backup:
xcopy backup-dir\*.db validatebackup-dir\backupmydb.db
Validate the backup 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.
Stop the servers in the following order:
|Upgrade the database||
Run the Upgrade utility (dbupgrad) on the primary database. For example:
The database is upgraded, a new transaction log is created, and the database is stopped. You can delete the old transaction logs.
|Rebuild (unload/reload) the database||
Copy the upgraded or rebuilt database and its new transaction log to the mirror server and any scale-out copy nodes.
Start the servers in the following order:
Discuter à propos de cette page dans DocCommentXchange.
|Copyright © 2013, SAP AG ou société affiliée SAP - SAP Sybase SQL Anywhere 16.0|