Time for action – verifying the standby database configuration

Run the following actions to verify the standby database configuration and redo transport services:

  1. Connect the standby database using SQL*Plus and check for the database role and status to ensure the database role is the physical standby.
    SQL> select db_unique_name,database_role,open_mode from v$database;
    DB_UNIQUE_NAME  DATABASE_ROLE    OPEN_MODE
    --------------- ---------------- --------------------
    india_un        PHYSICAL STANDBY MOUNTED
    
  2. Check the standby database, SPFILE.
    SQL> show parameter spfile
    NAME   TYPE    VALUE
    ------ ------- --------------------------------------------------
    spfile string  /u01/app/oracle/product/11.2.0/db_1/dbs/spfileINDIA.ora
    

    Tip

    If you have started the standby instance with PFILE, you should create an SPFILE and start an instance again using the new SPFILE.

  3. Use the v$datafile view to check the location of the datafiles in the standby database. The standby database datafile must be under the /u02 directory because of the DB_FILE_NAME_CONVERT parameter setting.
    SQL>  select name from v$datafile;
    NAME
    ---------------------------------------------
    /u02/app/oracle/oradata/orcl/system01.dbf
    /u02/app/oracle/oradata/orcl/sysaux01.dbf
    /u02/app/oracle/oradata/orcl/undotbs01.dbf
    /u02/app/oracle/oradata/orcl/users01.dbf
    /u02/app/oracle/oradata/orcl/example01.dbf
    
  4. Use the v$logfile view to check the location of online and standby redo logfiles in the standby database.
    SQL> select group#,type,member from v$logfile;
    
        GROUP# TYPE    MEMBER
    ---------- ------- ----------------------------------------------
             3 ONLINE  /u02/app/oracle/oradata/orcl/redo03.log
             2 ONLINE  /u02/app/oracle/oradata/orcl/redo02.log
             1 ONLINE  /u02/app/oracle/oradata/orcl/redo01.log
             4 ONLINE  /u02/app/oracle/oradata/orcl/redo04.log
            10 STANDBY /u02/app/oracle/oradata/orcl/standby_redo01.log
            11 STANDBY /u02/app/oracle/oradata/orcl/standby_redo02.log
            12 STANDBY /u02/app/oracle/oradata/orcl/standby_redo03.log
            13 STANDBY /u02/app/oracle/oradata/orcl/standby_redo04.log
            14 STANDBY /u02/app/oracle/oradata/orcl/standby_redo05.log
    

    Note that the online redo logfiles and standby redo logfiles in the primary database are created under the /u01 directory, whereas logfiles in the standby database are under /u02. This change occurred because of the settings of the LOG_FILE_NAME_CONVERT parameter.

    SQL> show parameter log_file_name_convert
    NAME                   TYPE        VALUE
    ---------------------- ----------- ----------------------------
    log_file_name_convert  string      /u01/app/oracle/oradata/orcl,
                                       /u02/app/oracle/oradata/orcl
    
  5. Verify if the redo transport service is active using the v$managed_standby view on the standby database:
    SQL> SELECT THREAD#,SEQUENCE#,PROCESS,CLIENT_PROCESS,STATUS,BLOCKS FROM V$MANAGED_STANDBY;
       THREAD#  SEQUENCE# PROCESS   CLIENT_P STATUS           BLOCKS
    ---------- ---------- --------- -------- ------------ ----------
             1        148 ARCH      ARCH     CLOSING               6
             1        147 ARCH      ARCH     CLOSING               8
             1        149 RFS       LGWR     IDLE                  1
             0          0 RFS       UNKNOWN  IDLE                  0
    

You must see RFS processes running on the standby database, which are responsible for writing redo information that the primary database sends to standby.

What just happened?

We've verified the standby database mode, status, and database files. We've also seen that the redo transport service is actively working between primary and standby.

Managing Redo Apply

As discussed in Chapter 1, Getting Started, Redo Apply is the synchronization method of the physical standby databases. Now let's see how can we start, stop, and monitor Redo Apply.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.133.141.219