Documente Academic
Documente Profesional
Documente Cultură
destination that has this attribute before the transcation can commit.
--affirm and noaffirm
ensure that redo was successfully written to disk on the standyby destination.
noaffirm is the default when async is specified
noaffirm specifes that redo transport destination acknowledges recived redo data
before writing it to the standby redolog
affirm specifes that redo transport destination acknowledges recived redo data a
fter writing it to the standby redolog
>alter system set log_archive_dest_2='service=standb LGWR ASYNC VALID_FOR=(ONLIN
E_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=standb' scope=spfile;
Define state of archiving enable/difer
>alter system set log_archive_dest_state_1=enable
>alter system set log_archive_dest_state_2=enable
Remote_login_passwordfile = must be in exclusive mode
FAL_SERVER-- use for archivelog gap resolution(required only in physical standby
server)
>alter system set fal_server=standb scope spfile;
>alter system set fal_client=proddb scope spfile;
STANDBY_FILE_MANAGEMENT--keep auto to create file automatically on standby.
>alter sytem set standby_file_management=auto scope=spfile;
DB_FILE_NAME_CONVERT--Required when directory structure is different datafile
>alter system set db_file_name_convert='/u01/oradata/proddb','/u01/oradata/stand
b' scope = spfile;
LOG_FILE_NAME_CONVERT--Required when directory structure is different logfile
>alter system set log_file_name_convert='/u01/oradata/proddb','/u01/oradata/stan
db' scope = spfile;
>shutdown immediate;
>startup
>create pfile from spfile;
>scp initprodb.ora dbserver2:/u01/11g/dbs/initstand.ora
>orapwd file=orapwproddb password=oracle force=y
-p
-p
-p
-p
-p
-p
-p
/u01/11g/admin/standb/bdump
/u01/11g/admin/standb/cdump
/u01/11g/admin/standb/adump
/u01/11g/admin/standb/udump
/u01/oradata/standb
/u01/11g/flash_recovery_area
/u02/archives
-----switch over
on primary database
>>select name,open_mode,database_role,protection_mode from v$database;
open_mode---read write
>alter database commit to switchover to standby;
open log file and see what is happening
>shutdown immediate
>startup nomount
>alter database mount standby database;
>>alter database recover managed standby database disconnect from session;
>>select name,open_mode,database_role,protection_mode from v$database;
open_mode---mounted
on physical standby database
>alter database commit to switchover to primary;
>shutdown immediate
>startup
>>select name,open_mode,database_role,protection_mode from v$database;
open_mode---read write
-----Failover
on standby database
alter database recover standby database finish;
alter database activate standby database;
DATA GUARD PROTECTION MODES
There are 3 protection modes. Summarized in the table below.
Mode
The risk of data loss Transfer method Primary status
Maximum Protection
Zero data loss
two-sided protection SYNC
waits for the receipt of information. if it doesn t respond to primary,
ngs
Maximum Availability
Zero data loss single-sided protection
waits for the receipt of information. if it doesn t respond to primary,
its until the timeout parameter . (NET_TIMEOUT)
Maximum Performance
least data loss ASYNC primary never waits for
ipt of information
primary
primary ha
SYNC
primary
primary wa
the rece
Modes of Operation
The following table shows the options giving the benefits and drawbacks.
Mode of Operation
SYNC/
ASYNC
Benefits
Drawbacks
Maximum Protection
SYNC
Never any data loss, no data ever accepted on primary
without being on standby.
Slower response times on primary. Network disruption
between primary and secondary causes downtime of primary database.
Mode of Operation
SYNC/
ASYNC
Benefits
Drawbacks
Maximum Availability
SYNC
Updates must be on standby before accepted on primary,
network disruption means the primary continues running with updates sent to
standby when it is available again.
Slower response times on primary. Data loss possible if
network fails and then site fails.
Mode of Operation
SYNC/
ASYNC
Benefits
Drawbacks
Maximum Performance
ASYNC
No performance slowdown for applications on primary.
Data loss will happen