Wednesday, June 15, 2011

Creating an Oracle physical standby database

Data Guard is an Oracle technology that enables you to replicate one database and keep it up to date according to selected levels of performance and protection; you can have one or more standby databases that you can open in read-only mode for reporting purposes (physical standby) or in read-write mode if you don't change the replicated data (logical standby). Data Guard is a very useful technology for disaster recovery and more so be sure to read all the documentation listed at the end of this post. In the following example is described the easiest scenario: creating a physical standby database in a different server from the primary database, with the same paths, in maximum performance mode, copying the primary database with operating system commands (no ASM).

This example is written in a way you can create quickly and easily a standby database, but don't be mislead by this and skip reading the documentation; the more you study Data Guard technology the less problems you will have trying different scenarios and configurations and troubleshooting your standby database.

The first and most difficult part of creating a standby database is configuring the primary database, therefore we will begin activating the force logging at the primary database:

oracle@primarysrv:/opt/oracle/product/10.2.0/db_1/dbs$ sqlplus / as sysdba

SQL*Plus: Release 10.2.0.1.0 - Production on Tue Jun 7 12:49:25 2011

Copyright (c) 1982, 2005, Oracle. All rights reserved.


Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining Scoring Engine options

SQL> select FORCE_LOGGING from v$database;

FOR
---
NO

SQL> ALTER DATABASE FORCE LOGGING;

Database altered.

SQL> select FORCE_LOGGING from v$database;

FOR
---
YES

Next we will get redo log file information as number of groups, threads, members' path and size, and we will create standby log files the same size as log files, adding an extra group for each thread for standby log files:

SQL> select GROUP#, MEMBER from v$logfile order by GROUP#;

GROUP# MEMBER
---------- ----------------------------------------
1 /primarydb/logfile/redo01.rdo
1 /fra/primarydb/logfile/redo01.rdo
2 /primarydb/logfile/redo02.rdo
2 /fra/primarydb/logfile/redo02.rdo
3 /primarydb/logfile/redo03.rdo
3 /fra/primarydb/logfile/redo03.rdo

6 rows selected.

SQL> select GROUP#, THREAD#, BYTES from v$log order by GROUP#;

GROUP# THREAD# BYTES
---------- ---------- ----------
1 1 134217728
2 1 134217728
3 1 134217728

SQL> ALTER DATABASE ADD STANDBY LOGFILE GROUP 4 ('/primarydb/logfile/stdby01.rdo',
'/fra/primarydb/logfile/stdby01.rdo') SIZE 134217728;

Database altered.

SQL> ALTER DATABASE ADD STANDBY LOGFILE GROUP 5 ('/primarydb/logfile/stdby02.rdo',
'/fra/primarydb/logfile/stdby02.rdo') SIZE 134217728;

Database altered.

SQL> ALTER DATABASE ADD STANDBY LOGFILE GROUP 6 ('/primarydb/logfile/stdby03.rdo',
'/fra/primarydb/logfile/stdby03.rdo') SIZE 134217728;

Database altered.

SQL> ALTER DATABASE ADD STANDBY LOGFILE GROUP 7 ('/primarydb/logfile/stdby04.rdo',
'/fra/primarydb/logfile/stdby04.rdo') SIZE 134217728;

Database altered.

SQL> SELECT GROUP#, THREAD#, SEQUENCE#, ARCHIVED, STATUS FROM V$STANDBY_LOG;

GROUP# THREAD# SEQUENCE# ARC STATUS
---------- ---------- ---------- --- ----------
4 0 0 YES UNASSIGNED
5 0 0 YES UNASSIGNED
6 0 0 YES UNASSIGNED
7 0 0 YES UNASSIGNED

After creating standby log file groups we will check if the database is in archive mode, has a password file and the remote_login_passwordfile parameter is properly set; if not we will create a password file and activate the archive mode:

SQL> show parameter REMOTE_LOGIN_PASSWORDFILE

