...
Dbvisit will create standby database files regardless whether on ASM, Filesystem or ACFS according to the general Oracle rules and concept. The main consideration is always whether you will do file path conversion or not.
The behavior is different for OMF files and non-OMF files. If you don’t know which type of files your primary database is using, be sure to check https://dbvisit.atlassian.net/wiki/spaces/DSMP/pages/3806167060/Prerequisites#5.-Check-Primary-Database-Files-Naming-Structure
...
You will need to set OMF parameters when creating standby database to the same values as on your primary (this . This is done automatically during create standby database wizard), so you don’t have to worry about it in this case.
Note |
---|
OMF parameters on primary and on standby are needed even if your standby file locations are the same as on primary and standby. |
If you would like to have different file paths on primary and standby or if you’re converting between ASM and filesystem (path conversion is done):
...
Following rules will apply for different types of files when standby database is created:
Location of OMF datafiles and tempfiles on standby
They will be created on standby in location <db_create_file_dest>/<db_unique_name>/datafile. For example if you have OMF datafile on primary (primary db_unique_name=SOLO):
...
Info |
---|
db_unique_name is converted by oracle to uppercase for filesystem location. |
Location of OMF redo logs on standby
Info |
---|
Redo member paths on standby will be changed only during standby database activation or graceful switchover |
Will They will be created on standby in location(s) <db_create_online_log_dest_[x]>/<db_unique_name>/onlinelog.
...
Note |
---|
db_file_name_convert and log_file_name_convert must not be set if primary database files are OMF exclusively |
Info |
---|
control_files parameter is not set as controlfiles are OMF |
...
They contain pair or pairs of strings which are used for path conversion when standby database is created
They are valid on standby database only. On primary, they are not effective.
For Dbvisit to work properly, tey they need always set on primary and standby (their values are reversed)
...
Note |
---|
For setting convert parameters in the create standby database wizard, we don’t use single quotes. Make sure to not use any trailing slashes and empty spaces for parameter values. |
Info |
---|
Note that for parameter db_file_name_convert we have to add one more path conversion pair for primary datafile /u02/app/oracle/oradata/DBVONE/convert_tbs_01.dbf. Setting db_file_name_convert only to u01,u02 would place this datafile on standby to the same path as on primary: /u02/app/oracle/oradata/DBVONE/convert_tbs_01.dbf. There’s no way to convert it back if it’s placed on standby together with other datafiles. It would be impossible to perform graceful switchover as the datafile would be expected to be in /u01/app/oracle/oradata/DBVONE/convert_tbs_01.dbf on the old primary / new standby. If the datafile |
...
Note |
---|
After standby database is created, you should set convert parameters on your primary database with opposite reverse values (requires restart): SQL> alter system set db_file_name_convert ='u02','u01','/u02/app/oracle/oradata/DBVONE_u02','/u02/app/oracle/oradata/DBVONE' scope=spfile; SQL> alter system set log_file_name_convert = ‘u02','u01' scope=spfile; This is for proper functionality of failover and switchover. If you skip this step, Dbvisit will set these parameters during switchover automatically. |
...
Primary filesystem to Standby filesystem path conversion example with OMF and non-OMF mix:
Primary database has following configuration:
Code Block |
---|
-- controlfile:
/u02/app/oracle/oradata/SLASH/controlfile/o1_mf_kqh8jsfk_.ctl
/u02/app/oracle/fast_recovery_area/SLASH/controlfile/o1_mf_kqh8jsjw_.ctl
-- redo:
/u02/app/oracle/fast_recovery_area/SLASH/onlinelog/o1_mf_1_lw9or6g7_.log
/u02/app/oracle/fast_recovery_area/SLASH/onlinelog/o1_mf_2_lw9orcp3_.log
/u02/app/oracle/fast_recovery_area/SLASH/onlinelog/o1_mf_3_lw9or7mw_.log
/u02/app/oracle/oradata/SLASH/onlinelog/o1_mf_1_lw9or606_.log
/u02/app/oracle/oradata/SLASH/onlinelog/o1_mf_2_lw9orck6_.log
/u02/app/oracle/oradata/SLASH/onlinelog/o1_mf_3_lw9or7g1_.log
/u02/app/oracle/oradata/SLASH/onlinelog/redo99.log
-- datafiles:
/u02/app/oracle/oradata/SLASH/datafile/o1_mf_system_kqh8ln12_.dbf
/u02/app/oracle/oradata/SLASH/datafile/o1_mf_sysaux_kqh8n4jq_.dbf
/u02/app/oracle/oradata/SLASH/datafile/o1_mf_undotbs1_kqh8ohhc_.dbf
/u02/app/oracle/oradata/SLASH/datafile/o1_mf_users_kqh8pjld_.dbf
/u02/app/oracle/oradata/SLASH/datafile/nonomf.dbf
-- tempfiles:
/u02/app/oracle/oradata/SLASH/datafile/o1_mf_temp_lw9ornvw_.tmp
-- db_unique_name = SLASH
-- db_create_file_dest = /u02/app/oracle/oradata
-- db_recovery_file_dest = /u02/app/oracle/oradata/fast_recovery_area
-- db_create_online_log_dest_[x] is not set
-- db_file_name_convert is not set
-- log_file_name_convert is not set |
All files are OMF except of one datafile (nonomf.dbf
) and one redo member (redo99.log
).
On standby server we want to place all files on u01 instead of u02. So during the create standby database we need to specify following parameters:
...
We need to specify OMF parameters and convert parameters as well, becausew we’re using OMF and non-OMF file types and we want to have path conversion.
Code Block |
---|
-- controlfile:
/u01/app/oracle/oradata/SLASH/controlfile/o1_mf_lxvn3m9f_.ctl
/u01/app/oracle/fast_recovery_area/SLASH/controlfile/o1_mf_lxvn3md3_.ctl
-- redo:
/u01/app/oracle/fast_recovery_area/SLASH/onlinelog/o1_mf_1_lw9or6g7_.log
/u01/app/oracle/fast_recovery_area/SLASH/onlinelog/o1_mf_2_lw9orcp3_.log
/u01/app/oracle/fast_recovery_area/SLASH/onlinelog/o1_mf_3_lw9or7mw_.log
/u01/app/oracle/oradata/SLASH/onlinelog/o1_mf_1_lw9or606_.log
/u01/app/oracle/oradata/SLASH/onlinelog/o1_mf_2_lw9orck6_.log
/u01/app/oracle/oradata/SLASH/onlinelog/o1_mf_3_lw9or7g1_.log
/u01/app/oracle/oradata/SLASH/onlinelog/redo99.log
-- datafiles:
NAME
--------------------------------------------------------------------------------
/u01/app/oracle/oradata/SLASH/datafile/o1_mf_system_lxvn5vtq_.dbf
/u01/app/oracle/oradata/SLASH/datafile/o1_mf_sysaux_lxvn7om1_.dbf
/u01/app/oracle/oradata/SLASH/datafile/o1_mf_undotbs1_lxvn9h7h_.dbf
/u01/app/oracle/oradata/SLASH/datafile/o1_mf_users_lxvnb6rp_.dbf
/u01/app/oracle/oradata/SLASH/datafile/nonomf.dbf
-- tempfiles:
/u01/app/oracle/oradata/SLASH/datafile/o1_mf_temp_%u_.tmp
-- db_unique_name = SLASH
-- db_create_file_dest = /u01/app/oracle/oradata
-- db_recovery_file_dest = /u01/app/oracle/oradata/fast_recovery_area
-- db_create_online_log_dest_[x] is not set
-- db_file_name_convert = u02,u01
-- log_file_name_convert = u02,u01 |
Note |
---|
After standby database is created, you should set convert parameters on your primary database with reverse values (requires restart): SQL> alter system set db_file_name_convert ='u01','u02' scope=spfile; SQL> alter system set log_file_name_convert = ‘u01','u02' scope=spfile; This is for proper functionality of failover and switchover. If you skip this step, Dbvisit will set these parameters during switchover automatically. |
Info |
---|
non-OMF tempfiles and redologs will be forcefully created as OMF by Dbvisit if you perform graceful switchover or failover. |