Dataguard commands and SQL scripts

Physical Standby Commands _________________________ To start redo apply in foreground: SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE; To stop redo apply process on the Standby database (to stop MRP): SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE CANCEL; To start real-time redo apply: SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE USING CURRENT LOGFILE DISCONNECT FROM SESSION;…

Steps to Install Oracle Database 12c Release 2 in Redhat Linux 7.5

A quick Guide on How to Install the Oracle Database 12c Release 2 in Redhat Enterprise Linux 7.5 Server. To Download the Oracle Database Installer, Visit the below URL: http://www.oracle.com/technetwork/database/enterprise-edition/downloads/index.html Prerequiste for Installation: Download the Oracle Database 12c installer package. The Swap Space size should be 16GB . Enable X11 Forwarding to “yes” in sshd…

PostgreSQL 11 Streaming Replication/Hot Standby

To create PostgreSQL replication first we must install PostgreSQL on  Primary and  Standby server. On Primary and Standby: [root@localhost ]# yum -y install epel-release [root@localhost ]# yum -y install bash-completion [root@localhost ]# yum -y install https://download.postgresql.org/pub/repos/yum/11/redhat/rhel-7-x86_64/pgdg-centos11-11-2.noarch.rpm [root@localhost ]# yum install postgresql11-server [root@localhost ]# yum install postgresql11-contrib On Primary: [root@localhost ]# /usr/pgsql-11/bin/postgresql-11-setup initdb Initializing database ……

Solving An Unusual Oracle Upgrade Issue

by Jim Okla January 27, 2015 Posted in: How To I recently came across a very unusual situation. During an upgraded review, I noticed the dba_registry_sqlpatch was empty when it shouldn’t be: SQL> select patch_id, patch_uid, version, action, action_time, status, description from dba_registry_sqlpatch; no rows selected SQL> The expected output should be (from another CDB…

Scenario 1 – Restore control file from backup after loss of all control files

Condition: All copies of the control file have been deleted The data is in the order of files and online redo logs Our control file has backups Database archive works in log mode First we look at where our control files are located SQL> select name from v$controlfile; NAME ——————————————————————————– /u01/app/oracle/oradata/DB11G/control01.ctl /u01/app/oracle/oradata/DB11G/control02.ctl   We then…