NAME TYPE VALUE
------------------------------------ -------------------- --------------
remote_login_passwordfile string EXCLUSIVE

SQL> select * from V$PWFILE_USERS;

no rows selected

SQL> select NAME, LOG_MODE from v$database;

NAME LOG_MODE
--------- ------------
primarydb NOARCHIVELOG

SQL> SHUTDOWN IMMEDIATE;
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining Scoring Engine options
oracle@primarysrv:~$ cd $ORACLE_HOME/dbs
oracle@primarysrv:/opt/oracle/product/10.2.0/db_1/dbs$ orapwd FILE=orapwprimarydb password="somepassword"
oracle@primarysrv:/opt/oracle/product/10.2.0/db_1/dbs$ sqlplus '/ as sysdba'

SQL*Plus: Release 10.2.0.1.0 - Production on Fri Jun 10 11:34:18 2011

Copyright (c) 1982, 2005, Oracle. All rights reserved.


Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining Scoring Engine options

SQL> STARTUP MOUNT;
ORACLE instance started.

Total System Global Area 268435456 bytes
Fixed Size 1218892 bytes
Variable Size 92276404 bytes
Database Buffers 171966464 bytes
Redo Buffers 2973696 bytes
Database mounted.
SQL> ALTER DATABASE ARCHIVELOG;

Database altered.

SQL> ALTER DATABASE OPEN;

Database altered.

SQL> select NAME, LOG_MODE from v$database;

NAME LOG_MODE
--------- ------------
primarydb ARCHIVELOG

SQL> alter user SYS identified by "mypassword";

User altered.

SQL> select * from V$PWFILE_USERS;

USERNAME SYSDB SYSOP
------------------------------ ----- -----
SYS TRUE TRUE

In the previous step we created first a password file with a password and later changed the SYS password; in order to work the redo transport services both primary and standby databases have to have the same SYS password and a password file, therefore if there is no password file at the primary database you can first create it and later change the SYS password, create the password file with the proper password or just change the SYS password if it exist. But as long as you cannot open a physical standby database in read-write mode without turning it unsuitable for Data Guard purposes, you cannot change the SYS password with an ALTER USER statement so you have to create the standby database password file with the proper password.

Next we will set the parameters needed for a Data Guard configuration; you have to check all the 19 parameters listed below and change them as needed, and also you may have to check other parameters not listed related to server address or file system path.

SQL> column NAME format a30
SQL> column VALUE format a40
SQL> select NAME, VALUE from v$parameter where NAME in ('db_name','db_unique_name',
'log_archive_config','control_files','log_archive_dest','log_archive_dest_1',
'log_archive_dest_2','log_archive_dest_state_1','log_archive_dest_state_2',
'remote_login_passwordfile','log_archive_format','log_archive_max_processes','fal_server',
'fal_client','db_file_name_convert','log_file_name_convert','standby_file_management',
'db_recovery_file_dest','db_recovery_file_dest_size') order by NAME;

NAME VALUE
------------------------------ ----------------------------------------
control_files /primarydb/controlfile/primarydb01.ctl
, /fra/primarydb/controlfile/primarydb02.c
tl

db_file_name_convert
db_name primarydb
db_recovery_file_dest
db_recovery_file_dest_size 0
db_unique_name primarydb
fal_client
fal_server
log_archive_config
log_archive_dest /fra/archfile/
log_archive_dest_1
log_archive_dest_2
log_archive_dest_state_1 enable
log_archive_dest_state_2 enable
log_archive_format primarydb_%t_%s_%r.arc
log_archive_max_processes 2
log_file_name_convert
remote_login_passwordfile EXCLUSIVE
standby_file_management MANUAL

19 rows selected.

SQL> alter system set LOG_ARCHIVE_CONFIG='DG_CONFIG=(primarydb,standbydb)';

System altered.

SQL> alter system set log_archive_dest='';

