Oracle DataGuard Step by Step Installation with RMAN Duplicate Method -1

Hi,

I will tell you Oracle dataguard configuration and installation in this article.

 

dataguard4

 

Let’s read Dataguard Architecture if you don’t know.

 

 

With Oracle DataGuard technology, we can create Physical and Logical Standby for our databases for providing disaster recovery . I will explain the most used Physical Standby configuration and setup in Oracle 12c, Oracle 18c database on Linux server.

 

Before starting installation, I will use db_name DEVECI for my Primary database. The name of the Physical Standby database will be DEVECIDG.  I will proceed step by step through the configuration and installation.

Requirements

1- An Oracle Software must be installed on the standby database server, which versions will be the same as the Primary database and also Patchset versions. (Database must not be created with DBCA and  If your primary database is 12.1.0.2, it must be 12.1.0.2 for Standby database)

2- A Listener must be created on the standby database server that will listen to the physical standby that will be created by NETCA with Oracle Software.

 

3- The primary database must be in Archivelog mode. For detailed information about Archivelog mode, please read the following article. You can find out whether the database is in archive mode with the following query.

 

 

SELECT log_mode FROM v$database;

LOG_MODE
------------
ARCHIVELOG

SQL>

 

4- All changes namely transactions (except TEMP Tablespace) running in the primary database must be logged and applied to the Standby. The following command must be run in Primary so that all changes and transactions in the primary database will be logged.

 

SQL> alter database force logging;

Database altered.

 

5- In the primary database, we should set some parameters required for Data Guard, and I will explain what these parameters are in the following article.

 

After making the following parameter change, the database must be closed and opened due to static parameters. Those who do not know how to close or open the database can read the following article.

 

Following scripts have to execute on Primary Side.

SQL> alter system set LOG_ARCHIVE_CONFIG='DG_CONFIG=(DEVECI,DEVECIDG)';
System altered.

SQL> alter system set LOG_ARCHIVE_DEST_2='SERVICE=DEVECIDG LGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=DEVECIDG';
System altered.

SQL> alter system set LOG_ARCHIVE_DEST_1='LOCATION=/oracle/DATA/DEVECI/ARCH/ VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=DEVECI';
System altered.

SQL> alter system set LOG_ARCHIVE_DEST_STATE_1=ENABLE;
System altered.

SQL> alter system set FAL_SERVER=DEVECIDG;
System altered.

SQL> alter system set FAL_CLIENT=DEVECI;
System altered.

SQL> ALTER SYSTEM SET LOG_ARCHIVE_MAX_PROCESSES=20;
System altered.

SQL> ALTER SYSTEM SET REMOTE_LOGIN_PASSWORDFILE=EXCLUSIVE SCOPE=SPFILE;
System altered.

SQL> alter system set DB_FILE_NAME_CONVERT='/oracle/DATA/DEVECIDG/DEVECIDG','/oracle/DATA/DEVECI/DEVECI' scope=spfile;
System altered.

SQL> alter system set LOG_FILE_NAME_CONVERT='/oracle/DATA/DEVECIDG/DEVECIDG','/oracle/DATA/DEVECI/DEVECI' scope=spfile;
System altered.

 

I will continue to tell installation of dataguard in the next post.

 

Mehmet Salih Deveci

I am Founder of IT Tutorial and Certified Expert about Oracle & SQL Server database, Goldengate, Exadata Machine, Oracle Database Appliance administrator with 10+years experience.I have OCA, OCP, OCE RAC Expert Certificates I have worked 100+ Banking, Insurance, Finance, Telco and etc. clients as a Consultant, Insource or Outsource.I have done 200+ Operations in this clients such as Exadata Installation & PoC & Migration & Upgrade, Oracle & SQL Server Database Upgrade, Oracle RAC Installation, SQL Server AlwaysOn Installation, Database Migration, Disaster Recovery, Backup Restore, Performance Tuning, Periodic Healthchecks.I have done 2000+ Table replication with Goldengate or SQL Server Replication tool for DWH Databases in many clients.If you need Oracle DBA, SQL Server DBA, APPS DBA,  Exadata, Goldengate, EBS Consultancy and Training you can send my email adress mehmetsalih.deveci@outlook.com.-                                                                                                                                                                                                                                                 -Oracle DBA, SQL Server DBA, APPS DBA,  Exadata, Goldengate, EBS ve linux Danışmanlık ve Eğitim için  mehmetsalih.deveci@outlook.com a mail atabilirsiniz.

2 thoughts on “Oracle DataGuard Step by Step Installation with RMAN Duplicate Method -1

Leave a Reply

Your email address will not be published. Required fields are marked *