SlideShare a Scribd company logo
1 of 13
Download to read offline
STANDBY/DATAGUARD
StandBy Database (DATAGUARD) :- It enables very high-speed movement of data
and metadata from one database to another means providing Disaster recovery,
Complete automatic data protection, and High availability. Servers working on Oracle
11g database with base OS Oracle Linux Enterprise. One is currently open and Up On
which huge no. of transaction are going on and while other is in mount mode with
Different geographical locations.
As automate the backups of archives& datafiles from server 1 to server 2, Whenever if
there is problem in currently up server 1 or get destroyed in disaster or burnt out or
require maintenance so to avoid failure of ongoing transactions decrease or decrease in
hit ratio or to maintain no time lag or server down problem, then with few commands to
run the server 2 will automatically up and working as primary server So no loss of
ongoing transactions and Data Loss.
Base OS :- Oracle Linux Enterprise.
Technology :- Oracle 11g, Oracle Data Pump.
Tools :- Linux, Type-2 Hypervisor, Putty.
Two VMWARE Nodes having base OS as ORACLE LINUX ENTERPRISE
1. Primary DB :- Oracle Linux Enterprise on which Oracle Universal Installer (OUI) and Database
COnfriguration Asssistant (dbca) should be installed.
2. Secondary DB:- Only Oracle Linux Enterprise Later this will be converted into StandBy Database or
DATAGUARD.
what is standby database..
:: suppose there is a db p&g this is primary or target db and it is up and all users which are
connected are able to transact
So for user connectivity to this the db should be open.
Until we done whatever recovery is media recovery like files are corrupted or lost which recovered
through backups on server machine
:: but suppose somehow due to any disaster building in which server machine is kept is destroyed or
server machine of database is burn.
Now db is lost even we have archive in tapes which are of no use because we don’t have base db on
which db we apply this archives
:: to solve this we create another database which connected with base db So what ever trans happen
on base will be automatically happens on this another db on together different location
That another db should mount or open ?
that will be on MOUNT(stand by database will always put on mount) not on open because when it is
on open then datafile and redofile is available then transact is taking place and generate SCN no.s
and these SCN number will not match with primary database
if both are open then both db become primary and work individually so stand by database will
always put on mount
As the base db controlfile are updating so is base controlfile will same or different for standby db
We require archives to be updated only for standby so controlfile for stby are different so lets we
call them stby controlfile
As base db will generate stby controlfile with some command On which we apply archives which are
not destroyed.
Otherwise if both are the Master controlfile then how no will obeys each other
:: because data is safe in standby database that why it is called dataguard..
:: directory structure will be same on both stby and base db because the exactly the same
ORACLE_HOME and ORACLE_BASE are copied on stby from base db
We cannot use template because the time may varies
Both are same but base db will in open mode while stby is in mount mode
Base will apply the transact while stby will only listen the instruction
PRACTICAL
PRIMARY DATABASE
SQL>startup
For standby db archives are imp so base db must enabled archive mode
check that primary database is enabled archive mode if not than put..
SQL> archive log list;
set the archive to a different location (So to check multiplexing of archives )
create a new folder with oracle user So to avoid the conflict of permission take care that you should
not login with root user if the switch it to oracle user using “su – oracle”
[oracle@akku ~]$ mkdir -p /u01/app/arch
[oracle@akku ~]$ cd ..
[oracle@akku ~]$ ls –l
To check the current destination of archive logs
SQL>show parameter log_archive_dest;
Almost 31 destination will shown so if four destination is set then ARCH process will make copy of
all 4 set destinations means doing multiplexing so on every logswitch 4 copies will created so for four
destination is set so one of destination is set by us now
:: setting of archive destination
SQL> alter system set log_Archive_dest_2='location=/u01/app/arch' scope=spfile;
:: now startup force so that new destination of arch will be updated
SQL>startup force
By default location of archives is FRA when FRA is configured and no other destination is not given
But if the destination is set the oracle will not go to FRA for archives it will go new destination will set
For multiplexing you can set log_Archive_dest_3, log_Archive_dest_4 etc
Now do some logswitches 2 or 3 archives ( archives are going to above location and extension will be
.dbf if archive location is other than FRA
SQL>alter system switch logfile ;
SQL>/
SQL>/
Now to check where is Archive are created
SQL>desc dictionary;
SQL>select table_name from dictionary where table_name like ‘%ARCHIVE%’ ;
SQL>desc V$ARCHIVE_DEST;
STANDBY DATABASE
create a new folder with root user as it is a fresh having linux
[root@gaurav u01]# mkdir -p /u01/app
change the owner ship to oracle:dba
[root@gaurav u01]# chown -R oracle:dba app
create a new folder with oracle user
[root@gaurav u01]#su - oracle
[oracle@gaurav ~]$ mkdir -p /u01/app/arch
[oracle@gaurav ~]$cd /u01
[oracle@gaurav ~]$ls –l (to check ownership)
now create ORACLE_BASE location of base db on stby db location must be same as base db with
oracle user
[oracle@gaurav ~]$mkdir -p /u01/app/oracle/oradata/prod (here prod is your db name)
now create ORACLE_HOME location of priamry database on standby database location must be
same as base db with oracle user
[oracle@gaurav ~]$mkdir -p /u01/app/oracle/product/11.2.0 (dbhome will not copied here)
As now we have to copy datafiles from base db to stby db but due various transac going on then it is
not possible copy the file without freezing the transac
So we have to freeze the header of PRIMARY DATABASE to maintain consistency of SCN no
PRIMARY DATABASE
SQL>alter database begin backup;
As now we have copy datafiles from base db to stby db so we require the ip and username to login
using scp command
to copy the data file from primary database to standby database goto location of stndby database's
base location..
STANDBY DATABASE
[oracle@gaurav 11.2.0]$ cd /u01/app/oracle/oradata/prod/ (prod is db name)
[oracle@gaurav prod]$ scp oracle@192.168.232.128:/u01/app/oracle/oradata/prod/* .
here the ip is of primary database..and scp is linux command stand for secure copy
PRIMARY DATABASE
create controlfile for standby database from primary database
SQL> alter database create standby controlfile as
'/u01/app/oracle/oradata/prod/stdby_control.ctl';
this command will create stdby_control.ctl file with primary database's files..
STANDBY DATABASE
Now copy stdby controlfile to standby database..
[oracle@gaurav prod]$ scp
oracle@192.168.232.128:/u01/app/oracle/oradata/prod/stdby_control.ctl .
PRIMARY DATABASE
end backup from primary database
SQL> alter database end backup;
Check whether archives are going to above location or not(not neccesary)
if archives are in the fra ,then move it to /u01/app/arch folder by cp command
[oracle@gaurav arch]$cd /u01/app/oracle/fast_recovery_area/
[oracle@gaurav fast_recovery_area]$ls
[oracle@gaurav fast_recovery_area]$cd PROD
[oracle@gaurav PROD]$ls
[oracle@gaurav PROD]$cd archivelog
[oracle@gaurav archivelog]$ls
[oracle@gaurav archivelog]$ cd 2016_04_02 (go to date folder and copy all archives)
[oracle@gaurav 2016_04_02]$cp *.* /u01/app/arch
[oracle@gaurav 2016_04_02]$cd ..
[oracle@gaurav archivelog]$ ls
[oracle@gaurav archivelog]$ cd 2016_04_03
[oracle@gaurav 2016_04_03]$cp *.* /u01/app/arch
[oracle@gaurav 2016_04_03]$cd /u01/app/arch
[oracle@gaurav 2016_04_03]$ls
STANDBY DATABASE
copy all the archive file from base db to stby db
[oracle@gaurav arch]$ scp oracle@192.168.232.128:/u01/app/arch/* .
[oracle@gaurav arch]$ls
go to location of DBHOME at sdby db
[oracle@gaurav 11.2.0]$ cd /u01/app/oracle/product/11.2.0
[oracle@gaurav 11.2.0]$ ssh oracle@192.168.232.128 "(cd /u01/app/oracle/product/11.2.0;tar -cf
- dbhome_1|gzip)"|gunzip|tar -xf -
If password is asked then syntax is correct otherwise syntax is wrong
DESCRIPTION-->
ssh--secure shell command
tar--target archive used to it store all file which are written with it and create only one file id with it
so.. here supose there are 1000 file in dbhome_1 folder if we didn't use tar than 1000 inode entry is
genrated..to avoid this we use tar command..
as we create as many files in harddisk as the range of FILE_ID of the OS
-cf-- to keep original as it is..
-xf-- extract
[oracle@gaurav 11.2.0]$du –sh (check the size these files must equal to that files size of base db)
As all files DBHOME is copied on stby db means we can run all binary commands like dbca or sqlplus
etc for that we have update the .bash_profile of stby database with .bash_profile of base db means
copy all data of .bash_profile of base db to .base_profile of stby db
Open .base_profile of db in two different vi editor
STANDBY DATABASE
:: run the bash profile . ./.bash_profile
[oracle@gaurav ~]$. ./.bash_profile
Is there requirement for listener on which side stby db or base side and why ?
Because base db need contact with stby db to store all its archive on stby db so listener is require on
stdb side
So there must be listener on stby database as base db is client for stby db as base db require to store
its archive on stby db
STANDBY DATABASE
If listener is started on stby side it means we ca run binary on this side
So start the listener
[oracle@gaurav ~]$lsnrctl start
[oracle@gaurav ~]$sqlplus / as sysdba (if this not run then open this in new instance of putty)
SQL> create pfile from spfile;
open pfile in vi editor and change the controlfile path with stdby control file..
open initorcl.ora in vi editor and delete one path of control file
and change it to
[oracle@gaurav ~]$cd /u01/app/oracle/product/11.2.0/dbhome_1/dbs/
[oracle@gaurav ~]$ls
[oracle@gaurav ~]$vi initorcl.ora
*.control_files='/u01/app/oracle/oradata/prod/stdby_control.ctl'
//ADD TWO NEW PARAMETER
*.standby_archive_dest='/u01/app/arch' -->to set destination of archive
*.standby_file_management='AUTO' -->to files management automatically
Means what ever change in file must be reflect on stby db automatically
File close
comment db_recovery_file_dest parameter
**************************************NOTE***************************************
NOT run this command but this command is very useful because in industry if don’t have access of
password of sys user then this command is used because sometime senior dba don’t give
password of sys user the junior dba can change the password using it when database is down
Because we can up db without password But we db is up we change the password using command
If password file is not present then to create password file fire the following command on root (this is
only method to set password of sys user when database is down )
#orapwd=/u01/app/oracle/product/11.2.0/dbhome_1/dbs/orapwprod password=oracle
**********************************************************************************
remove all file from dbs folder other than pfile initprod.ora
and password file prodpwprod.ora..
[oracle@gaurav ~]$cd /u01/app/oracle/product/11.2.0/dbhome_1/dbs/
[oracle@gaurav ~]$ls
[oracle@gaurav dbs]$ rm -rf hc_DBUA0.dat init.ora lkPROD spfileprod.ora hc_prod.dat
PRIMARY DATABASE
create a tns entry of stby db on primary database..
[oracle@gaurav ~]$vncserver :1
Open tight vnc VNC host of primary database
[oracle@gaurav ~]$netmgr
Create tns entry of “test” name
1. host name(ip) will be of stndby datanbase
2. service name will be of prmry db global id here it is (prod)
if not known then check it through listener by start it and check it through [oracle@gaurav
~]$lsnrctl start [oracle@gaurav ~]$lsnrctl status
3. if tns enrty is not correct then archives cannot be copied on stby db side
(prod)
service name:- test
host name:- standby ip
net service name:- prod
At last save and exit close the tight VNC
Run on primary database
[oracle@gaurav ~]$lsnrctl start
[oracle@gaurav ~]$tnsping test ( to check tns entry is working right or not)
STANDBY DATABASE
[oracle@gaurav ~]$cd /u01/app/oracle/product/11.2.0/dbhome_1/dbs/
[oracle@gaurav ~]$ls
As we have created dbhome in stby db but more folders also create on primary db kike
adump,bdump,cdump, udump which must be created on stby db
create adump,bdump,cdump folder on standby database if not created mannualy and check path in
pfile
[oracle@gaurav ~]$cat initprod.ora
[oracle@gaurav ~]$mkdir -p /u01/app/oracle/admin/prod/adump
(location of bdump is same of udump run SQL> show parameter background_dump_dest on base
db to get location )
[oracle@gaurav ~]$mkdir -p /u01/app/oracle/diag/rdbms/prod/prod /trace ( show parameter
background_dump_dest)
(location of cdump run SQL> show parameter core on base db to get location )
[oracle@gaurav ~]$mkdir -p /u01/app/oracle/diag/rdbms/ prod/prod/cdump ( show parameter
core and tab )
PRIMARY DATABASE
Now the archive which are locally made must be sent to remotely to stbt db
to set that archive will also go to stndby db
SQL> alter system set log_archive_dest_3="SERVICE=TEST";
SQL> startup force (to primary database)
SQL> alter system set standby_file_management=auto scope=spfile;
STANDBY DATABASE
SQL> startup nomount on stby database after base db will start
SQL>alter database mount standby database; --> to mount the standby database
As now check that if any new archive is made on primary db side on startup or shutdown time if it
made then copy it stby db side in “/u01/app/arch”
[oracle@gaurav ~]$cd /u01/app/arch/
[oracle@gaurav ~]$scp oracle@192.168.79.129:/u01/app/arch/* .
SQL> recover automatic standby database; this command will check for archive if any of them is
not applied to stndby
Description:- If it is asking for new archive and if it is not made, then cancel
SQL> recover managed standby database disconnect; -> this will take database out of recovery
mode;
OPEN ALERT FILE FOR BOTH PRIMARY AND STANDBY DATABASE AND PRIMARY DB SQL PROMPT.
[oracle@gaurav ~]$:- cd /u01/app/oracle/rdbms/orcl/orcl/trace
[oracle@gaurav ~]$:- tail -f alert_prod.log
Now to check stby is working or not logswitch on primary db side
PRIMARY DATABASE
SQL> alter system switch logfile;
(see both sequences are updated in primary and standby database)
to make standby as primary
now create a datafile on primary side it must be automatically created on stby side and if not then do
one logswitch even if not then your stby db is not made properly
SQL>create tablespace test '/u01/app/oracle/oradata/prod/test01.dbf' size 5m;
SQL> alter system switch logfile;
SUCCESSFULL
*******************************NOTE******************************************
DON’T DO ONLY FOR KNOWLEDGE
TO MAKE STANDBY DATABASE AS PRIMARY DATABASE(STANDBY DATABASE WILL ACT AS
PRIMARY DATABASE)
STANDBY DATABASE
SQL>shut immediate
SQL>startup nomount
SQL>alter database mount standby database;
SQL>alter database activate standby database;
SQL>alter database open;
********************************************************************************
Docker is a container management service. The keywords of Docker are develop , ship
and run anywhere. The whole idea of Docker is for developers to easily develop
applications, ship them into containers which can then be deployed anywhere.
 Docker Engine – It is used for building Docker images and creating Docker
containers.
 Docker Hub – This is the registry which is used to host various Docker images.
 Docker Compose – This is used to define applications using multiple Docker
containers.

More Related Content

What's hot

Pluggable database tutorial
Pluggable database tutorialPluggable database tutorial
Pluggable database tutorialOsama Mustafa
 
How to create a non managed standby database
How to create a non managed  standby databaseHow to create a non managed  standby database
How to create a non managed standby databaseJorge Batista
 
Oracle Data Guard Physical Standby Configuration
Oracle Data Guard Physical Standby ConfigurationOracle Data Guard Physical Standby Configuration
Oracle Data Guard Physical Standby ConfigurationArun Sharma
 
Maa wp-10g-racprimaryracphysicalsta-131940
Maa wp-10g-racprimaryracphysicalsta-131940Maa wp-10g-racprimaryracphysicalsta-131940
Maa wp-10g-racprimaryracphysicalsta-131940gopalchsamanta
 
Pluggable database 3
Pluggable database 3Pluggable database 3
Pluggable database 3Osama Mustafa
 
Steps for upgrading the database to 10g release 2
Steps for upgrading the database to 10g release 2Steps for upgrading the database to 10g release 2
Steps for upgrading the database to 10g release 2nesmaddy
 
oracle upgradation
oracle upgradationoracle upgradation
oracle upgradationinfluxbob
 
Creating a physical standby database 11g on windows
Creating a physical standby database 11g on windowsCreating a physical standby database 11g on windows
Creating a physical standby database 11g on windowsRoo Wall
 
Oracle12c Pluggable Database Hands On - TROUG 2014
Oracle12c Pluggable Database Hands On - TROUG 2014Oracle12c Pluggable Database Hands On - TROUG 2014
Oracle12c Pluggable Database Hands On - TROUG 2014Özgür Umut Vurgun
 
DSpace Manual for BALID Trainee
DSpace Manual for BALID Trainee DSpace Manual for BALID Trainee
DSpace Manual for BALID Trainee Nur Ahammad
 
12cR2 Single-Tenant: Multitenant Features for All Editions
12cR2 Single-Tenant: Multitenant Features for All Editions12cR2 Single-Tenant: Multitenant Features for All Editions
12cR2 Single-Tenant: Multitenant Features for All EditionsFranck Pachot
 
Database decommission process
Database decommission processDatabase decommission process
Database decommission processK Kumar Guduru
 
Content server installation guide
Content server installation guideContent server installation guide
Content server installation guideNaveed Bashir
 

What's hot (20)

Pluggable database tutorial
Pluggable database tutorialPluggable database tutorial
Pluggable database tutorial
 
How to create a non managed standby database
How to create a non managed  standby databaseHow to create a non managed  standby database
How to create a non managed standby database
 
Oracle Data Guard Physical Standby Configuration
Oracle Data Guard Physical Standby ConfigurationOracle Data Guard Physical Standby Configuration
Oracle Data Guard Physical Standby Configuration
 
Maa wp-10g-racprimaryracphysicalsta-131940
Maa wp-10g-racprimaryracphysicalsta-131940Maa wp-10g-racprimaryracphysicalsta-131940
Maa wp-10g-racprimaryracphysicalsta-131940
 
Oracle11g notes
Oracle11g notesOracle11g notes
Oracle11g notes
 
Pluggable database 3
Pluggable database 3Pluggable database 3
Pluggable database 3
 
Steps for upgrading the database to 10g release 2
Steps for upgrading the database to 10g release 2Steps for upgrading the database to 10g release 2
Steps for upgrading the database to 10g release 2
 
oracle upgradation
oracle upgradationoracle upgradation
oracle upgradation
 
Creating a physical standby database 11g on windows
Creating a physical standby database 11g on windowsCreating a physical standby database 11g on windows
Creating a physical standby database 11g on windows
 
121 Pdfsam
121 Pdfsam121 Pdfsam
121 Pdfsam
 
Oracle12c Pluggable Database Hands On - TROUG 2014
Oracle12c Pluggable Database Hands On - TROUG 2014Oracle12c Pluggable Database Hands On - TROUG 2014
Oracle12c Pluggable Database Hands On - TROUG 2014
 
21 Rac
21 Rac21 Rac
21 Rac
 
141 Pdfsam
141 Pdfsam141 Pdfsam
141 Pdfsam
 
161 Rac
161 Rac161 Rac
161 Rac
 
61 Rac
61 Rac61 Rac
61 Rac
 
Physical_Standby_Database_R12.2.4
Physical_Standby_Database_R12.2.4Physical_Standby_Database_R12.2.4
Physical_Standby_Database_R12.2.4
 
DSpace Manual for BALID Trainee
DSpace Manual for BALID Trainee DSpace Manual for BALID Trainee
DSpace Manual for BALID Trainee
 
12cR2 Single-Tenant: Multitenant Features for All Editions
12cR2 Single-Tenant: Multitenant Features for All Editions12cR2 Single-Tenant: Multitenant Features for All Editions
12cR2 Single-Tenant: Multitenant Features for All Editions
 
Database decommission process
Database decommission processDatabase decommission process
Database decommission process
 
Content server installation guide
Content server installation guideContent server installation guide
Content server installation guide
 

Similar to Standby db creation commands

Oracle 11g Installation With ASM and Data Guard Setup
Oracle 11g Installation With ASM and Data Guard SetupOracle 11g Installation With ASM and Data Guard Setup
Oracle 11g Installation With ASM and Data Guard SetupArun Sharma
 
D17316 gc20 l05_phys_sql
D17316 gc20 l05_phys_sqlD17316 gc20 l05_phys_sql
D17316 gc20 l05_phys_sqlMoeen_uddin
 
Shell Scripts for Oracle Database and E-Business Suite.pdf
Shell Scripts for Oracle Database and E-Business Suite.pdfShell Scripts for Oracle Database and E-Business Suite.pdf
Shell Scripts for Oracle Database and E-Business Suite.pdfAkhashRamnath
 
Oracle database hot backup and recovery
Oracle database hot backup and recoveryOracle database hot backup and recovery
Oracle database hot backup and recoveryArun Sharma
 
Oracle interview question & answers
Oracle interview question & answersOracle interview question & answers
Oracle interview question & answersMohammad Wasi
 
Testing Delphix: easy data virtualization
Testing Delphix: easy data virtualizationTesting Delphix: easy data virtualization
Testing Delphix: easy data virtualizationFranck Pachot
 
MDF and LDF in SQL Server
MDF and LDF in SQL ServerMDF and LDF in SQL Server
MDF and LDF in SQL ServerMasum Reza
 
An overview of snowflake
An overview of snowflakeAn overview of snowflake
An overview of snowflakeSivakumar Ramar
 
Disaster Recovery and Cloud Migration for your Apache Hive Warehouse
Disaster Recovery and Cloud Migration for your Apache Hive WarehouseDisaster Recovery and Cloud Migration for your Apache Hive Warehouse
Disaster Recovery and Cloud Migration for your Apache Hive WarehouseDataWorks Summit
 
Sql introduction
Sql introductionSql introduction
Sql introductionvimal_guru
 
Oracle Database 12c "New features"
Oracle Database 12c "New features" Oracle Database 12c "New features"
Oracle Database 12c "New features" Anar Godjaev
 
Handling Database Deployments
Handling Database DeploymentsHandling Database Deployments
Handling Database DeploymentsMike Willbanks
 
Cordova training - Day 9 - SQLITE
Cordova training - Day 9 - SQLITECordova training - Day 9 - SQLITE
Cordova training - Day 9 - SQLITEBinu Paul
 
High concurrency,
Low latency analytics
using Spark/Kudu
 High concurrency,
Low latency analytics
using Spark/Kudu High concurrency,
Low latency analytics
using Spark/Kudu
High concurrency,
Low latency analytics
using Spark/KuduChris George
 
Disaster Recovery and Cloud Migration for your Apache Hive Warehouse
Disaster Recovery and Cloud Migration for your Apache Hive WarehouseDisaster Recovery and Cloud Migration for your Apache Hive Warehouse
Disaster Recovery and Cloud Migration for your Apache Hive WarehouseSankar H
 

Similar to Standby db creation commands (20)

Oracle 11g Installation With ASM and Data Guard Setup
Oracle 11g Installation With ASM and Data Guard SetupOracle 11g Installation With ASM and Data Guard Setup
Oracle 11g Installation With ASM and Data Guard Setup
 
D17316 gc20 l05_phys_sql
D17316 gc20 l05_phys_sqlD17316 gc20 l05_phys_sql
D17316 gc20 l05_phys_sql
 
Shell Scripts for Oracle Database and E-Business Suite.pdf
Shell Scripts for Oracle Database and E-Business Suite.pdfShell Scripts for Oracle Database and E-Business Suite.pdf
Shell Scripts for Oracle Database and E-Business Suite.pdf
 
Oracle database hot backup and recovery
Oracle database hot backup and recoveryOracle database hot backup and recovery
Oracle database hot backup and recovery
 
Oracle interview question & answers
Oracle interview question & answersOracle interview question & answers
Oracle interview question & answers
 
PHP Oracle
PHP OraclePHP Oracle
PHP Oracle
 
Testing Delphix: easy data virtualization
Testing Delphix: easy data virtualizationTesting Delphix: easy data virtualization
Testing Delphix: easy data virtualization
 
MDF and LDF in SQL Server
MDF and LDF in SQL ServerMDF and LDF in SQL Server
MDF and LDF in SQL Server
 
An overview of snowflake
An overview of snowflakeAn overview of snowflake
An overview of snowflake
 
Disaster Recovery and Cloud Migration for your Apache Hive Warehouse
Disaster Recovery and Cloud Migration for your Apache Hive WarehouseDisaster Recovery and Cloud Migration for your Apache Hive Warehouse
Disaster Recovery and Cloud Migration for your Apache Hive Warehouse
 
Sql introduction
Sql introductionSql introduction
Sql introduction
 
Sqllite
SqlliteSqllite
Sqllite
 
Oracle Database 12c "New features"
Oracle Database 12c "New features" Oracle Database 12c "New features"
Oracle Database 12c "New features"
 
Handling Database Deployments
Handling Database DeploymentsHandling Database Deployments
Handling Database Deployments
 
Cordova training - Day 9 - SQLITE
Cordova training - Day 9 - SQLITECordova training - Day 9 - SQLITE
Cordova training - Day 9 - SQLITE
 
Cloning 2
Cloning 2Cloning 2
Cloning 2
 
Cloning 2
Cloning 2Cloning 2
Cloning 2
 
Oracle ORA Errors
Oracle ORA ErrorsOracle ORA Errors
Oracle ORA Errors
 
High concurrency,
Low latency analytics
using Spark/Kudu
 High concurrency,
Low latency analytics
using Spark/Kudu High concurrency,
Low latency analytics
using Spark/Kudu
High concurrency,
Low latency analytics
using Spark/Kudu
 
Disaster Recovery and Cloud Migration for your Apache Hive Warehouse
Disaster Recovery and Cloud Migration for your Apache Hive WarehouseDisaster Recovery and Cloud Migration for your Apache Hive Warehouse
Disaster Recovery and Cloud Migration for your Apache Hive Warehouse
 

Recently uploaded

APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDGMarianaLemus7
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraDeakin University
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024The Digital Insurer
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024BookNet Canada
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Unlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power SystemsUnlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power SystemsPrecisely
 
costume and set research powerpoint presentation
costume and set research powerpoint presentationcostume and set research powerpoint presentation
costume and set research powerpoint presentationphoebematthew05
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr LapshynFwdays
 

Recently uploaded (20)

APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDG
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
The transition to renewables in India.pdf
The transition to renewables in India.pdfThe transition to renewables in India.pdf
The transition to renewables in India.pdf
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning era
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort ServiceHot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
 
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Unlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power SystemsUnlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power Systems
 
costume and set research powerpoint presentation
costume and set research powerpoint presentationcostume and set research powerpoint presentation
costume and set research powerpoint presentation
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
 

Standby db creation commands

  • 1. STANDBY/DATAGUARD StandBy Database (DATAGUARD) :- It enables very high-speed movement of data and metadata from one database to another means providing Disaster recovery, Complete automatic data protection, and High availability. Servers working on Oracle 11g database with base OS Oracle Linux Enterprise. One is currently open and Up On which huge no. of transaction are going on and while other is in mount mode with Different geographical locations. As automate the backups of archives& datafiles from server 1 to server 2, Whenever if there is problem in currently up server 1 or get destroyed in disaster or burnt out or require maintenance so to avoid failure of ongoing transactions decrease or decrease in hit ratio or to maintain no time lag or server down problem, then with few commands to run the server 2 will automatically up and working as primary server So no loss of ongoing transactions and Data Loss. Base OS :- Oracle Linux Enterprise. Technology :- Oracle 11g, Oracle Data Pump. Tools :- Linux, Type-2 Hypervisor, Putty. Two VMWARE Nodes having base OS as ORACLE LINUX ENTERPRISE 1. Primary DB :- Oracle Linux Enterprise on which Oracle Universal Installer (OUI) and Database COnfriguration Asssistant (dbca) should be installed. 2. Secondary DB:- Only Oracle Linux Enterprise Later this will be converted into StandBy Database or DATAGUARD. what is standby database.. :: suppose there is a db p&g this is primary or target db and it is up and all users which are connected are able to transact So for user connectivity to this the db should be open. Until we done whatever recovery is media recovery like files are corrupted or lost which recovered through backups on server machine :: but suppose somehow due to any disaster building in which server machine is kept is destroyed or server machine of database is burn. Now db is lost even we have archive in tapes which are of no use because we don’t have base db on which db we apply this archives :: to solve this we create another database which connected with base db So what ever trans happen on base will be automatically happens on this another db on together different location That another db should mount or open ?
  • 2. that will be on MOUNT(stand by database will always put on mount) not on open because when it is on open then datafile and redofile is available then transact is taking place and generate SCN no.s and these SCN number will not match with primary database if both are open then both db become primary and work individually so stand by database will always put on mount As the base db controlfile are updating so is base controlfile will same or different for standby db We require archives to be updated only for standby so controlfile for stby are different so lets we call them stby controlfile As base db will generate stby controlfile with some command On which we apply archives which are not destroyed. Otherwise if both are the Master controlfile then how no will obeys each other :: because data is safe in standby database that why it is called dataguard.. :: directory structure will be same on both stby and base db because the exactly the same ORACLE_HOME and ORACLE_BASE are copied on stby from base db We cannot use template because the time may varies Both are same but base db will in open mode while stby is in mount mode Base will apply the transact while stby will only listen the instruction PRACTICAL PRIMARY DATABASE SQL>startup For standby db archives are imp so base db must enabled archive mode check that primary database is enabled archive mode if not than put.. SQL> archive log list;
  • 3. set the archive to a different location (So to check multiplexing of archives ) create a new folder with oracle user So to avoid the conflict of permission take care that you should not login with root user if the switch it to oracle user using “su – oracle” [oracle@akku ~]$ mkdir -p /u01/app/arch [oracle@akku ~]$ cd .. [oracle@akku ~]$ ls –l To check the current destination of archive logs SQL>show parameter log_archive_dest; Almost 31 destination will shown so if four destination is set then ARCH process will make copy of all 4 set destinations means doing multiplexing so on every logswitch 4 copies will created so for four destination is set so one of destination is set by us now :: setting of archive destination SQL> alter system set log_Archive_dest_2='location=/u01/app/arch' scope=spfile; :: now startup force so that new destination of arch will be updated SQL>startup force By default location of archives is FRA when FRA is configured and no other destination is not given But if the destination is set the oracle will not go to FRA for archives it will go new destination will set For multiplexing you can set log_Archive_dest_3, log_Archive_dest_4 etc Now do some logswitches 2 or 3 archives ( archives are going to above location and extension will be .dbf if archive location is other than FRA SQL>alter system switch logfile ; SQL>/ SQL>/ Now to check where is Archive are created SQL>desc dictionary; SQL>select table_name from dictionary where table_name like ‘%ARCHIVE%’ ; SQL>desc V$ARCHIVE_DEST; STANDBY DATABASE create a new folder with root user as it is a fresh having linux [root@gaurav u01]# mkdir -p /u01/app
  • 4. change the owner ship to oracle:dba [root@gaurav u01]# chown -R oracle:dba app create a new folder with oracle user [root@gaurav u01]#su - oracle [oracle@gaurav ~]$ mkdir -p /u01/app/arch [oracle@gaurav ~]$cd /u01 [oracle@gaurav ~]$ls –l (to check ownership) now create ORACLE_BASE location of base db on stby db location must be same as base db with oracle user [oracle@gaurav ~]$mkdir -p /u01/app/oracle/oradata/prod (here prod is your db name) now create ORACLE_HOME location of priamry database on standby database location must be same as base db with oracle user [oracle@gaurav ~]$mkdir -p /u01/app/oracle/product/11.2.0 (dbhome will not copied here) As now we have to copy datafiles from base db to stby db but due various transac going on then it is not possible copy the file without freezing the transac So we have to freeze the header of PRIMARY DATABASE to maintain consistency of SCN no PRIMARY DATABASE SQL>alter database begin backup; As now we have copy datafiles from base db to stby db so we require the ip and username to login using scp command to copy the data file from primary database to standby database goto location of stndby database's base location.. STANDBY DATABASE [oracle@gaurav 11.2.0]$ cd /u01/app/oracle/oradata/prod/ (prod is db name) [oracle@gaurav prod]$ scp oracle@192.168.232.128:/u01/app/oracle/oradata/prod/* . here the ip is of primary database..and scp is linux command stand for secure copy PRIMARY DATABASE create controlfile for standby database from primary database
  • 5. SQL> alter database create standby controlfile as '/u01/app/oracle/oradata/prod/stdby_control.ctl'; this command will create stdby_control.ctl file with primary database's files.. STANDBY DATABASE Now copy stdby controlfile to standby database.. [oracle@gaurav prod]$ scp oracle@192.168.232.128:/u01/app/oracle/oradata/prod/stdby_control.ctl . PRIMARY DATABASE end backup from primary database SQL> alter database end backup; Check whether archives are going to above location or not(not neccesary) if archives are in the fra ,then move it to /u01/app/arch folder by cp command [oracle@gaurav arch]$cd /u01/app/oracle/fast_recovery_area/ [oracle@gaurav fast_recovery_area]$ls [oracle@gaurav fast_recovery_area]$cd PROD [oracle@gaurav PROD]$ls [oracle@gaurav PROD]$cd archivelog [oracle@gaurav archivelog]$ls [oracle@gaurav archivelog]$ cd 2016_04_02 (go to date folder and copy all archives) [oracle@gaurav 2016_04_02]$cp *.* /u01/app/arch [oracle@gaurav 2016_04_02]$cd .. [oracle@gaurav archivelog]$ ls [oracle@gaurav archivelog]$ cd 2016_04_03 [oracle@gaurav 2016_04_03]$cp *.* /u01/app/arch [oracle@gaurav 2016_04_03]$cd /u01/app/arch [oracle@gaurav 2016_04_03]$ls STANDBY DATABASE copy all the archive file from base db to stby db [oracle@gaurav arch]$ scp oracle@192.168.232.128:/u01/app/arch/* .
  • 6. [oracle@gaurav arch]$ls go to location of DBHOME at sdby db [oracle@gaurav 11.2.0]$ cd /u01/app/oracle/product/11.2.0 [oracle@gaurav 11.2.0]$ ssh oracle@192.168.232.128 "(cd /u01/app/oracle/product/11.2.0;tar -cf - dbhome_1|gzip)"|gunzip|tar -xf - If password is asked then syntax is correct otherwise syntax is wrong DESCRIPTION--> ssh--secure shell command tar--target archive used to it store all file which are written with it and create only one file id with it so.. here supose there are 1000 file in dbhome_1 folder if we didn't use tar than 1000 inode entry is genrated..to avoid this we use tar command.. as we create as many files in harddisk as the range of FILE_ID of the OS -cf-- to keep original as it is.. -xf-- extract [oracle@gaurav 11.2.0]$du –sh (check the size these files must equal to that files size of base db) As all files DBHOME is copied on stby db means we can run all binary commands like dbca or sqlplus etc for that we have update the .bash_profile of stby database with .bash_profile of base db means copy all data of .bash_profile of base db to .base_profile of stby db Open .base_profile of db in two different vi editor STANDBY DATABASE :: run the bash profile . ./.bash_profile [oracle@gaurav ~]$. ./.bash_profile Is there requirement for listener on which side stby db or base side and why ? Because base db need contact with stby db to store all its archive on stby db so listener is require on stdb side So there must be listener on stby database as base db is client for stby db as base db require to store its archive on stby db STANDBY DATABASE
  • 7. If listener is started on stby side it means we ca run binary on this side So start the listener [oracle@gaurav ~]$lsnrctl start [oracle@gaurav ~]$sqlplus / as sysdba (if this not run then open this in new instance of putty) SQL> create pfile from spfile; open pfile in vi editor and change the controlfile path with stdby control file.. open initorcl.ora in vi editor and delete one path of control file and change it to [oracle@gaurav ~]$cd /u01/app/oracle/product/11.2.0/dbhome_1/dbs/ [oracle@gaurav ~]$ls [oracle@gaurav ~]$vi initorcl.ora *.control_files='/u01/app/oracle/oradata/prod/stdby_control.ctl' //ADD TWO NEW PARAMETER *.standby_archive_dest='/u01/app/arch' -->to set destination of archive *.standby_file_management='AUTO' -->to files management automatically Means what ever change in file must be reflect on stby db automatically File close comment db_recovery_file_dest parameter **************************************NOTE*************************************** NOT run this command but this command is very useful because in industry if don’t have access of password of sys user then this command is used because sometime senior dba don’t give password of sys user the junior dba can change the password using it when database is down Because we can up db without password But we db is up we change the password using command If password file is not present then to create password file fire the following command on root (this is only method to set password of sys user when database is down ) #orapwd=/u01/app/oracle/product/11.2.0/dbhome_1/dbs/orapwprod password=oracle ********************************************************************************** remove all file from dbs folder other than pfile initprod.ora and password file prodpwprod.ora..
  • 8. [oracle@gaurav ~]$cd /u01/app/oracle/product/11.2.0/dbhome_1/dbs/ [oracle@gaurav ~]$ls [oracle@gaurav dbs]$ rm -rf hc_DBUA0.dat init.ora lkPROD spfileprod.ora hc_prod.dat PRIMARY DATABASE create a tns entry of stby db on primary database.. [oracle@gaurav ~]$vncserver :1 Open tight vnc VNC host of primary database [oracle@gaurav ~]$netmgr Create tns entry of “test” name 1. host name(ip) will be of stndby datanbase
  • 9. 2. service name will be of prmry db global id here it is (prod) if not known then check it through listener by start it and check it through [oracle@gaurav ~]$lsnrctl start [oracle@gaurav ~]$lsnrctl status 3. if tns enrty is not correct then archives cannot be copied on stby db side (prod)
  • 10. service name:- test host name:- standby ip net service name:- prod At last save and exit close the tight VNC Run on primary database [oracle@gaurav ~]$lsnrctl start [oracle@gaurav ~]$tnsping test ( to check tns entry is working right or not) STANDBY DATABASE [oracle@gaurav ~]$cd /u01/app/oracle/product/11.2.0/dbhome_1/dbs/ [oracle@gaurav ~]$ls As we have created dbhome in stby db but more folders also create on primary db kike adump,bdump,cdump, udump which must be created on stby db create adump,bdump,cdump folder on standby database if not created mannualy and check path in pfile [oracle@gaurav ~]$cat initprod.ora [oracle@gaurav ~]$mkdir -p /u01/app/oracle/admin/prod/adump
  • 11. (location of bdump is same of udump run SQL> show parameter background_dump_dest on base db to get location ) [oracle@gaurav ~]$mkdir -p /u01/app/oracle/diag/rdbms/prod/prod /trace ( show parameter background_dump_dest) (location of cdump run SQL> show parameter core on base db to get location ) [oracle@gaurav ~]$mkdir -p /u01/app/oracle/diag/rdbms/ prod/prod/cdump ( show parameter core and tab ) PRIMARY DATABASE Now the archive which are locally made must be sent to remotely to stbt db to set that archive will also go to stndby db SQL> alter system set log_archive_dest_3="SERVICE=TEST"; SQL> startup force (to primary database) SQL> alter system set standby_file_management=auto scope=spfile; STANDBY DATABASE SQL> startup nomount on stby database after base db will start SQL>alter database mount standby database; --> to mount the standby database As now check that if any new archive is made on primary db side on startup or shutdown time if it made then copy it stby db side in “/u01/app/arch” [oracle@gaurav ~]$cd /u01/app/arch/ [oracle@gaurav ~]$scp oracle@192.168.79.129:/u01/app/arch/* . SQL> recover automatic standby database; this command will check for archive if any of them is not applied to stndby Description:- If it is asking for new archive and if it is not made, then cancel SQL> recover managed standby database disconnect; -> this will take database out of recovery mode; OPEN ALERT FILE FOR BOTH PRIMARY AND STANDBY DATABASE AND PRIMARY DB SQL PROMPT. [oracle@gaurav ~]$:- cd /u01/app/oracle/rdbms/orcl/orcl/trace
  • 12. [oracle@gaurav ~]$:- tail -f alert_prod.log Now to check stby is working or not logswitch on primary db side PRIMARY DATABASE SQL> alter system switch logfile; (see both sequences are updated in primary and standby database) to make standby as primary now create a datafile on primary side it must be automatically created on stby side and if not then do one logswitch even if not then your stby db is not made properly SQL>create tablespace test '/u01/app/oracle/oradata/prod/test01.dbf' size 5m; SQL> alter system switch logfile; SUCCESSFULL *******************************NOTE****************************************** DON’T DO ONLY FOR KNOWLEDGE TO MAKE STANDBY DATABASE AS PRIMARY DATABASE(STANDBY DATABASE WILL ACT AS PRIMARY DATABASE) STANDBY DATABASE SQL>shut immediate SQL>startup nomount SQL>alter database mount standby database; SQL>alter database activate standby database; SQL>alter database open; ********************************************************************************
  • 13. Docker is a container management service. The keywords of Docker are develop , ship and run anywhere. The whole idea of Docker is for developers to easily develop applications, ship them into containers which can then be deployed anywhere.  Docker Engine – It is used for building Docker images and creating Docker containers.  Docker Hub – This is the registry which is used to host various Docker images.  Docker Compose – This is used to define applications using multiple Docker containers.