System altered.

SQL> alter system set LOG_ARCHIVE_DEST_1='LOCATION=/fra/primarydb/archivelog VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=primarydb';

System altered.

SQL> alter system set LOG_ARCHIVE_DEST_2='SERVICE=standbydb LGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=standbydb';

System altered.

SQL> alter system set FAL_SERVER=standbydb;

System altered.

SQL> alter system set FAL_CLIENT=primarydb;

System altered.

SQL> alter system set standby_file_management=AUTO;

System altered.

SQL> select NAME, VALUE from v$parameter where NAME in ('db_name','db_unique_name',
'log_archive_config','control_files','log_archive_dest','log_archive_dest_1',
'log_archive_dest_2','log_archive_dest_state_1','log_archive_dest_state_2',
'remote_login_passwordfile','log_archive_format','log_archive_max_processes','fal_server',
'fal_client','db_file_name_convert','log_file_name_convert','standby_file_management',
'db_recovery_file_dest','db_recovery_file_dest_size') order by NAME;

NAME VALUE
------------------------------ ----------------------------------------
control_files /primarydb/controlfile/primarydb01.ctl
, /fra/primarydb/controlfile/primarydb02.c
tl

db_file_name_convert
db_name primarydb
db_recovery_file_dest
db_recovery_file_dest_size 0
db_unique_name primarydb
fal_client primarydb
fal_server standbydb
log_archive_config DG_CONFIG=(primarydb,standbydb)
log_archive_dest
log_archive_dest_1 LOCATION=/fra/primarydb/archivel
og VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB
_UNIQUE_NAME=primarydb

log_archive_dest_2 SERVICE=standbydb LGWR ASYNC VALID_FOR=(O
NLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_N
AME=standbydb

log_archive_dest_state_1 enable
log_archive_dest_state_2 enable
log_archive_format primarydb_%t_%s_%r.arc
log_archive_max_processes 2
log_file_name_convert
remote_login_passwordfile EXCLUSIVE
standby_file_management AUTO

19 rows selected.

You have to set values like above for your relevant Data Guard database parameters. After having done this, you are almost ready to copy your database to the standby server along with the database's pfile and a special control file:

SQL> SHUTDOWN IMMEDIATE;
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining Scoring Engine options
oracle@primarysrv:~$ sqlplus / as sysdba

SQL*Plus: Release 10.2.0.1.0 - Production on Wed Jun 8 12:18:44 2011

Copyright (c) 1982, 2005, Oracle. All rights reserved.

Connected to an idle instance.

SQL> STARTUP MOUNT;
ORACLE instance started.

Total System Global Area 268435456 bytes
Fixed Size 1218892 bytes
Variable Size 92276404 bytes
Database Buffers 171966464 bytes
Redo Buffers 2973696 bytes
Database mounted.
SQL> ALTER DATABASE CREATE STANDBY CONTROLFILE AS '/primarydb/standbydb.ctl';

Database altered.

SQL> CREATE PFILE='/primarydb/initstandbydb.ora' FROM SPFILE;

File created.

SQL> SHUTDOWN IMMEDIATE;
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining Scoring Engine options

At this point you can copy all the relevant database files (datafiles, tempfiles, online redo logs, standby redo logs, standby control file and pfile) with your favorite method and programs, like scp. Don't forget to place all the files at the same path, this example assumes that. If you put the database files in a different path, you have to set parameters like db_file_name_convert and log_file_name_convert (not covered in this post). Also, you have to create directories needed for parameters like background_dump_dest, core_dump_dest, user_dump_dest and audit_file_dest amongst others.

After that, you have to copy your standby control file to all the paths stated in the control_files parameter, using the same file names; you cannot use the original (primary) control file or you will get an error.

Finally, you have to modify some parameters in the standby pfile related to this new database; it would be handy to have the original primary pfile and the standby pfile and compare it as in the following example, just to be sure you modified everything properly. In this standby pfile there are no primarydb.__ parameters because they are related to parameters managed automatically by the Oracle instance but saved anyway with the CREATE PFILE statement, and the audit_trail parameter is set to OS, otherwise you need to open a database in read-write mode in order to save all the audit events at the database itself (DB value), but you cannot do so with a physical standby database. Also, there is the extra db_unique_name parameter with the name of the standby database, that by default is optional and the same as db_name (in this case primarydb) but mandatory in a standby database.

oracle@standbysrv:/primarydb$ diff initstandbydb.ora initprimarydb.ora
0a1,5
> primarydb.__db_cache_size=171966464
> primarydb.__java_pool_size=4194304
> primarydb.__large_pool_size=4194304
> primarydb.__shared_pool_size=83886080
> primarydb.__streams_pool_size=0
3,4c8,9
< *.audit_trail='os'
---
> *.audit_trail='db'
14,16c19,20
< *.db_unique_name='standbydb'
< *.fal_client='standbydb'
< *.fal_server='primarydb'
---
> *.fal_client='primarydb'
> *.fal_server='standbydb'
22,23c26,27
< *.log_archive_dest_1='LOCATION=/fra/primarydb/standbydb/archivelog VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=standbydb'
< *.log_archive_dest_2='SERVICE=primarydb LGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=primarydb'
---
> *.log_archive_dest_1='LOCATION=/fra/primarydb/primarydb/archivelog VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=primarydb'
> *.log_archive_dest_2='SERVICE=standbydb LGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=standbydb'

But before starting up your primary and standby databases, first you have to include in the tnsnames.ora files the primary and standby instance connection information like this, both in the primary and standby servers:

PRIMARYDB =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = primarysrv)(PORT = 1521))
)
(CONNECT_DATA = (SERVICE_NAME = primarydb))
)

