{"id":2667,"date":"2019-10-14T10:49:24","date_gmt":"2019-10-14T07:49:24","guid":{"rendered":"https:\/\/www.fatihacar.com\/blog\/?p=2667"},"modified":"2019-10-23T15:52:58","modified_gmt":"2019-10-23T12:52:58","slug":"oracle-19c-r3-active-data-guard-installation-on-oracle-linux-7-7","status":"publish","type":"post","link":"https:\/\/www.fatihacar.com\/blog\/oracle-19c-r3-active-data-guard-installation-on-oracle-linux-7-7\/","title":{"rendered":"Oracle 19c R3 Active Data Guard Installation on Oracle Linux 7.7"},"content":{"rendered":"<p>Oracle Data Guard ensures high availability, data protection, and disaster recovery for enterprise data. Oracle Data Guard provides a comprehensive set of services that create, maintain, manage, and monitor one or more standby databases to enable production Oracle databases to survive disasters and data corruptions. Oracle Data Guard maintains these standby databases as copies of the production database.Then, if the production database becomes unavailable because of a planned or an unplanned outage, Oracle Data Guard can switch any standby database to the production role, minimizing the downtime associated with the outage. Oracle Data Guard can be used with traditional backup, restoration, and cluster techniques to provide a high level of data protection and data availability.<\/p>\n<p>With Oracle Data Guard, administrators can optionally improve production database performance by offloading resource-intensive backup and reporting operations to standby systems.<\/p>\n<p>Types of standby databases are Physical standby database, Logical standby database and Snapshot standby database.<\/p>\n<p>I will demonstrate Physical standby database as working real time apply at this document. Most used type is Physical standby database type. You can investigate other types of standby database from Oracle docs.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2668\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/Oracle19c_RAC_and_Active_Data_Guard.jpg\" alt=\"\" width=\"1069\" height=\"559\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/Oracle19c_RAC_and_Active_Data_Guard.jpg 1069w, https:\/\/www.fatihacar.com\/blog\/resimler\/Oracle19c_RAC_and_Active_Data_Guard-300x157.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/Oracle19c_RAC_and_Active_Data_Guard-768x402.jpg 768w, https:\/\/www.fatihacar.com\/blog\/resimler\/Oracle19c_RAC_and_Active_Data_Guard-1024x535.jpg 1024w\" sizes=\"auto, (max-width: 1069px) 100vw, 1069px\" \/><\/p>\n<p>I used Oracle RAC database as primary side and I used single instance database with asm file system as secondary side (Data Guard).<\/p>\n<p>Firstly, you have to adjust system parameters of operating system on secondary side and create asm disks. After, you can start to install of grid infrastructure. You can create disk groups for DATA and FRA disk groups after install grid. After grid installation, you can install Oracle Data Guard database on grid infrastructure and ASM disks as software only. Finally you can configure parameter and listeners on both sides and start apply. I divide the stages of installation four steps.<\/p>\n<p>You can find primary side (Oracle 19c R3 RAC) installation steps <a href=\"https:\/\/www.fatihacar.com\/blog\/oracle-19c-r3-real-application-clusters-rac-installation-steps-on-oracle-linux-7-7\/\">here<\/a>. I will use this infrastructure as primary side.<\/p>\n<h3>First Step : Configure Operation System on Standby Server<\/h3>\n<p><strong>1. Upgrade All Packages<\/strong><\/p>\n<blockquote><p>yum upgrade<\/p><\/blockquote>\n<p><!--more--><\/p>\n<p><strong>2. Selinux Disable or Permissive<\/strong><\/p>\n<blockquote><p>You can do disabled or permissive<\/p>\n<p>vi \/etc\/selinux\/config<\/p>\n<p>SELINUX=permissive<\/p><\/blockquote>\n<p><strong>3. Firewall Stop and Disable<\/strong><\/p>\n<blockquote><p>You can open firewall after installation, but you have to give permission to necessary ports and services.<\/p>\n<p>systemctl stop firewalld.service<\/p>\n<p>systemctl disable firewalld.service<\/p><\/blockquote>\n<p><strong>4. Chrony NTP Configuration<\/strong><\/p>\n<blockquote><p>Chrony plugin came with Oracle Linux 7 version for ntp sync. You can write your ntp server information in \/etc\/chrony.conf file to time sync.<\/p>\n<p>on each node<\/p>\n<p>vi \/etc\/chrony.conf<\/p>\n<p>server yourntpaddress iburst<\/p>\n<p>systemctl restart chronyd.service<\/p>\n<p>systemctl enable chronyd.service<\/p><\/blockquote>\n<p><strong>5. Package Installation<\/strong><\/p>\n<blockquote><p>on each node<\/p>\n<p>yum install oracle-database-preinstall-19c<\/p>\n<p>yum install oracleasm-support<\/p>\n<p>reboot<\/p><\/blockquote>\n<p><strong>6. Create Oracle and Grid Users<\/strong><\/p>\n<blockquote><p>When you run \u201cyum install oracle-database-preinstall-19c\u201d, oracle user created. You can see oracle user info with \u201cid oracle\u201d command. uid and gid have to be the same on both servers.<\/p>\n<p>id oracle<br \/>\nuid=54321(oracle) gid=54321(oinstall) groups=54321(oinstall),54322(dba),54323(oper),54324(backupdba),54325(dgdba),54326(kmdba),54330(racdba)<\/p>\n<p>Also I will create new groups to grid user. And then I will create grid user with adding to new groups on both servers.<\/p>\n<p>groupadd -g 54333 asmdba<\/p>\n<p align=\"justify\">groupadd -g 54334 asmoper<\/p>\n<p align=\"justify\">groupadd -g 54335 asmadmin<\/p>\n<p align=\"justify\">useradd -m -u 54341 -g oinstall -G dba,asmadmin,asmdba,asmoper,racdba -d \/home\/grid -s \/bin\/bash grid<\/p>\n<p align=\"justify\">passwd oracle<\/p>\n<p align=\"justify\">passwd grid<\/p>\n<p align=\"justify\">oracle user add to asmdba,asmadmin group.<\/p>\n<p align=\"justify\">usermod -a -G asmdba,asmadmin oracle<\/p>\n<p align=\"justify\">passwd oracle<\/p>\n<p align=\"justify\">passwd grid<\/p>\n<\/blockquote>\n<p><strong>7. Create Directories<\/strong><\/p>\n<blockquote><p>mkdir -p \/oracle\/grid\/19.3.0\/grid_home<\/p>\n<p>mkdir -p \/oracle\/grid\/gridbase\/<\/p>\n<p>mkdir -p \/oracle\/db\/19.3.0\/db_home<\/p>\n<p>chown -R oracle.oinstall \/oracle\/<\/p>\n<p>chown -R grid.oinstall \/oracle\/grid\/<\/p>\n<p>chmod -R 775 \/oracle\/<\/p><\/blockquote>\n<p align=\"justify\"><strong>8. Configure Bash Profile of Users.<\/strong><\/p>\n<p align=\"justify\">Add below parameters to bash_profiles.<\/p>\n<blockquote>\n<p align=\"justify\"><strong>Oracle user bash_profile<\/strong><\/p>\n<p>vi .bash_profile<\/p>\n<p># Oracle Settings<\/p>\n<p>export TMP=\/tmp<\/p>\n<p>export TMPDIR=$TMP<\/p>\n<p>export ORACLE_HOSTNAME=oracle19cdg1.yourdomain<\/p>\n<p>export ORACLE_UNQNAME=ORA19CD1<\/p>\n<p>export ORACLE_BASE=\/oracle\/db\/19.3.0<\/p>\n<p>export DB_HOME=$ORACLE_BASE\/db_home<\/p>\n<p>export ORACLE_HOME=$DB_HOME<\/p>\n<p>export ORACLE_SID=ORA19CD1<\/p>\n<p>export ORACLE_TERM=xterm<\/p>\n<p>export PATH=\/usr\/sbin:\/usr\/local\/bin:$PATH<\/p>\n<p>export PATH=$ORACLE_HOME\/bin:$PATH<\/p>\n<p>export LD_LIBRARY_PATH=$ORACLE_HOME\/lib:\/lib:\/usr\/lib<\/p>\n<p>export CLASSPATH=$ORACLE_HOME\/jlib:$ORACLE_HOME\/rdbms\/jlib<\/p><\/blockquote>\n<p>&nbsp;<\/p>\n<blockquote><p><strong>Grid user bash_profile<\/strong><\/p>\n<p>vi .bash_profile<\/p>\n<p># Grid Settings<\/p>\n<p>export TMP=\/tmp<\/p>\n<p>export TMPDIR=$TMP<\/p>\n<p>export ORACLE_HOSTNAME=oracle19cdg1.yourdomain<\/p>\n<p>export ORACLE_BASE=\/oracle\/grid\/gridbase<\/p>\n<p>export ORACLE_HOME=\/oracle\/grid\/19.3.0\/grid_home<\/p>\n<p>export GRID_BASE=\/oracle\/grid\/gridbase<\/p>\n<p>export GRID_HOME=\/oracle\/grid\/19.3.0\/grid_home<\/p>\n<p>export ORACLE_SID=+ASM<\/p>\n<p>export ORACLE_TERM=xterm<\/p>\n<p>export PATH=\/usr\/sbin:\/usr\/local\/bin:$PATH<\/p>\n<p>export PATH=$ORACLE_HOME\/bin:$PATH<\/p>\n<p>export LD_LIBRARY_PATH=$ORACLE_HOME\/lib:\/lib:\/usr\/lib<\/p>\n<p>export CLASSPATH=$ORACLE_HOME\/jlib:$ORACLE_HOME\/rdbms\/jlib<\/p>\n<p>&nbsp;<\/p><\/blockquote>\n<p><strong>9. Configure Hosts File<\/strong><\/p>\n<blockquote><p>vi \/etc\/hosts<\/p>\n<p>11.12.13.15 oracle19c1 oracle19c1.yourdomain<br \/>\n11.12.13.16 oracle19c2 oracle19c2.yourdomain<br \/>\n11.12.13.17 oracle19c1-vip oracle19c1-vip.yourdomain<br \/>\n11.12.13.18 oracle19c2-vip oracle19c2-vip.yourdomain<br \/>\n11.12.13.19 oracle19c-scan oracle19c-scan.yourdomain<br \/>\n11.12.13.20 oracle19c-scan oracle19c-scan.yourdomain<br \/>\n11.12.13.21 oracle19c-scan oracle19c-scan.yourdomain<br \/>\n11.12.13.21 oracle19cdg1 oracle19cdg1.yourdomain<\/p><\/blockquote>\n<p><strong>10. Configure Passwordless SSH Connection<\/strong><\/p>\n<blockquote><p>You have to configure ssh passwordless connection for oracle and grid user.<\/p>\n<p>You can find how to do this step\u00a0<a href=\"https:\/\/www.fatihacar.com\/blog\/?s=ssh-keygen\">here<\/a>.<\/p><\/blockquote>\n<p><strong>11. DNS Register<\/strong><\/p>\n<blockquote><p>You can configure dns information of nodes in \/etc\/resolf.conf file.<\/p><\/blockquote>\n<p><strong>12. Configure ASM Disks<\/strong><\/p>\n<blockquote><p>Your disk name can be different from I used. I configured sdc, sdd,sde disks for asm on my test suite. These sd* disks can be different on your system.<\/p>\n<p>Configure oracleasm with root user on both servers.<\/p>\n<p>oracleasm configure -i<\/p>\n<p>Answers of Questions;<\/p>\n<p>grid<\/p>\n<p>asmadmin<\/p>\n<p>y<\/p>\n<p>y<\/p>\n<p>After finish configuration you can make init with below command.<\/p>\n<p>oracleasm init<\/p>\n<p>Create partition and asm disk on only first server.<\/p>\n<p>fdisk \/dev\/sdc<\/p>\n<p>fdisk \/dev\/sdd<\/p>\n<p>fdisk \/dev\/sde<\/p>\n<p>oracleasm createdisk DATA1 \/dev\/sdb1<\/p>\n<p>oracleasm createdisk FRA1 \/dev\/sdc1<\/p>\n<p>oracleasm createdisk OCR_VOTING1 \/dev\/sdd1<\/p>\n<p>You can use scandisks and listdisks to control on both servers.<\/p>\n<p>oracleasm scandisks<\/p>\n<p>oracleasm listdisks<\/p><\/blockquote>\n<p>&nbsp;<\/p>\n<h3>Second Step : Install Grid Infrastructure<\/h3>\n<p>You have to copy your grid installation files to grid_home. I recommend that you copy grid zip file to grid home and change owner of zip file, and unzip with grid user.<\/p>\n<p><strong>1. Copy and Unzip Grid Files<\/strong><\/p>\n<blockquote><p>cp LINUX.X64_193000_grid_home.zip \/oracle\/grid\/19.3.0\/grid_home\/<\/p>\n<p>chown grid.oinstall LINUX.X64_193000_grid_home.zip<\/p>\n<p>su \u2013 grid<\/p>\n<p>unzip LINUX.X64_193000_grid_home.zip<\/p><\/blockquote>\n<p><strong>2. Display Config and Start Grid Installation<\/strong><\/p>\n<blockquote><p>su &#8211;<\/p>\n<p>export DISPLAY=:0.0<\/p>\n<p>xhost +<\/p>\n<p>su &#8211; grid<\/p>\n<p>export DISPLAY=:0.0<\/p>\n<p>xhost +<\/p>\n<p>cd \/$GRID_HOME\/<\/p>\n<p>.\/grid_Setup.sh<\/p><\/blockquote>\n<p><strong>3. Grid Infrastructure Installation Steps<\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2670\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-1.jpg\" alt=\"\" width=\"795\" height=\"601\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-1.jpg 795w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-1-300x227.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-1-768x581.jpg 768w\" sizes=\"auto, (max-width: 795px) 100vw, 795px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2671\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-2.jpg\" alt=\"\" width=\"798\" height=\"603\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-2.jpg 798w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-2-300x227.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-2-768x580.jpg 768w\" sizes=\"auto, (max-width: 798px) 100vw, 798px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2672\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-3.jpg\" alt=\"\" width=\"794\" height=\"604\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-3.jpg 794w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-3-300x228.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-3-768x584.jpg 768w\" sizes=\"auto, (max-width: 794px) 100vw, 794px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2673\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-4.jpg\" alt=\"\" width=\"798\" height=\"605\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-4.jpg 798w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-4-300x227.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-4-768x582.jpg 768w\" sizes=\"auto, (max-width: 798px) 100vw, 798px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2674\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-5.jpg\" alt=\"\" width=\"796\" height=\"605\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-5.jpg 796w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-5-300x228.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-5-768x584.jpg 768w\" sizes=\"auto, (max-width: 796px) 100vw, 796px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2675\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-6.jpg\" alt=\"\" width=\"795\" height=\"604\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-6.jpg 795w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-6-300x228.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-6-768x583.jpg 768w\" sizes=\"auto, (max-width: 795px) 100vw, 795px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2676\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-7.jpg\" alt=\"\" width=\"798\" height=\"603\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-7.jpg 798w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-7-300x227.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-7-768x580.jpg 768w\" sizes=\"auto, (max-width: 798px) 100vw, 798px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2677\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-8.jpg\" alt=\"\" width=\"797\" height=\"603\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-8.jpg 797w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-8-300x227.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-8-768x581.jpg 768w\" sizes=\"auto, (max-width: 797px) 100vw, 797px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2678\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-9.jpg\" alt=\"\" width=\"796\" height=\"602\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-9.jpg 796w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-9-300x227.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-9-768x581.jpg 768w\" sizes=\"auto, (max-width: 796px) 100vw, 796px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2679\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-10.jpg\" alt=\"\" width=\"794\" height=\"604\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-10.jpg 794w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-10-300x228.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-10-768x584.jpg 768w\" sizes=\"auto, (max-width: 794px) 100vw, 794px\" \/><\/p>\n<p>&nbsp;<\/p>\n<blockquote><p>[root@oracle19cdg1 ~]# \/oracle\/grid\/19.3.0\/grid_home\/root.sh<br \/>\nPerforming root user operation.<\/p>\n<p>The following environment variables are set as:<br \/>\nORACLE_OWNER= grid<br \/>\nORACLE_HOME= \/oracle\/grid\/19.3.0\/grid_home<\/p>\n<p>Enter the full pathname of the local bin directory: [\/usr\/local\/bin]:<br \/>\nCopying dbhome to \/usr\/local\/bin &#8230;<br \/>\nCopying oraenv to \/usr\/local\/bin &#8230;<br \/>\nCopying coraenv to \/usr\/local\/bin &#8230;<\/p>\n<p>Creating \/etc\/oratab file&#8230;<br \/>\nEntries will be added to the \/etc\/oratab file as needed by<br \/>\nDatabase Configuration Assistant when a database is created<br \/>\nFinished running generic part of root script.<br \/>\nNow product-specific root actions will be performed.<br \/>\nUsing configuration parameter file: \/oracle\/grid\/19.3.0\/grid_home\/crs\/install\/crsconfig_params<br \/>\nThe log of current session can be found at:<br \/>\n\/oracle\/grid\/gridbase\/crsdata\/oracle19cdg1\/crsconfig\/roothas_2019-10-11_03-46-04PM.log<br \/>\nLOCAL ADD MODE<br \/>\nCreating OCR keys for user &#8216;grid&#8217;, privgrp &#8216;oinstall&#8217;..<br \/>\nOperation successful.<br \/>\nLOCAL ONLY MODE<br \/>\nSuccessfully accumulated necessary OCR keys.<br \/>\nCreating OCR keys for user &#8216;root&#8217;, privgrp &#8216;root&#8217;..<br \/>\nOperation successful.<br \/>\nCRS-4664: Node oracle19cdg1 successfully pinned.<br \/>\n2019\/10\/11 15:46:22 CLSRSC-330: Adding Clusterware entries to file &#8216;oracle-ohasd.service&#8217;<\/p>\n<p>oracle19cdg1 2019\/10\/11 15:49:16 \/oracle\/grid\/gridbase\/crsdata\/oracle19cdg1\/olr\/backup_20191011_154916.olr 724960844<br \/>\n2019\/10\/11 15:49:17 CLSRSC-327: Successfully configured Oracle Restart for a standalone server<\/p><\/blockquote>\n<p>&nbsp;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2680\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-11.jpg\" alt=\"\" width=\"794\" height=\"604\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-11.jpg 794w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-11-300x228.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-grid-install-11-768x584.jpg 768w\" sizes=\"auto, (max-width: 794px) 100vw, 794px\" \/><\/p>\n<p>&nbsp;<\/p>\n<p><strong>4. ASM Disk Configuration<\/strong><\/p>\n<p><strong>Start ASMCA<\/strong><\/p>\n<blockquote><p>su \u2013<\/p>\n<p>export DISPLAY=:0.0<\/p>\n<p>xhost +<\/p>\n<p>su \u2013 grid<\/p>\n<p>export DISPLAY=:0.0<\/p>\n<p>xhost +<\/p>\n<p>asmca<\/p><\/blockquote>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2681\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-1.jpg\" alt=\"\" width=\"945\" height=\"631\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-1.jpg 945w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-1-300x200.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-1-768x513.jpg 768w\" sizes=\"auto, (max-width: 945px) 100vw, 945px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2682\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-2.jpg\" alt=\"\" width=\"946\" height=\"632\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-2.jpg 946w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-2-300x200.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-2-768x513.jpg 768w\" sizes=\"auto, (max-width: 946px) 100vw, 946px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2683\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-3.jpg\" alt=\"\" width=\"948\" height=\"633\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-3.jpg 948w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-3-300x200.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-3-768x513.jpg 768w\" sizes=\"auto, (max-width: 948px) 100vw, 948px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2684\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-4.jpg\" alt=\"\" width=\"946\" height=\"632\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-4.jpg 946w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-4-300x200.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-asmca-4-768x513.jpg 768w\" sizes=\"auto, (max-width: 946px) 100vw, 946px\" \/><\/p>\n<p>&nbsp;<\/p>\n<h3>Third Step : Install Database Software<\/h3>\n<p>You have to copy your database installation files to oracle_home. I recommend that you copy database zip file to oracle home and change owner of zip file, and unzip with oracle user.<\/p>\n<p><strong>1. Copy and Unzip Database Files<\/strong><\/p>\n<blockquote><p>cp LINUX.X64_193000_db_home.zip \/oracle\/db\/19.3.0\/db_home\/<\/p>\n<p>chown oracle.oinstall LINUX.X64_193000_db_home.zip<\/p>\n<p>su &#8211; oracle<\/p>\n<p>unzip LINUX.X64_193000_db_home.zip<\/p><\/blockquote>\n<p><strong>2. Display Config and Start Database Installation<\/strong><\/p>\n<blockquote><p>su &#8211;<\/p>\n<p>export DISPLAY=:0.0<\/p>\n<p>xhost +<\/p>\n<p>su &#8211; oracle<\/p>\n<p>export DISPLAY=:0.0<\/p>\n<p>xhost +<\/p>\n<p>cd \/$ORACLE_HOME\/<\/p>\n<p>.\/runInstaller.sh<\/p><\/blockquote>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2685\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-1.jpg\" alt=\"\" width=\"797\" height=\"604\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-1.jpg 797w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-1-300x227.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-1-768x582.jpg 768w\" sizes=\"auto, (max-width: 797px) 100vw, 797px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2686\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-2.jpg\" alt=\"\" width=\"796\" height=\"603\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-2.jpg 796w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-2-300x227.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-2-768x582.jpg 768w\" sizes=\"auto, (max-width: 796px) 100vw, 796px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2687\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-3.jpg\" alt=\"\" width=\"795\" height=\"605\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-3.jpg 795w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-3-300x228.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-3-768x584.jpg 768w\" sizes=\"auto, (max-width: 795px) 100vw, 795px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2688\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-4.jpg\" alt=\"\" width=\"795\" height=\"605\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-4.jpg 795w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-4-300x228.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-4-768x584.jpg 768w\" sizes=\"auto, (max-width: 795px) 100vw, 795px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2689\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-5.jpg\" alt=\"\" width=\"794\" height=\"604\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-5.jpg 794w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-5-300x228.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-5-768x584.jpg 768w\" sizes=\"auto, (max-width: 794px) 100vw, 794px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2690\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-6.jpg\" alt=\"\" width=\"795\" height=\"604\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-6.jpg 795w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-6-300x228.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-6-768x583.jpg 768w\" sizes=\"auto, (max-width: 795px) 100vw, 795px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2691\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-7.jpg\" alt=\"\" width=\"793\" height=\"603\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-7.jpg 793w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-7-300x228.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-7-768x584.jpg 768w\" sizes=\"auto, (max-width: 793px) 100vw, 793px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2692\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-8.jpg\" alt=\"\" width=\"792\" height=\"603\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-8.jpg 792w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-8-300x228.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-8-768x585.jpg 768w\" sizes=\"auto, (max-width: 792px) 100vw, 792px\" \/><\/p>\n<blockquote><p>[root@oracle19cdg1 ~]# \/oracle\/db\/19.3.0\/db_home\/root.sh<br \/>\nPerforming root user operation.<\/p>\n<p>The following environment variables are set as:<br \/>\nORACLE_OWNER= oracle<br \/>\nORACLE_HOME= \/oracle\/db\/19.3.0\/db_home<\/p>\n<p>Enter the full pathname of the local bin directory: [\/usr\/local\/bin]:<br \/>\nThe contents of &#8220;dbhome&#8221; have not changed. No need to overwrite.<br \/>\nThe contents of &#8220;oraenv&#8221; have not changed. No need to overwrite.<br \/>\nThe contents of &#8220;coraenv&#8221; have not changed. No need to overwrite.<\/p>\n<p>Entries will be added to the \/etc\/oratab file as needed by<br \/>\nDatabase Configuration Assistant when a database is created<br \/>\nFinished running generic part of root script.<br \/>\nNow product-specific root actions will be performed.<br \/>\nOracle Trace File Analyzer (TFA &#8211; Standalone Mode) is available at :<br \/>\n\/oracle\/db\/19.3.0\/db_home\/bin\/tfactl<\/p>\n<p>Note :<br \/>\n1. tfactl will use TFA Service if that service is running and user has been granted access<br \/>\n2. tfactl will configure TFA Standalone Mode only if user has no access to TFA Service or TFA is not installed<\/p><\/blockquote>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2693\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-9.jpg\" alt=\"\" width=\"793\" height=\"605\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-9.jpg 793w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-9-300x229.jpg 300w, https:\/\/www.fatihacar.com\/blog\/resimler\/oracle19c-data-guard-installation-steps-database-software-9-768x586.jpg 768w\" sizes=\"auto, (max-width: 793px) 100vw, 793px\" \/><\/p>\n<h3>Fourth Step : Configure Parameters and Listeners<\/h3>\n<p><strong>Primary Side<\/strong><\/p>\n<p><strong>Node 1<\/strong><\/p>\n<p>Add new listener and configure tnsnames.ora for data guard connection<\/p>\n<blockquote><p>su &#8211; oracle<\/p>\n<p>cd $ORACLE_HOME\/network\/admin<\/p>\n<p>vi listener.ora<\/p>\n<p>listener_for_dataguard =<br \/>\n(ADDRESS_LIST =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(Host = oracle19c1-vip.sm.gov.tr)(Port = 1541))<br \/>\n)<\/p>\n<p>SID_LIST_LISTENER_FOR_DATAGUARD =<br \/>\n(SID_LIST =<br \/>\n(SID_DESC =<br \/>\n(ORACLE_HOME = \/oracle\/db\/19.3.0\/db_home)<br \/>\n(SID_NAME = ORA19C1)<br \/>\n)<br \/>\n)<\/p>\n<p>&nbsp;<\/p>\n<p>vi tnsnames.ora<\/p>\n<p>ORA19C =<br \/>\n(DESCRIPTION =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(HOST = oracle19c-scan)(PORT = 1521))<br \/>\n(CONNECT_DATA =<br \/>\n(SERVER = DEDICATED)<br \/>\n(SERVICE_NAME = ORA19C)<br \/>\n)<br \/>\n)<\/p>\n<p>ORA19C1 =<br \/>\n(DESCRIPTION =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(HOST = oracle19c1-vip)(PORT = 1521))<br \/>\n(CONNECT_DATA =<br \/>\n(SERVER = DEDICATED)<br \/>\n(SERVICE_NAME = ORA19C)<br \/>\n)<br \/>\n)<\/p>\n<p>ORA19C2 =<br \/>\n(DESCRIPTION =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(HOST = oracle19c2-vip)(PORT = 1521))<br \/>\n(CONNECT_DATA =<br \/>\n(SERVER = DEDICATED)<br \/>\n(SERVICE_NAME = ORA19C)<br \/>\n)<br \/>\n)<\/p>\n<p>PRI_ORA19C =<br \/>\n(DESCRIPTION =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(HOST = oracle19c1-vip)(PORT = 1541))<br \/>\n(CONNECT_DATA =<br \/>\n(SERVER = DEDICATED)<br \/>\n(SERVICE_NAME = ORA19C)<br \/>\n)<br \/>\n)<\/p>\n<p>DG_ORA19C =<br \/>\n(DESCRIPTION =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(HOST = oracle19cdg1)(PORT = 1541))<br \/>\n(CONNECT_DATA =<br \/>\n(SERVER = DEDICATED)<br \/>\n(SERVICE_NAME = ORA19CD1)<br \/>\n)<br \/>\n)<\/p>\n<p>[oracle@oracle19c1 admin]$ lsnrctl start listener_for_dataguard<\/p>\n<p>LSNRCTL for Linux: Version 19.0.0.0.0 &#8211; Production on 11-OCT-2019 16:26:30<\/p>\n<p>Copyright (c) 1991, 2019, Oracle. All rights reserved.<\/p>\n<p>Starting \/oracle\/db\/19.3.0\/db_home\/bin\/tnslsnr: please wait&#8230;<\/p>\n<p>TNSLSNR for Linux: Version 19.0.0.0.0 &#8211; Production<br \/>\nSystem parameter file is \/oracle\/db\/19.3.0\/db_home\/network\/admin\/listener.ora<br \/>\nLog messages written to \/oracle\/db\/19.3.0\/diag\/tnslsnr\/oracle19c1\/listener_for_dataguard\/alert\/log.xml<br \/>\nListening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.1.9.17)(PORT=1541)))<\/p>\n<p>Connecting to (ADDRESS=(PROTOCOL=TCP)(Host=oracle19c1-vip.sm.gov.tr)(Port=1541))<br \/>\nSTATUS of the LISTENER<br \/>\n&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br \/>\nAlias listener_for_dataguard<br \/>\nVersion TNSLSNR for Linux: Version 19.0.0.0.0 &#8211; Production<br \/>\nStart Date 11-OCT-2019 16:26:31<br \/>\nUptime 0 days 0 hr. 0 min. 0 sec<br \/>\nTrace Level off<br \/>\nSecurity ON: Local OS Authentication<br \/>\nSNMP OFF<br \/>\nListener Parameter File \/oracle\/db\/19.3.0\/db_home\/network\/admin\/listener.ora<br \/>\nListener Log File \/oracle\/db\/19.3.0\/diag\/tnslsnr\/oracle19c1\/listener_for_dataguard\/alert\/log.xml<br \/>\nListening Endpoints Summary&#8230;<br \/>\n(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.1.9.17)(PORT=1541)))<br \/>\nServices Summary&#8230;<br \/>\nService &#8220;ORA19C1&#8221; has 1 instance(s).<br \/>\nInstance &#8220;ORA19C1&#8221;, status UNKNOWN, has 1 handler(s) for this service&#8230;<br \/>\nThe command completed successfully<\/p><\/blockquote>\n<p><strong>Node 2<\/strong><\/p>\n<blockquote><p>su &#8211; oracle<\/p>\n<p>cd $ORACLE_HOME\/network\/admin<\/p>\n<p>vi listener.ora<\/p>\n<p>listener_for_dataguard =<br \/>\n(ADDRESS_LIST =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(Host = oracle19c2-vip.sm.gov.tr)(Port = 1541))<br \/>\n)<\/p>\n<p>SID_LIST_LISTENER_FOR_DATAGUARD =<br \/>\n(SID_LIST =<br \/>\n(SID_DESC =<br \/>\n(ORACLE_HOME = \/oracle\/db\/19.3.0\/db_home)<br \/>\n(SID_NAME = ORA19C2)<br \/>\n)<br \/>\n)<\/p>\n<p>vi tnsnames.ora<\/p>\n<p>ORA19C =<br \/>\n(DESCRIPTION =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(HOST = oracle19c-scan)(PORT = 1521))<br \/>\n(CONNECT_DATA =<br \/>\n(SERVER = DEDICATED)<br \/>\n(SERVICE_NAME = ORA19C)<br \/>\n)<br \/>\n)<\/p>\n<p>ORA19C1 =<br \/>\n(DESCRIPTION =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(HOST = oracle19c1-vip)(PORT = 1521))<br \/>\n(CONNECT_DATA =<br \/>\n(SERVER = DEDICATED)<br \/>\n(SERVICE_NAME = ORA19C)<br \/>\n)<br \/>\n)<\/p>\n<p>ORA19C2 =<br \/>\n(DESCRIPTION =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(HOST = oracle19c2-vip)(PORT = 1521))<br \/>\n(CONNECT_DATA =<br \/>\n(SERVER = DEDICATED)<br \/>\n(SERVICE_NAME = ORA19C)<br \/>\n)<br \/>\n)<\/p>\n<p>PRI_ORA19C =<br \/>\n(DESCRIPTION =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(HOST = oracle19c2-vip)(PORT = 1541))<br \/>\n(CONNECT_DATA =<br \/>\n(SERVER = DEDICATED)<br \/>\n(SERVICE_NAME = ORA19C)<br \/>\n)<br \/>\n)<\/p>\n<p>DG_ORA19C =<br \/>\n(DESCRIPTION =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(HOST = oracle19cdg1)(PORT = 1541))<br \/>\n(CONNECT_DATA =<br \/>\n(SERVER = DEDICATED)<br \/>\n(SERVICE_NAME = ORA19CD1)<br \/>\n)<br \/>\n)<\/p>\n<p>[oracle@oracle19c2 admin]$ lsnrctl start listener_for_dataguard<\/p>\n<p>LSNRCTL for Linux: Version 19.0.0.0.0 &#8211; Production on 11-OCT-2019 16:27:02<\/p>\n<p>Copyright (c) 1991, 2019, Oracle. All rights reserved.<\/p>\n<p>Starting \/oracle\/db\/19.3.0\/db_home\/bin\/tnslsnr: please wait&#8230;<\/p>\n<p>TNSLSNR for Linux: Version 19.0.0.0.0 &#8211; Production<br \/>\nSystem parameter file is \/oracle\/db\/19.3.0\/db_home\/network\/admin\/listener.ora<br \/>\nLog messages written to \/oracle\/db\/19.3.0\/diag\/tnslsnr\/oracle19c2\/listener_for_dataguard\/alert\/log.xml<br \/>\nListening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.1.9.18)(PORT=1541)))<\/p>\n<p>Connecting to (ADDRESS=(PROTOCOL=TCP)(Host=oracle19c2-vip.sm.gov.tr)(Port=1541))<br \/>\nSTATUS of the LISTENER<br \/>\n&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br \/>\nAlias listener_for_dataguard<br \/>\nVersion TNSLSNR for Linux: Version 19.0.0.0.0 &#8211; Production<br \/>\nStart Date 11-OCT-2019 16:27:02<br \/>\nUptime 0 days 0 hr. 0 min. 0 sec<br \/>\nTrace Level off<br \/>\nSecurity ON: Local OS Authentication<br \/>\nSNMP OFF<br \/>\nListener Parameter File \/oracle\/db\/19.3.0\/db_home\/network\/admin\/listener.ora<br \/>\nListener Log File \/oracle\/db\/19.3.0\/diag\/tnslsnr\/oracle19c2\/listener_for_dataguard\/alert\/log.xml<br \/>\nListening Endpoints Summary&#8230;<br \/>\n(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.1.9.18)(PORT=1541)))<br \/>\nServices Summary&#8230;<br \/>\nService &#8220;ORA19C2&#8221; has 1 instance(s).<br \/>\nInstance &#8220;ORA19C2&#8221;, status UNKNOWN, has 1 handler(s) for this service&#8230;<br \/>\nThe command completed successfully<\/p><\/blockquote>\n<p><strong>Standby Side<\/strong><\/p>\n<p>Add new listener and configure tnsnames.ora for data guard connection<\/p>\n<blockquote><p>su &#8211; oracle<\/p>\n<p>cd $ORACLE_HOME\/network\/admin<\/p>\n<p>vi listener.ora<\/p>\n<p>listener_for_dataguard =<br \/>\n(ADDRESS_LIST =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(Host = oracle19cdg1)(Port = 1541))<br \/>\n)<\/p>\n<p>SID_LIST_LISTENER_FOR_DATAGUARD =<br \/>\n(SID_LIST =<br \/>\n(SID_DESC =<br \/>\n(ORACLE_HOME = \/oracle\/db\/19.3.0\/db_home)<br \/>\n(SID_NAME = ORA19CD1)<br \/>\n)<br \/>\n)<\/p>\n<p>vi tnsnames.ora<\/p>\n<p>PRI_ORA19C =<br \/>\n(DESCRIPTION =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(HOST = oracle19c1-vip)(PORT = 1541))<br \/>\n(CONNECT_DATA =<br \/>\n(SERVER = DEDICATED)<br \/>\n(SID = ORA19C1)<br \/>\n)<br \/>\n)<\/p>\n<p>DG_ORA19C =<br \/>\n(DESCRIPTION =<br \/>\n(ADDRESS = (PROTOCOL = TCP)(HOST = oracle19cdg1)(PORT = 1541))<br \/>\n(CONNECT_DATA =<br \/>\n(SERVER = DEDICATED)<br \/>\n(SERVICE_NAME = ORA19CD1)<br \/>\n)<br \/>\n)<\/p>\n<p>[oracle@oracle19cdg1 admin]$ lsnrctl start listener_for_dataguard<\/p>\n<p>LSNRCTL for Linux: Version 19.0.0.0.0 &#8211; Production on 11-OCT-2019 16:50:59<\/p>\n<p>Copyright (c) 1991, 2019, Oracle. All rights reserved.<\/p>\n<p>Starting \/oracle\/db\/19.3.0\/db_home\/bin\/tnslsnr: please wait&#8230;<\/p>\n<p>TNSLSNR for Linux: Version 19.0.0.0.0 &#8211; Production<br \/>\nSystem parameter file is \/oracle\/db\/19.3.0\/db_home\/network\/admin\/listener.ora<br \/>\nLog messages written to \/oracle\/db\/19.3.0\/diag\/tnslsnr\/oracle19cdg1\/listener_for_dataguard\/alert\/log.xml<br \/>\nListening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=oracle19cdg1)(PORT=1541) ))<\/p>\n<p>Connecting to (ADDRESS=(PROTOCOL=TCP)(Host=oracle19cdg1)(Port=1541))<br \/>\nSTATUS of the LISTENER<br \/>\n&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br \/>\nAlias listener_for_dataguard<br \/>\nVersion TNSLSNR for Linux: Version 19.0.0.0.0 &#8211; Production<br \/>\nStart Date 11-OCT-2019 16:50:59<br \/>\nUptime 0 days 0 hr. 0 min. 0 sec<br \/>\nTrace Level off<br \/>\nSecurity ON: Local OS Authentication<br \/>\nSNMP OFF<br \/>\nListener Parameter File \/oracle\/db\/19.3.0\/db_home\/network\/admin\/listener.ora<br \/>\nListener Log File \/oracle\/db\/19.3.0\/diag\/tnslsnr\/oracle19cdg1\/listener_for_dataguard\/alert\/log.xml<br \/>\nListening Endpoints Summary&#8230;<br \/>\n(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=oracle19cdg1)(PORT=1541)))<br \/>\nServices Summary&#8230;<br \/>\nService &#8220;ORA19CD1&#8221; has 1 instance(s).<br \/>\nInstance &#8220;ORA19CD1&#8221;, status UNKNOWN, has 1 handler(s) for this service&#8230;<br \/>\nThe command completed successfully<\/p><\/blockquote>\n<p><strong>Primary Side<\/strong><\/p>\n<p>Configure parameters<\/p>\n<blockquote><p>Database has to be archivelog mode<\/p>\n<p>sqlplus \/ as sysdba<\/p>\n<p>SQL&gt; select log_mode from gv$database;<\/p>\n<p>LOG_MODE<br \/>\n&#8212;&#8212;&#8212;&#8212;<br \/>\nARCHIVELOG<br \/>\nARCHIVELOG<\/p>\n<p>SQL&gt; alter database force logging;<\/p>\n<p>Database altered.<\/p>\n<p>SQL&gt; alter system set db_file_name_convert=&#8217;+DATA\/ORA19CD1\/DATAFILE&#8217;,&#8217;+DATA\/ORA19C\/DATAFILE&#8217;,&#8217;+FRA\/ORA19CD1\/DATAFILE&#8217;,&#8217;+FRA\/ORA19C\/DATAFILE&#8217; scope=spfile;<\/p>\n<p>System altered.<\/p>\n<p>SQL&gt; alter system set log_file_name_convert=&#8217;+DATA\/ORA19CD1\/ONLINELOG&#8217;,&#8217;+DATA\/ORA19C\/ONLINELOG&#8217;,&#8217;+FRA\/ORA19CD1\/ONLINELOG&#8217;,&#8217;+FRA\/ORA19C\/ONLINELOG&#8217; scope=spfile;<\/p>\n<p>System altered.<\/p>\n<p>SQL&gt; alter system set log_archive_config=&#8217;DG_CONFIG=(ORA19C,ORA19CD1)&#8217;;<\/p>\n<p>System altered.<\/p>\n<p>SQL&gt; alter system set log_archive_dest_1=&#8217;LOCATION=USE_DB_RECOVERY_FILE_DEST VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=ORA19C&#8217;;<\/p>\n<p>System altered.<\/p>\n<p>SQL&gt; alter system set log_archive_dest_2=&#8217;SERVICE=DG_ORA19C ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=ORA19CD1&#8242;;<\/p>\n<p>System altered.<\/p>\n<p>SQL&gt; alter system set log_archive_dest_state_2=&#8217;ENABLE&#8217;;<\/p>\n<p>System altered.<\/p>\n<p>SQL&gt; alter system set log_archive_format=&#8217;%t_%s_%r.arc&#8217; scope=spfile;<\/p>\n<p>System altered.<\/p>\n<p>SQL&gt; alter system set fal_client=&#8217;PRI_ORA19C&#8217;;<\/p>\n<p>System altered.<\/p>\n<p>SQL&gt; alter system set fal_server=&#8217;DG_ORA19C&#8217;;<\/p>\n<p>System altered.<\/p>\n<p>SQL&gt; alter system set standby_file_management=&#8217;AUTO&#8217;;<\/p>\n<p>System altered.<\/p>\n<p>SQL&gt; alter system set remote_login_passwordfile=&#8217;exclusive&#8217; scope=spfile;<\/p>\n<p>System altered.<\/p>\n<p>SQL&gt; alter database flashback on;<\/p>\n<p>Database altered.<\/p>\n<p>SQL&gt; alter database add standby logfile size 200M;<\/p>\n<p>Database altered.<\/p>\n<p>SQL&gt; alter database add standby logfile size 200M;<\/p>\n<p>Database altered.<\/p>\n<p>SQL&gt; alter database add standby logfile size 200M;<\/p>\n<p>Database altered.<\/p>\n<p>SQL&gt; alter database add standby logfile size 200M;<\/p>\n<p>Database altered.<\/p>\n<p>SQL&gt; alter database add standby logfile size 200M;<\/p>\n<p>Database altered.<\/p>\n<p>SQL&gt; exit<\/p>\n<p>srvctl stop database -d ORA19C<br \/>\nsrvctl start database -d ORA19C<\/p>\n<p>sqlplus \/ as sysdba<\/p>\n<p>SQL&gt; create pfile=&#8217;\/tmp\/pfile.ora&#8217; from spfile;<\/p>\n<p>File created.<\/p>\n<p>more \/tmp\/pfile.ora<\/p>\n<p>ORA19C1.__data_transfer_cache_size=0<br \/>\nORA19C2.__data_transfer_cache_size=0<br \/>\nORA19C1.__db_cache_size=2214592512<br \/>\nORA19C2.__db_cache_size=2214592512<br \/>\nORA19C1.__inmemory_ext_roarea=0<br \/>\nORA19C2.__inmemory_ext_roarea=0<br \/>\nORA19C1.__inmemory_ext_rwarea=0<br \/>\nORA19C2.__inmemory_ext_rwarea=0<br \/>\nORA19C1.__java_pool_size=0<br \/>\nORA19C2.__java_pool_size=0<br \/>\nORA19C1.__large_pool_size=16777216<br \/>\nORA19C2.__large_pool_size=16777216<br \/>\nORA19C1.__oracle_base=&#8217;\/oracle\/db\/19.3.0&#8217;#ORACLE_BASE set from environment<br \/>\nORA19C2.__oracle_base=&#8217;\/oracle\/db\/19.3.0&#8217;#ORACLE_BASE set from environment<br \/>\nORA19C1.__pga_aggregate_target=1023410176<br \/>\nORA19C2.__pga_aggregate_target=1023410176<br \/>\nORA19C1.__sga_target=3070230528<br \/>\nORA19C2.__sga_target=3070230528<br \/>\nORA19C1.__shared_io_pool_size=134217728<br \/>\nORA19C2.__shared_io_pool_size=134217728<br \/>\nORA19C1.__shared_pool_size=687865856<br \/>\nORA19C2.__shared_pool_size=687865856<br \/>\nORA19C1.__streams_pool_size=0<br \/>\nORA19C2.__streams_pool_size=0<br \/>\nORA19C1.__unified_pga_pool_size=0<br \/>\nORA19C2.__unified_pga_pool_size=0<br \/>\n*.audit_file_dest=&#8217;\/oracle\/db\/19.3.0\/admin\/ORA19C\/adump&#8217;<br \/>\n*.audit_trail=&#8217;db&#8217;<br \/>\n*.cluster_database=true<br \/>\n*.compatible=&#8217;19.0.0&#8242;<br \/>\n*.control_files=&#8217;+DATA\/ORA19C\/CONTROLFILE\/current.261.1021367051&#8242;,&#8217;+FRA\/ORA19C\/CONTROLFILE\/current.256.1021367053&#8242;<br \/>\n*.db_block_size=8192<br \/>\n*.db_create_file_dest=&#8217;+DATA&#8217;<br \/>\n*.db_file_name_convert=&#8217;+DATA\/ORA19CD1\/DATAFILE&#8217;,&#8217;+DATA\/ORA19C\/DATAFILE&#8217;,&#8217;+FRA\/ORA19CD1\/DATAFILE&#8217;,&#8217;+FRA\/ORA19C\/DATAFILE&#8217;<br \/>\n*.db_name=&#8217;ORA19C&#8217;<br \/>\n*.db_recovery_file_dest=&#8217;+FRA&#8217;<br \/>\n*.db_recovery_file_dest_size=20000m<br \/>\n*.diagnostic_dest=&#8217;\/oracle\/db\/19.3.0&#8242;<br \/>\n*.dispatchers='(PROTOCOL=TCP) (SERVICE=ORA19CXDB)&#8217;<br \/>\n*.fal_client=&#8217;PRI_ORA19C&#8217;<br \/>\n*.fal_server=&#8217;DG_ORA19C&#8217;<br \/>\nfamily:dw_helper.instance_mode=&#8217;read-only&#8217;<br \/>\nORA19C1.instance_number=1<br \/>\nORA19C2.instance_number=2<br \/>\n*.local_listener=&#8217;-oraagent-dummy-&#8216;<br \/>\n*.log_archive_config=&#8217;DG_CONFIG=(ORA19C,ORA19CD1)&#8217;<br \/>\n*.log_archive_dest_1=&#8217;LOCATION=USE_DB_RECOVERY_FILE_DEST VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=ORA19C&#8217;<br \/>\n*.log_archive_dest_2=&#8217;SERVICE=DG_ORA19C ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=ORA19CD1&#8242;<br \/>\n*.log_archive_dest_state_2=&#8217;ENABLE&#8217;<br \/>\n*.log_archive_format=&#8217;%t_%s_%r.arc&#8217;<br \/>\n*.log_file_name_convert=&#8217;+DATA\/ORA19CD1\/ONLINELOG&#8217;,&#8217;+DATA\/ORA19C\/ONLINELOG&#8217;,&#8217;+FRA\/ORA19CD1\/ONLINELOG&#8217;,&#8217;+FRA\/ORA19C\/ONLINELOG&#8217;<br \/>\n*.nls_language=&#8217;AMERICAN&#8217;<br \/>\n*.nls_territory=&#8217;AMERICA&#8217;<br \/>\n*.open_cursors=300<br \/>\n*.pga_aggregate_target=974m<br \/>\n*.processes=320<br \/>\n*.remote_login_passwordfile=&#8217;exclusive&#8217;<br \/>\n*.sga_target=2922m<br \/>\n*.standby_file_management=&#8217;AUTO&#8217;<br \/>\nORA19C2.thread=2<br \/>\nORA19C1.thread=1<br \/>\nORA19C1.undo_tablespace=&#8217;UNDOTBS1&#8242;<br \/>\nORA19C2.undo_tablespace=&#8217;UNDOTBS2&#8242;<\/p>\n<p>&nbsp;<\/p>\n<p>Create password file<\/p>\n<p>orapwd file=$ORACLE_HOME\/dbs\/orapwORA19C<\/p>\n<p>Copy password file and pfile to standby with scp<\/p><\/blockquote>\n<p><strong>Standby Side<\/strong><\/p>\n<blockquote><p>cd $ORACLE_HOME\/dbs<\/p>\n<p>mv orapwORA19C orapwORA19CD1<\/p>\n<p>Configure pfile like below.<\/p>\n<p>vi \/tmp\/pfile.ora<\/p>\n<p>*.__data_transfer_cache_size=0<br \/>\n*.__db_cache_size=2231369728<br \/>\n*.__inmemory_ext_roarea=0<br \/>\n*.__inmemory_ext_rwarea=0<br \/>\n*.__java_pool_size=0<br \/>\n*.__large_pool_size=16777216<br \/>\n*.__oracle_base=&#8217;\/oracle\/db\/19.3.0&#8217;#ORACLE_BASE set from environment<br \/>\n*.__pga_aggregate_target=1023410176<br \/>\n*.__sga_target=3070230528<br \/>\n*.__shared_io_pool_size=134217728<br \/>\n*.__shared_pool_size=671088640<br \/>\n*.__streams_pool_size=0<br \/>\n*.__unified_pga_pool_size=0<br \/>\n*.audit_file_dest=&#8217;\/oracle\/db\/19.3.0\/admin\/ORA19CD1\/adump&#8217;<br \/>\n*.audit_trail=&#8217;db&#8217;<br \/>\n*.cluster_database=false<br \/>\n*.compatible=&#8217;19.0.0&#8242;<br \/>\n*.control_files=&#8217;+DATA\/ORA19CD1\/CONTROLFILE\/current.261.1021367051&#8242;,&#8217;+FRA\/ORA19CD1\/CONTROLFILE\/current.256.1021367053&#8242;<br \/>\n*.db_block_size=8192<br \/>\n*.db_create_file_dest=&#8217;+DATA&#8217;<br \/>\n*.db_file_name_convert=&#8217;+DATA\/ORA19C\/DATAFILE&#8217;,&#8217;+DATA\/ORA19CD1\/DATAFILE&#8217;,&#8217;+FRA\/ORA19C\/DATAFILE&#8217;,&#8217;+FRA\/ORA19CD1\/DATAFILE&#8217;<br \/>\n*.db_name=&#8217;ORA19C&#8217;<br \/>\n*.db_unique_name=&#8217;ORA19CD1&#8242;<br \/>\n*.db_recovery_file_dest=&#8217;+FRA&#8217;<br \/>\n*.db_recovery_file_dest_size=20000m<br \/>\n*.diagnostic_dest=&#8217;\/oracle\/db\/19.3.0&#8242;<br \/>\n*.dispatchers='(PROTOCOL=TCP) (SERVICE=ORA19CD1XDB)&#8217;<br \/>\n*.fal_client=&#8217;DG_ORA19C&#8217;<br \/>\n*.fal_server=&#8217;PRI_ORA19C&#8217;<br \/>\nfamily:dw_helper.instance_mode=&#8217;read-only&#8217;<br \/>\n*.local_listener=&#8217;-oraagent-dummy-&#8216;<br \/>\n*.log_archive_config=&#8217;DG_CONFIG=(ORA19C,ORA19CD1)&#8217;<br \/>\n*.log_archive_dest_1=&#8217;LOCATION=USE_DB_RECOVERY_FILE_DEST VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=ORA19CD1&#8242;<br \/>\n*.log_archive_dest_2=&#8217;SERVICE=PRI_ORA19C ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=ORA19C&#8217;<br \/>\n*.log_archive_dest_state_2=&#8217;DEFER&#8217;<br \/>\n*.log_archive_format=&#8217;%t_%s_%r.arc&#8217;<br \/>\n*.log_file_name_convert=&#8217;+DATA\/ORA19C\/ONLINELOG&#8217;,&#8217;+DATA\/ORA19CD1\/ONLINELOG&#8217;,&#8217;+FRA\/ORA19C\/ONLINELOG&#8217;,&#8217;+FRA\/ORA19CD1\/ONLINELOG&#8217;<br \/>\n*.nls_language=&#8217;AMERICAN&#8217;<br \/>\n*.nls_territory=&#8217;AMERICA&#8217;<br \/>\n*.open_cursors=300<br \/>\n*.pga_aggregate_target=974m<br \/>\n*.processes=320<br \/>\n*.remote_login_passwordfile=&#8217;exclusive&#8217;<br \/>\n*.sga_target=2922m<br \/>\n*.standby_file_management=&#8217;AUTO&#8217;<br \/>\n*.undo_tablespace=&#8217;UNDOTBS1&#8242;<\/p>\n<p>&nbsp;<\/p>\n<p>mkdir -p \/oracle\/db\/19.3.0\/admin\/ORA19CD1\/adump<\/p>\n<p>[oracle@oracle19cdg1 dbs]$ sqlplus \/ as sysdba<\/p>\n<p>SQL*Plus: Release 19.0.0.0.0 &#8211; Production on Mon Oct 14 09:57:24 2019<br \/>\nVersion 19.3.0.0.0<\/p>\n<p>Copyright (c) 1982, 2019, Oracle. All rights reserved.<\/p>\n<p>Connected to an idle instance.<\/p>\n<p>SQL&gt; create spfile from pfile=&#8217;\/tmp\/pfile.ora&#8217;;<\/p>\n<p>File created.<\/p>\n<p>SQL&gt; startup nomount;<br \/>\nORACLE instance started.<\/p>\n<p>Total System Global Area 3070227080 bytes<br \/>\nFixed Size 8901256 bytes<br \/>\nVariable Size 687865856 bytes<br \/>\nDatabase Buffers 2365587456 bytes<br \/>\nRedo Buffers 7872512 bytes<br \/>\nSQL&gt; exit;<\/p><\/blockquote>\n<p>Initialize Data Guard<\/p>\n<blockquote><p>[oracle@oracle19cdg1 dbs]$ rman target sys@PRI_ORA19C auxiliary sys@DG_ORA19C<\/p>\n<p>Recovery Manager: Release 19.0.0.0.0 &#8211; Production on Mon Oct 14 09:58:56 2019<br \/>\nVersion 19.3.0.0.0<\/p>\n<p>Copyright (c) 1982, 2019, Oracle and\/or its affiliates. All rights reserved.<\/p>\n<p>target database Password:<br \/>\nconnected to target database: ORA19C (DBID=1074555083)<br \/>\nauxiliary database Password:<br \/>\nconnected to auxiliary database: ORA19C (not mounted)<\/p>\n<p>RMAN&gt; duplicate target database for standby from active database dorecover nofilenamecheck;<\/p>\n<p>Starting Duplicate Db at 14-OCT-19<br \/>\nusing target database control file instead of recovery catalog<br \/>\nallocated channel: ORA_AUX_DISK_1<br \/>\nchannel ORA_AUX_DISK_1: SID=390 device type=DISK<br \/>\ncurrent log archived<\/p>\n<p>contents of Memory Script:<br \/>\n{<br \/>\nbackup as copy reuse<br \/>\npasswordfile auxiliary format &#8216;\/oracle\/db\/19.3.0\/db_home\/dbs\/orapwORA19CD1&#8217; ;<br \/>\n}<br \/>\nexecuting Memory Script<\/p>\n<p>Starting backup at 14-OCT-19<br \/>\nallocated channel: ORA_DISK_1<br \/>\nchannel ORA_DISK_1: SID=154 instance=ORA19C1 device type=DISK<br \/>\nFinished backup at 14-OCT-19<\/p>\n<p>contents of Memory Script:<br \/>\n{<br \/>\nsql clone &#8220;alter system set control_files =<br \/>\n&#8221;+DATA\/ORA19CD1\/CONTROLFILE\/current.256.1021629589&#8221;, &#8221;+FRA\/ORA19CD1\/CONTROLFILE\/current.256.1021629589&#8221; comment=<br \/>\n&#8221;Set by RMAN&#8221; scope=spfile&#8221;;<br \/>\nrestore clone from service &#8216;PRI_ORA19C&#8217; standby controlfile;<br \/>\n}<br \/>\nexecuting Memory Script<\/p>\n<p>sql statement: alter system set control_files = &#8221;+DATA\/ORA19CD1\/CONTROLFILE\/current.256.1021629589&#8221;, &#8221;+FRA\/ORA19CD1\/CONTROLFILE\/current.256.1021629589&#8221; comment= &#8221;Set by RMAN&#8221; scope=spfile<\/p>\n<p>Starting restore at 14-OCT-19<br \/>\nusing channel ORA_AUX_DISK_1<\/p>\n<p>channel ORA_AUX_DISK_1: starting datafile backup set restore<br \/>\nchannel ORA_AUX_DISK_1: using network backup set from service PRI_ORA19C<br \/>\nchannel ORA_AUX_DISK_1: restoring control file<br \/>\nchannel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:01<br \/>\noutput file name=+DATA\/ORA19CD1\/CONTROLFILE\/current.258.1021629593<br \/>\noutput file name=+FRA\/ORA19CD1\/CONTROLFILE\/current.258.1021629593<br \/>\nFinished restore at 14-OCT-19<\/p>\n<p>contents of Memory Script:<br \/>\n{<br \/>\nsql clone &#8216;alter database mount standby database&#8217;;<br \/>\n}<br \/>\nexecuting Memory Script<\/p>\n<p>sql statement: alter database mount standby database<br \/>\nRMAN-05529: warning: DB_FILE_NAME_CONVERT resulted in invalid ASM names; names changed to disk group only.<br \/>\nRMAN-05158: WARNING: auxiliary (tempfile) file name +DATA\/ORA19C\/TEMPFILE\/temp.264.1021367069 conflicts with a file used by the target database<\/p>\n<p>contents of Memory Script:<br \/>\n{<br \/>\nset newname for tempfile 1 to<br \/>\n&#8220;+DATA&#8221;;<br \/>\nswitch clone tempfile all;<br \/>\nset newname for datafile 1 to<br \/>\n&#8220;+DATA&#8221;;<br \/>\nset newname for datafile 3 to<br \/>\n&#8220;+DATA&#8221;;<br \/>\nset newname for datafile 4 to<br \/>\n&#8220;+DATA&#8221;;<br \/>\nset newname for datafile 5 to<br \/>\n&#8220;+DATA&#8221;;<br \/>\nset newname for datafile 7 to<br \/>\n&#8220;+DATA&#8221;;<br \/>\nrestore<br \/>\nfrom nonsparse from service<br \/>\n&#8216;PRI_ORA19C&#8217; clone database<br \/>\n;<br \/>\nsql &#8216;alter system archive log current&#8217;;<br \/>\n}<br \/>\nexecuting Memory Script<\/p>\n<p>executing command: SET NEWNAME<\/p>\n<p>renamed tempfile 1 to +DATA in control file<\/p>\n<p>executing command: SET NEWNAME<\/p>\n<p>executing command: SET NEWNAME<\/p>\n<p>executing command: SET NEWNAME<\/p>\n<p>executing command: SET NEWNAME<\/p>\n<p>executing command: SET NEWNAME<\/p>\n<p>Starting restore at 14-OCT-19<br \/>\nusing channel ORA_AUX_DISK_1<\/p>\n<p>channel ORA_AUX_DISK_1: starting datafile backup set restore<br \/>\nchannel ORA_AUX_DISK_1: using network backup set from service PRI_ORA19C<br \/>\nchannel ORA_AUX_DISK_1: specifying datafile(s) to restore from backup set<br \/>\nchannel ORA_AUX_DISK_1: restoring datafile 00001 to +DATA<br \/>\nchannel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:07<br \/>\nchannel ORA_AUX_DISK_1: starting datafile backup set restore<br \/>\nchannel ORA_AUX_DISK_1: using network backup set from service PRI_ORA19C<br \/>\nchannel ORA_AUX_DISK_1: specifying datafile(s) to restore from backup set<br \/>\nchannel ORA_AUX_DISK_1: restoring datafile 00003 to +DATA<br \/>\nchannel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:07<br \/>\nchannel ORA_AUX_DISK_1: starting datafile backup set restore<br \/>\nchannel ORA_AUX_DISK_1: using network backup set from service PRI_ORA19C<br \/>\nchannel ORA_AUX_DISK_1: specifying datafile(s) to restore from backup set<br \/>\nchannel ORA_AUX_DISK_1: restoring datafile 00004 to +DATA<br \/>\nchannel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:01<br \/>\nchannel ORA_AUX_DISK_1: starting datafile backup set restore<br \/>\nchannel ORA_AUX_DISK_1: using network backup set from service PRI_ORA19C<br \/>\nchannel ORA_AUX_DISK_1: specifying datafile(s) to restore from backup set<br \/>\nchannel ORA_AUX_DISK_1: restoring datafile 00005 to +DATA<br \/>\nchannel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:02<br \/>\nchannel ORA_AUX_DISK_1: starting datafile backup set restore<br \/>\nchannel ORA_AUX_DISK_1: using network backup set from service PRI_ORA19C<br \/>\nchannel ORA_AUX_DISK_1: specifying datafile(s) to restore from backup set<br \/>\nchannel ORA_AUX_DISK_1: restoring datafile 00007 to +DATA<br \/>\nchannel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:01<br \/>\nFinished restore at 14-OCT-19<\/p>\n<p>sql statement: alter system archive log current<br \/>\ncurrent log archived<\/p>\n<p>contents of Memory Script:<br \/>\n{<br \/>\nrestore clone force from service &#8216;PRI_ORA19C&#8217;<br \/>\narchivelog from scn 3053451;<br \/>\nswitch clone datafile all;<br \/>\n}<br \/>\nexecuting Memory Script<\/p>\n<p>Starting restore at 14-OCT-19<br \/>\nusing channel ORA_AUX_DISK_1<\/p>\n<p>channel ORA_AUX_DISK_1: starting archived log restore to default destination<br \/>\nchannel ORA_AUX_DISK_1: using network backup set from service PRI_ORA19C<br \/>\nchannel ORA_AUX_DISK_1: restoring archived log<br \/>\narchived log thread=1 sequence=13<br \/>\nchannel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:01<br \/>\nchannel ORA_AUX_DISK_1: starting archived log restore to default destination<br \/>\nchannel ORA_AUX_DISK_1: using network backup set from service PRI_ORA19C<br \/>\nchannel ORA_AUX_DISK_1: restoring archived log<br \/>\narchived log thread=1 sequence=14<br \/>\nchannel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:01<br \/>\nchannel ORA_AUX_DISK_1: starting archived log restore to default destination<br \/>\nchannel ORA_AUX_DISK_1: using network backup set from service PRI_ORA19C<br \/>\nchannel ORA_AUX_DISK_1: restoring archived log<br \/>\narchived log thread=2 sequence=7<br \/>\nchannel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:02<br \/>\nchannel ORA_AUX_DISK_1: starting archived log restore to default destination<br \/>\nchannel ORA_AUX_DISK_1: using network backup set from service PRI_ORA19C<br \/>\nchannel ORA_AUX_DISK_1: restoring archived log<br \/>\narchived log thread=2 sequence=8<br \/>\nchannel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:01<br \/>\nchannel ORA_AUX_DISK_1: starting archived log restore to default destination<br \/>\nchannel ORA_AUX_DISK_1: using network backup set from service PRI_ORA19C<br \/>\nchannel ORA_AUX_DISK_1: restoring archived log<br \/>\narchived log thread=2 sequence=9<br \/>\nchannel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:01<br \/>\nFinished restore at 14-OCT-19<\/p>\n<p>datafile 1 switched to datafile copy<br \/>\ninput datafile copy RECID=6 STAMP=1021629632 file name=+DATA\/ORA19CD1\/DATAFILE\/system.259.1021629601<br \/>\ndatafile 3 switched to datafile copy<br \/>\ninput datafile copy RECID=7 STAMP=1021629632 file name=+DATA\/ORA19CD1\/DATAFILE\/sysaux.260.1021629607<br \/>\ndatafile 4 switched to datafile copy<br \/>\ninput datafile copy RECID=8 STAMP=1021629632 file name=+DATA\/ORA19CD1\/DATAFILE\/undotbs1.261.1021629615<br \/>\ndatafile 5 switched to datafile copy<br \/>\ninput datafile copy RECID=9 STAMP=1021629632 file name=+DATA\/ORA19CD1\/DATAFILE\/undotbs2.262.1021629617<br \/>\ndatafile 7 switched to datafile copy<br \/>\ninput datafile copy RECID=10 STAMP=1021629632 file name=+DATA\/ORA19CD1\/DATAFILE\/users.263.1021629617<\/p>\n<p>contents of Memory Script:<br \/>\n{<br \/>\nset until scn 3055123;<br \/>\nrecover<br \/>\nstandby<br \/>\nclone database<br \/>\ndelete archivelog<br \/>\n;<br \/>\n}<br \/>\nexecuting Memory Script<\/p>\n<p>executing command: SET until clause<\/p>\n<p>Starting recover at 14-OCT-19<br \/>\nusing channel ORA_AUX_DISK_1<\/p>\n<p>starting media recovery<\/p>\n<p>archived log for thread 1 with sequence 13 is already on disk as file +FRA\/ORA19CD1\/ARCHIVELOG\/2019_10_14\/thread_1_seq_13.259.1021629627<br \/>\narchived log for thread 1 with sequence 14 is already on disk as file +FRA\/ORA19CD1\/ARCHIVELOG\/2019_10_14\/thread_1_seq_14.260.1021629627<br \/>\narchived log for thread 2 with sequence 8 is already on disk as file +FRA\/ORA19CD1\/ARCHIVELOG\/2019_10_14\/thread_2_seq_8.262.1021629631<br \/>\narchived log for thread 2 with sequence 9 is already on disk as file +FRA\/ORA19CD1\/ARCHIVELOG\/2019_10_14\/thread_2_seq_9.263.1021629631<br \/>\narchived log file name=+FRA\/ORA19CD1\/ARCHIVELOG\/2019_10_14\/thread_1_seq_13.259.1021629627 thread=1 sequence=13<br \/>\narchived log file name=+FRA\/ORA19CD1\/ARCHIVELOG\/2019_10_14\/thread_2_seq_8.262.1021629631 thread=2 sequence=8<br \/>\narchived log file name=+FRA\/ORA19CD1\/ARCHIVELOG\/2019_10_14\/thread_2_seq_9.263.1021629631 thread=2 sequence=9<br \/>\narchived log file name=+FRA\/ORA19CD1\/ARCHIVELOG\/2019_10_14\/thread_1_seq_14.260.1021629627 thread=1 sequence=14<br \/>\nmedia recovery complete, elapsed time: 00:00:00<br \/>\nFinished recover at 14-OCT-19<\/p>\n<p>contents of Memory Script:<br \/>\n{<br \/>\ndelete clone force archivelog all;<br \/>\n}<br \/>\nexecuting Memory Script<\/p>\n<p>released channel: ORA_DISK_1<br \/>\nreleased channel: ORA_AUX_DISK_1<br \/>\nallocated channel: ORA_DISK_1<br \/>\nchannel ORA_DISK_1: SID=154 instance=ORA19C1 device type=DISK<br \/>\ndeleted archived log<br \/>\narchived log file name=+FRA\/ORA19CD1\/ARCHIVELOG\/2019_10_14\/thread_1_seq_13.259.1021629627 RECID=1 STAMP=1021629626<br \/>\ndeleted archived log<br \/>\narchived log file name=+FRA\/ORA19CD1\/ARCHIVELOG\/2019_10_14\/thread_1_seq_14.260.1021629627 RECID=2 STAMP=1021629627<br \/>\ndeleted archived log<br \/>\narchived log file name=+FRA\/ORA19CD1\/ARCHIVELOG\/2019_10_14\/thread_2_seq_7.261.1021629629 RECID=3 STAMP=1021629629<br \/>\ndeleted archived log<br \/>\narchived log file name=+FRA\/ORA19CD1\/ARCHIVELOG\/2019_10_14\/thread_2_seq_8.262.1021629631 RECID=4 STAMP=1021629630<br \/>\ndeleted archived log<br \/>\narchived log file name=+FRA\/ORA19CD1\/ARCHIVELOG\/2019_10_14\/thread_2_seq_9.263.1021629631 RECID=5 STAMP=1021629631<br \/>\nDeleted 5 objects<\/p>\n<p>Finished Duplicate Db at 14-OCT-19<\/p>\n<p>RMAN&gt; exit;<\/p><\/blockquote>\n<p>Start Data Guard as Active Data Guard<\/p>\n<blockquote><p>[oracle@oracle19cdg1 dbs]$ sqlplus \/ as sysdba<\/p>\n<p>SQL*Plus: Release 19.0.0.0.0 &#8211; Production on Mon Oct 14 10:01:44 2019<br \/>\nVersion 19.3.0.0.0<\/p>\n<p>Copyright (c) 1982, 2019, Oracle. All rights reserved.<\/p>\n<p>Connected to:<br \/>\nOracle Database 19c Enterprise Edition Release 19.0.0.0.0 &#8211; Production<br \/>\nVersion 19.3.0.0.0<\/p>\n<p>SQL&gt; alter database open read only;<\/p>\n<p>Database altered.<\/p>\n<p>SQL&gt; alter database recover managed standby database disconnect from session;<\/p>\n<p>Database altered.<\/p>\n<p>SQL&gt;<\/p><\/blockquote>\n<p><strong>Activate DML Redirect<\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2697\" src=\"https:\/\/www.fatihacar.com\/blog\/resimler\/active_dml.png\" alt=\"\" width=\"663\" height=\"638\" srcset=\"https:\/\/www.fatihacar.com\/blog\/resimler\/active_dml.png 663w, https:\/\/www.fatihacar.com\/blog\/resimler\/active_dml-300x289.png 300w\" sizes=\"auto, (max-width: 663px) 100vw, 663px\" \/><\/p>\n<p><strong>Primary Side<\/strong><\/p>\n<blockquote><p>SQL&gt; alter system set adg_redirect_dml=true scope=both;<\/p><\/blockquote>\n<p><strong>Standby Side<\/strong><\/p>\n<blockquote><p>SQL&gt; alter system set adg_redirect_dml=true scope=both;<\/p><\/blockquote>\n<p>You can test DML operations on standby side. You have to connect standby side with username password otherwise you get an error just as ORA-16397: statement redirection from Oracle Active Data Guard standby database to primary database failed<\/p>\n<p>Source : Oracle Docs<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Oracle Data Guard ensures high availability, data protection, and disaster recovery for enterprise data. Oracle Data Guard provides a comprehensive set of services that create, maintain, manage, and monitor one or more standby databases to enable production Oracle databases to survive disasters and data corruptions. Oracle Data Guard maintains these standby databases as copies of&#8230;<\/p>\n","protected":false},"author":37,"featured_media":2668,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[1],"tags":[122,125,32],"class_list":["post-2667","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-databases","tag-oracle-19c","tag-oracle-19c-data-guard","tag-oracle-administration"],"jetpack_featured_media_url":"https:\/\/www.fatihacar.com\/blog\/resimler\/Oracle19c_RAC_and_Active_Data_Guard.jpg","jetpack_shortlink":"https:\/\/wp.me\/p39NFI-H1","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/posts\/2667","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/users\/37"}],"replies":[{"embeddable":true,"href":"https:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/comments?post=2667"}],"version-history":[{"count":7,"href":"https:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/posts\/2667\/revisions"}],"predecessor-version":[{"id":2701,"href":"https:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/posts\/2667\/revisions\/2701"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/media\/2668"}],"wp:attachment":[{"href":"https:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/media?parent=2667"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/categories?post=2667"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.fatihacar.com\/blog\/wp-json\/wp\/v2\/tags?post=2667"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}