Restoring COLD backup in the same location
Restoring COLD backup in the same location.
-
Scenario with Networker Media Manager.
Step 1 : Move SPFile for scenario purpose:
[oracle@oratst0001 dbs]$ mv spfilevirtualdb.ora spfilevirtualdb.ora2 [oracle@oratst0001 dbs]$ |
Step 2 : Start Database in nomount:
[oracle@oratst0001 networker]$ rman target /
Recovery Manager: Release 11.2.0.4.0 – Production on Fri Nov 9 07:54:23 2018 connected to target database (not started) RMAN> startup failed: ORA-01078: failure in processing system parameters starting Oracle instance without parameter file for retrieval of spfile Total System Global Area 1068937216 bytes Fixed Size 2260088 bytes |
Step 3: Restore SPFile:
RMAN> run 2> { 3> set DBID 1136962510; 4> allocate channel c1 type ‘SBT_TAPE’; 5> send ‘NSR_ENV=(NSR_SERVER=nsrserver.ajara.tech,NSR_CLIENT=nsrclient.ajara.tech,NSR_RECOVER_POOL=nsrrecoverpool.ajara.tech)’; 6> restore spfile from ‘4fthp2pr_1_1’; 7> release channel c1; 8> }executing command: SET DBID using target database control file instead of recovery catalog sent command to channel: c1 Starting restore at 09-NOV-18 channel c1: restoring spfile from AUTOBACKUP 4fthp2pr_1_1 released channel: c1 RMAN> |
Step 4: verify Restored SPFile:
[oracle@oratst0001 dbs]$ ls -ltr spfile* -rw——- 1 oracle dba 3584 Nov 9 03:05 spfilevirtualdb.ora1 -rw——- 1 oracle dba 3584 Nov 9 07:32 spfilevirtualdb.ora2 -rw——- 1 oracle dba 3584 Nov 9 07:58 spfilevirtualdb.ora [oracle@oratst0001 dbs]$ |
step 5: Shutdown Immediate:
[oracle@oratst0001 dbs]$ sqlplus “/as sysdba”
Connected to: SQL> shut immediate ORACLE instance shut down. |
Step 6: start DB in nomount:
[oracle@oratst0001 networker]$ sqlplus “/as sysdba”
Connected to an idle instance. SQL> startup nomount Total System Global Area 1068937216 bytes |
Step 7: Restore Controlfile:
RMAN> run 2> { 3> set DBID 1136962510; 4> allocate channel c1 type ‘SBT_TAPE’; 5> send ‘NSR_ENV=(NSR_SERVER=nsrserver.ajara.tech,NSR_CLIENT=nsrclient.ajara.tech,NSR_RECOVER_POOL=nsrrecoverpool.ajara.tech)’; 6> restore controlfile from ‘4gthp2ps_1_1’; 7> release channel c1; 8> }executing command: SET DBID using target database control file instead of recovery catalog sent command to channel: c1 Starting restore at 09-NOV-18 channel c1: restoring control file released channel: c1 RMAN> |
Step 8: Alter database mount:
SQL> alter database mount;
Database altered. SQL> |
Step 9: Restore database:
RMAN> run 2> { 3> allocate channel c1 type ‘SBT_TAPE’; 4> send ‘NSR_ENV=(NSR_SERVER=nsrserver.ajara.tech,NSR_CLIENT=nsrclient.ajara.tech,NSR_RECOVER_POOL=nsrrecoverpool.ajara.tech)’; 5> restore database from tag ‘VIRTUALDB_COLD_NOV9’; 6> release channel c1; 7> }allocated channel: c1 channel c1: SID=20 device type=SBT_TAPE channel c1: NMDA Oracle v9.1.1.8 sent command to channel: c1 Starting restore at 09-NOV-18 Starting implicit crosscheck copy at 09-NOV-18 searching for all files in the recovery area skipping datafile 1; already restored to file /u01/app/oracle/oradata/virtualdb/system01.dbf released channel: c1 RMAN> |
Step 10: Verify DB reset Logs:
SQL> select open_resetlogs from v$database;
OPEN_RESETL |
Step 11: Open Database with reset logs:
SQL> alter database open resetlogs;
Database altered. |
Step 12: Verify Database files:
SQL> select name from v$database;
NAME SQL> select name from v$datafile; NAME SQL> select name,open_mode,log_mode from v$database; NAME OPEN_MODE LOG_MODE |
See Also:
- Recover oracle DB after loss of datafiles scenarios
- Restore Oracle database from Cold backup
- Restore and recovering the Oracle database
- Flashback RAC database to restore point
- Recovery of Read-Only Files with a Re-Created Control File
- Recover From a DROP/TRUNCATE/DELETE TABLE with RMAN
- http://oracle.com