STANDBYDB =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = standbysrv)(PORT = 1521))
)
(CONNECT_DATA = (SERVICE_NAME = standbydb))
)

Also, you have to have listeners configured for both primary and standby instances (change the listener.ora files as needed):

LISTENER_PRIMARYDB =(ADDRESS_LIST = (ADDRESS= (PROTOCOL=TCP) (HOST = primarysrv) (PORT = 1521)))

SID_LIST_LISTENER_PRIMARYDB =
(SID_LIST =
(SID_DESC =
(SID_NAME = primarydb)
(ORACLE_HOME = /opt/oracle/product/10.2.0/db_1)
(ORACLE_SID = primarydb)
)
)

CONNECT_TIMEOUT_LISTENER_PRIMARYDB=30

Start both primary and standby database listeners and check it with the tnsping command, in both primary and standby servers:

oracle@standbysrv:/primarydb$ tnsping primarydb

TNS Ping Utility for Linux: Version 10.2.0.1.0 - Production on 17-JUN-2011 12:23:42

Copyright (c) 1997, 2005, Oracle. All rights reserved.

Used parameter files:
/opt/oracle/product/10.2.0/db_1/network/admin/sqlnet.ora


Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = primarysrv)(PORT = 1521))
(CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = primarydb)))
OK (10 msec)
oracle@standbysrv:/primarydb$ tnsping standbydb

TNS Ping Utility for Linux: Version 10.2.0.1.0 - Production on 17-JUN-2011 12:23:42

Copyright (c) 1997, 2005, Oracle. All rights reserved.

Used parameter files:
/opt/oracle/product/10.2.0/db_1/network/admin/sqlnet.ora


Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = standbysrv)(PORT = 1521))
(CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = standbydb)))
OK (0 msec)

At this point you will be able to create a password file and start up your standby database:

