1

I'm creating a data guard using hot backup from the primary server. In my restore I've used the following commands to restore:

run{
set newname for database to '+DADOS';
restore database;
switch datafile all;
switch tempfile all;
recover database;
}

After successful restore and recovery my redo logfile names has the name below:

select member from v$logfile;

+DADOS/MUST_RENAME_THIS_LOGFILE_1.4294967295.4294967295
+FRA/MOOTDB/ONLINELOG/group_1.287.1040583755
+DADOS/MUST_RENAME_THIS_LOGFILE_2.4294967295.4294967295
+DADOS/MUST_RENAME_THIS_LOGFILE_3.4294967295.4294967295
+FRA/MOOTDB/ONLINELOG/group_3.259.1036639239
+DADOS/MUST_RENAME_THIS_LOGFILE_4.4294967295.4294967295
+FRA/MOOTDB/ONLINELOG/group_2.288.1040583761
+DADOS/MUST_RENAME_THIS_LOGFILE_5.4294967295.4294967295
+FRA/MOOTDB/ONLINELOG/group_5.295.1042634101
+DADOS/MUST_RENAME_THIS_LOGFILE_6.4294967295.4294967295
+FRA/MOOTDB/ONLINELOG/group_6.297.1042634113

Why they have the "MUST_RENAME_THIS_LOGFILE_"? isn't automatic?

In my standby I'm using the db_log_file_name_convert and log_file_name_convert

log_file_name_convert = +DATA, +DADOS
db_file_name_convert = +DATA, +DADOS

Other issue is that some tempfiles come just with the DG name (see last line below).

select name from v$datafile union all select name from v$tempfile;

+DADOS/MOOTSTB/DATAFILE/system.266.1042731967
+DADOS/MOOTSTB/DATAFILE/sysaux.292.1042731967
+DADOS/MOOTSTB/A249914E10CA3494E0532900A8C0EAA4/DATAFILE/system.278.1042732081
+DADOS/MOOTSTB/A249914E10CA3494E0532900A8C0EAA4/DATAFILE/sysaux.296.1042732081
+DADOS/MOOTSTB/DATAFILE/users.309.1042731967
+DADOS/MOOTSTB/A249914E10CA3494E0532900A8C0EAA4/DATAFILE/undotbs1.320.1042732081
+DADOS/MOOTSTB/DATAFILE/undotbs2.283.1042731967
+DADOS/MOOTSTB/A249E748BB047773E0532900A8C02088/DATAFILE/system.257.1042731811
+DADOS/MOOTSTB/A249E748BB047773E0532900A8C02088/DATAFILE/sysaux.284.1042731809
+DADOS/MOOTSTB/A249E748BB047773E0532900A8C02088/DATAFILE/undotbs1.289.1042731811
+DADOS/MOOTSTB/A249E748BB047773E0532900A8C02088/DATAFILE/users.267.1042731811
+DADOS/MOOTSTB/A249E748BB047773E0532900A8C02088/DATAFILE/soe.311.1042731809
+DADOS/MOOTSTB/A249E748BB047773E0532900A8C02088/DATAFILE/teste.308.1042731811
+DADOS/MOOTSTB/A249E748BB047773E0532900A8C02088/DATAFILE/undo_2.304.1042731811
+DADOS/MOOTSTB/DATAFILE/undotbs1.302.1042731967
+DADOS/MOOTSTB/TEMPFILE/temp.319.1042736311
+DADOS/MOOTSTB/A249914E10CA3494E0532900A8C0EAA4/TEMPFILE/temp.318.1042736323
+DADOS  <<<<<< is a tempfile

1 Answer 1

2

Restore + recovery from backup does not use online redo logs. Your redo logs were just named something, but those files do not exist yet. A physical standby database also does not use online redo logs (it uses standby redo logs).

The redo log groups will be automatically cleared (rename according to OMF + create the file) whenever they are needed the first time. Like when you actually open the database in READ WRITE mode after converting the physical standby into a primary database or snapshot standby or logical standby.

+FRA/MOOTDB/ONLINELOG/group_1.287.1040583755 is also incorrect. At this point that file does not exist and the location of that file, once cleared, will be +FRA/MOOTSTB/ONLINELOG/... as the db_unique_name on the standby site is MOOTSTB. (Assuming you have an FRA diskgroup there.)

With the db_create_file_dest, db_create_online_log_dest_N, db_recovery_file_dest parameters set properly, you can simply clear the logfile groups manually (what would be done automatically anyway when required), so they will be named and placed correctly:

alter database clear logfile group 1;
alter database clear logfile group 2;
alter database clear logfile group 3;
alter database clear logfile group 4;
alter database clear logfile group 5;
alter database clear logfile group 6;

The tempfile named +DADOS is also not a problem. A physical standby in mount stage does not require a tempfile. The tempfile will be automatically renamed and created once the database is opened.

1
  • Thank you!! I've configured the db_create_online_log_dest_N as said and after issue the command "alter database clear logfile group" worked perfectly
    – Astora
    Commented Jun 11, 2020 at 21:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.