oracle@standbysrv:/primarydb$ export ORACLE_SID=standbydb
oracle@standbysrv:/primarydb$ set|grep ORA
ORACLE_BASE=/opt/oracle
ORACLE_HOME=/opt/oracle/product/10.2.0/db_1
ORACLE_SID=standbydb
oracle@standbysrv:/primarydb$ cd $ORACLE_HOME/dbs
oracle@standbysrv:/opt/oracle/product/10.2.0/db_1/dbs$ orapwd FILE=orapwstandbydb password="mypassword"
oracle@standbysrv:/opt/oracle/product/10.2.0/db_1/dbs$ sqlplus / as sysdba

SQL*Plus: Release 10.2.0.1.0 - Production on Wed Jun 8 17:15:59 2011

Copyright (c) 1982, 2005, Oracle. All rights reserved.

Connected to an idle instance.

SQL> create spfile from pfile='/primarydb/initstandbydb.ora';

File created.

SQL> startup mount;
ORACLE instance started.

Total System Global Area 268435456 bytes
Fixed Size 1218892 bytes
Variable Size 88082100 bytes
Database Buffers 176160768 bytes
Redo Buffers 2973696 bytes
Database mounted.

If everything was done properly at the next step the standby database will contact the primary database and start the data sincronization, but first you have to start up your primary database as usual (open in read-write mode). Then, you start the data sincronization at the standby database:

SQL> alter database recover managed standby database disconnect from session;

Database altered.

SQL> select name, open_mode, database_role from v$database;

NAME OPEN_MODE DATABASE_ROLE
--------- ---------- ----------------
PRIMARYDB MOUNTED PHYSICAL STANDBY

And also you force a log change at the primary database in order to begin the transfer:

SQL> ALTER SYSTEM SWITCH LOGFILE;

System altered.

SQL> SELECT SEQUENCE#, FIRST_TIME, NEXT_TIME FROM V$ARCHIVED_LOG ORDER BY SEQUENCE#;

SEQUENCE# FIRST_TIME NEXT_TIME
---------- ----------- -----------
6 07-jun-2011 08-jun-2011
7 08-jun-2011 08-jun-2011
8 08-jun-2011 10-jun-2011
9 10-jun-2011 10-jun-2011

After waiting a bit you should see the same information at the standby database:

SQL> select sequence#, first_time, next_time from v$archived_log order by sequence#;

SEQUENCE# FIRST_TIME NEXT_TIME
---------- ------------------ ------------------
6 07-JUN-11 08-JUN-11
7 08-JUN-11 08-JUN-11
8 08-JUN-11 10-JUN-11
9 10-JUN-11 10-JUN-11

4 rows selected.

If you do, congratulations! Everything went fine and you now have a working standby physical database. As a nice extra, you can set automatic deletion of applied redo logs when your archive log file system is almost full, and also check your standby database opening it in read-only mode.

Let's configure automatic deletion of applied redo logs setting the following parameters at the standby database:

SQL> alter system set DB_RECOVERY_FILE_DEST_SIZE=2G;

System altered.

SQL> alter system set DB_RECOVERY_FILE_DEST='/fra/primarydb';

System altered.

SQL> alter system set LOG_ARCHIVE_DEST_1='LOCATION=USE_DB_RECOVERY_FILE_DEST';

System altered.

SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options

Set the DB_RECOVERY_FILE_DEST_SIZE a little below the limit of the DB_RECOVERY_FILE_DEST file system; remember that any file not placed automatically there by or not related to Oracle doesn't count towards the limit set in the DB_RECOVERY_FILE_DEST_SIZE parameter. And to finish this step, you have to issue the CONFIGURE ARCHIVELOG DELETION POLICY TO APPLIED ON STANDBY statement in RMAN both at the primary and standby servers:

oracle@primarysrv:/opt/oracle/product/10.2.0/db_1/dbs$ rman

Recovery Manager: Release 10.2.0.1.0 - Production on Fri Jun 10 12:57:46 2011

Copyright (c) 1982, 2005, Oracle. All rights reserved.

RMAN> connect target /

connected to target database: primarydb (DBID=3023816100)

RMAN> CONFIGURE ARCHIVELOG DELETION POLICY TO APPLIED ON STANDBY;

using target database control file instead of recovery catalog
new RMAN configuration parameters:
CONFIGURE ARCHIVELOG DELETION POLICY TO APPLIED ON STANDBY;
new RMAN configuration parameters are successfully stored

RMAN> show all;

RMAN configuration parameters are:
...
CONFIGURE ARCHIVELOG DELETION POLICY TO APPLIED ON STANDBY;
...

RMAN> exit


Recovery Manager complete.

========================================

oracle@standbysrv:/opt/oracle/product/10.2.0/db_1/dbs$ rman

Recovery Manager: Release 10.2.0.1.0 - Production on Fri Jun 10 12:54:49 2011

Copyright (c) 1982, 2005, Oracle. All rights reserved.

RMAN> connect target /

connected to target database: primarydb (DBID=3023816100, not open)

RMAN> CONFIGURE ARCHIVELOG DELETION POLICY TO APPLIED ON STANDBY;

using target database control file instead of recovery catalog
new RMAN configuration parameters:
CONFIGURE ARCHIVELOG DELETION POLICY TO APPLIED ON STANDBY;
new RMAN configuration parameters are successfully stored

RMAN> SHOW ALL;

RMAN configuration parameters are:
...
CONFIGURE ARCHIVELOG DELETION POLICY TO APPLIED ON STANDBY;
...
RMAN> exit


Recovery Manager complete.

We have almost finished! Now we will check that the standby database can be opened in read-only mode (for reporting purposes for example) opening it and issuing a simple query:

oracle@standbysrv:/opt/oracle/product/10.2.0/db_1/dbs$ sqlplus '/ as sysdba'

SQL*Plus: Release 10.2.0.1.0 - Production on Fri Jun 10 13:16:24 2011

Copyright (c) 1982, 2005, Oracle. All rights reserved.


Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options

SQL> alter database recover managed standby database cancel;

Database altered.

SQL> alter database open;

Database altered.

SQL> select count(*) from dba_objects;

COUNT(*)
----------
9715

SQL> select name, open_mode from v$database;

NAME OPEN_MODE
--------------------------- ------------------------------
primarydb READ ONLY

At this time you can query tables regarding to your own schemas if you know them.

Finally, you will restart the synchronization at the standby database:

SQL> shutdown immediate;
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
oracle@standbysrv:/opt/oracle/product/10.2.0/db_1/dbs$ sqlplus '/ as sysdba'

SQL*Plus: Release 10.2.0.1.0 - Production on Fri Jun 10 13:20:46 2011

Copyright (c) 1982, 2005, Oracle. All rights reserved.

Connected to an idle instance.

SQL> startup mount;
ORACLE instance started.

Total System Global Area 268435456 bytes
Fixed Size 1218892 bytes
Variable Size 88082100 bytes
Database Buffers 176160768 bytes
Redo Buffers 2973696 bytes
Database mounted.
SQL> alter database recover managed standby database disconnect from session;

Database altered.

SQL> select sequence#, first_time, next_time from v$archived_log order by sequence#;

SEQUENCE# FIRST_TIME NEXT_TIME
---------- ------------------ ------------------
6 07-JUN-11 08-JUN-11
7 08-JUN-11 08-JUN-11
8 08-JUN-11 10-JUN-11
9 10-JUN-11 10-JUN-11
10 10-JUN-11 10-JUN-11
11 10-JUN-11 10-JUN-11
12 10-JUN-11 10-JUN-11

7 rows selected.

Don't forget to force a change log at the primary database in order to check the redo log transfer.

And that's all! We have finished creating and checking an Oracle physical standby database; just don't forget to read the following documentation (or similar with 11g):

Oracle Data Guard Concepts and Administration 10g Release 2 (10.2)
Creating and Maintaining a Password File
Maintenance Of Archivelogs On Standby Databases

No comments:

Post a Comment