RMAN restore backup to New Host problems
595034Dec 7 2007 — edited Dec 13 2007Hi Everyone,
Here are my scenarios:
New Host OS: Windows XP Professional
Oracle: 10.2.0.3 Enterprise Edition - 32bit (software)
Production Host OS: Windows Server 2003 Enterprise x64 Edition
Production Oracle: 10g Enterprise Edition Release 10.2.0.3.0 - 64bit
I used Enterprise Manager to backup database, database size is around 260G.
I followed the document to test disaster recovery to a New Host. (not duplication, because it's disaster recovery test)
http://download.oracle.com/docs/cd/B19306_01/backup.102/b14191/rcmrecov002.htm#i1007814
D:\>set oracle_sid=undb
D:\rman_backup>rman target / nocatalog
Recovery Manager: Release 10.2.0.3.0 - Production on Fri Dec 7 11:43:06 2007
Copyright (c) 1982, 2005, Oracle. All rights reserved.
connected to target database (not started)
RMAN> set dbid 1567350085
executing command: SET DBID
RMAN> startup nomount pfile='C:\oracle\product\10.2.0\db_1\database\initUNDB.ora';
Oracle instance started
Total System Global Area 1258291200 bytes
Fixed Size 1292156 bytes
Variable Size 301992068 bytes
Database Buffers 947912704 bytes
Redo Buffers 7094272 bytes
RMAN> set controlfile autobackup format for device type disk to 'd:\rman_backup\%F';
executing command: SET CONTROLFILE AUTOBACKUP FORMAT
RMAN> show all;
RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO REDUNDANCY 1; # default
CONFIGURE BACKUP OPTIMIZATION OFF; # default
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default
CONFIGURE CONTROLFILE AUTOBACKUP OFF; # default
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
RMAN> restore controlfile from 'd:\rman_backup\BACKUP_UNDB_S397_CDJ30GME_1_1';
Starting restore at 07-DEC-07
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=156 devtype=DISK
channel ORA_DISK_1: restoring control file
channel ORA_DISK_1: restore complete, elapsed time: 00:00:07
output filename=D:\ORACLE\UNDB\CONTROL01.CTL
output filename=D:\ORACLE\UNDB\CONTROL02.CTL
output filename=D:\ORACLE\UNDB\CONTROL03.CTL
Finished restore at 07-DEC-07
RMAN> alter database mount;
database mounted
released channel: ORA_DISK_1
RMAN> show all;
RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 7 DAYS;
CONFIGURE BACKUP OPTIMIZATION OFF; # default
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default
CONFIGURE CONTROLFILE AUTOBACKUP OFF;
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '\\it-dev\backup\undb\rman\%F';
CONFIGURE DEVICE TYPE DISK BACKUP TYPE TO COMPRESSED BACKUPSET PARALLELISM 1;
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '\\it-dev\backup\undb\rman\Backup_%d_S%s_%U';
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
CONFIGURE SNAPSHOT CONTROLFILE NAME TO 'C:\ORACLE\PRODUCT\10.2.0\DB_1\DATABASE\SNCFUNDB.ORA'; # default
RMAN> @d:\rman_backup\restore_undb.sql
RMAN> RUN
2> {
3> # allocate a channel to the disk device
4> ALLOCATE CHANNEL c1 DEVICE TYPE disk;
5> #FORMAT 'd:\rman_test';
6>
7> # rename the datafiles and online redo logs
8> SET NEWNAME FOR DATAFILE 1 to 'd:\oracle\undb\SYSTEM01.DBF';
9> SET NEWNAME FOR DATAFILE 2 to 'd:\oracle\undb\UNDOTBS01.DBF';
10> SET NEWNAME FOR DATAFILE 3 to 'd:\oracle\undb\SYSAUX01.DBF';
11> SET NEWNAME FOR DATAFILE 4 to 'd:\oracle\undb\USERS01.DBF';
12> SET NEWNAME FOR DATAFILE 5 to 'd:\oracle\undb\ZE_DATA01.ORA';
13> SET NEWNAME FOR DATAFILE 6 to 'd:\oracle\undb\ZE_DATA02.ORA';
14> SET NEWNAME FOR DATAFILE 7 to 'd:\oracle\undb\ZE_INDEX01.ORA';
15> SET NEWNAME FOR DATAFILE 8 to '\oracle\undb\CAISO01.ORA';
16> SET NEWNAME FOR DATAFILE 9 to '\oracle\undb\CAISO02.ORA';
17> SET NEWNAME FOR DATAFILE 10 to '\oracle\undb\ZE_DATA03.ORA';
18>
19> SET NEWNAME FOR DATAFILE 11 to '\oracle\undb\ZE_INDEX02.ORA';
20> SET NEWNAME FOR DATAFILE 12 to '\oracle\undb\ZE_DATA_XML01.ORA';
21> SET NEWNAME FOR DATAFILE 13 to '\oracle\undb\ZE_METADATA_01.ORA';
22> SET NEWNAME FOR DATAFILE 14 to '\oracle\undb\PERFSTAT.ORA';
23> SET NEWNAME FOR DATAFILE 15 to '\oracle\undb\RMAN01.ORA';
24> SET NEWNAME FOR DATAFILE 16 to '\oracle\undb\ZE_DATA04.ORA';
25> SET NEWNAME FOR DATAFILE 17 to '\oracle\undb\ZE_HELPDESK.ORA';
26> SET NEWNAME FOR DATAFILE 18 to '\oracle\undb\ZE_INDEX03.ORA';
27> SET NEWNAME FOR DATAFILE 19 to '\oracle\undb\CAISO03.ORA';
28> SET NEWNAME FOR DATAFILE 20 to '\oracle\undb\UNDB\ZE_DATA_2000.ORA';
29>
30> SET NEWNAME FOR DATAFILE 21 to '\oracle\undb\UNDB\ZE_DATA_2001.ORA';
31> SET NEWNAME FOR DATAFILE 22 to '\oracle\undb\UNDB\ZE_DATA_2002.ORA';
32> SET NEWNAME FOR DATAFILE 23 to '\oracle\undb\UNDB\ZE_DATA_2003.ORA';
33> SET NEWNAME FOR DATAFILE 24 to '\oracle\undb\UNDB\ZE_DATA_2004.ORA';
34> SET NEWNAME FOR DATAFILE 25 to '\oracle\undb\UNDB\ZE_DATA_2005.ORA';
35> SET NEWNAME FOR DATAFILE 26 to '\oracle\undb\UNDB\ZE_DATA_2006.ORA';
36> SET NEWNAME FOR DATAFILE 27 to '\oracle\undb\UNDB\ZE_DATA_2007.ORA';
37> SET NEWNAME FOR DATAFILE 28 to '\oracle\undb\UNDB\ZE_DATA_2008.ORA';
38> SET NEWNAME FOR DATAFILE 29 to '\oracle\undb\UNDB\ZE_DATA_2009.ORA';
39> SET NEWNAME FOR DATAFILE 30 to '\oracle\undb\UNDB\ZE_DATA_2010.ORA';
40> SET NEWNAME FOR DATAFILE 31 to '\oracle\undb\UNDB\ZE_INDEX_DUI.ORA';
41>
42> # SQL "ALTER DATABASE RENAME FILE ''d:\oradata\richdb\redo01.log '' TO
''d\oracle\richdb\redo04.log'' ";
43> # SQL "ALTER DATABASE RENAME FILE ''d:\oradata\richdb\redo02.log '' TO
''d\oracle\richdb\redo05.log'' ";
44> # SQL "ALTER DATABASE RENAME FILE ''d:\oradata\richdb\redo03.log '' TO
''d\oracle\richdb\redo06.log'' ";
45>
46> # Do a SET UNTIL to prevent recovery of the online logs
47> # set until time ="to_date('DEC-05-2007:15:00:00','MON-DD-YYYY:HH24:MI:SS'";
48> SET UNTIL SCN 9240193413409;
49> # restore the database and switch the datafile names
50> RESTORE DATABASE;
51> # from TAG='RMAN FULL BACK_120507014653';
52>
53> SWITCH DATAFILE ALL;
54>
55> # recover the database
56> RECOVER DATABASE;
57> }
allocated channel: c1
channel c1: sid=156 devtype=DISK
executing command: SET NEWNAME
...
(total 31 executing command: SET NEWNAME,
in order to short the post, omitted some executing command: SET NEWNAME here)
executing command: SET until clause
Starting restore at 07-DEC-07
Starting implicit crosscheck backup at 07-DEC-07
Crosschecked 49 objects
Finished implicit crosscheck backup at 07-DEC-07
Starting implicit crosscheck copy at 07-DEC-07
Finished implicit crosscheck copy at 07-DEC-07
searching for all files in the recovery area
cataloging files...
no files cataloged
released channel: c1
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 12/07/2007 11:51:54
RMAN-06026: some targets not found - aborting restore
RMAN-06023: no backup or copy of datafile 15 found to restore
RMAN-06023: no backup or copy of datafile 14 found to restore
RMAN-06023: no backup or copy of datafile 13 found to restore
RMAN-06023: no backup or copy of datafile 12 found to restore
RMAN-06023: no backup or copy of datafile 11 found to restore
RMAN-06023: no backup or copy of datafile 10 found to restore
RMAN-06023: no backup or copy of datafile 9 found to restore
RMAN-06023: no backup or copy of datafile 8 found to restore
RMAN-06023: no backup or copy of datafile 7 found to restore
RMAN-06023: no backup or copy of datafile 6 found to restore
RMAN-06023: no backup or copy of datafile 5 found to restore
RMAN-06023: no backup or copy of datafile 4 found to restore
RMAN-06023: no backup or copy of datafile 3 found to restore
RMAN-06023: no backup or copy of datafile 2 found to restore
RMAN-06023: no backup or copy of datafile 1 found to restore
RMAN> **end-of-file**
These backupset are available, not sure why RMAN can't find the backup files,
so I copied these backupsets to local PC at 'd:\rman_backup' folder
and changed the channel setting as following:
RMAN> CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT 'd:\rman_backup\Backup_%d_S%s_%U';
old RMAN configuration parameters:
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '\\it-dev\backup\undb\rman\Backup_%d_S%s_%U';
new RMAN configuration parameters:
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT 'd:\rman_backup\Backup_%d_S%s_%U';
new RMAN configuration parameters are successfully stored
RMAN> show all;
RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 7 DAYS;
CONFIGURE BACKUP OPTIMIZATION OFF; # default
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default
CONFIGURE CONTROLFILE AUTOBACKUP OFF;
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '\\it-dev\backup\undb\rman\%F';
CONFIGURE DEVICE TYPE DISK BACKUP TYPE TO COMPRESSED BACKUPSET PARALLELISM 1;
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT 'd:\rman_backup\Backup_%d_S%s_%U';
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
CONFIGURE SNAPSHOT CONTROLFILE NAME TO 'C:\ORACLE\PRODUCT\10.2.0\DB_1\DATABASE\SNCFUNDB.ORA'; # default
re-run the sql script:
RMAN> @d:\rman_backup\restore_undb.sql
RMAN> RUN
2> {
3> # allocate a channel to the disk device
4> ALLOCATE CHANNEL c1 DEVICE TYPE disk;
5> #FORMAT 'd:\rman_test';
6>
7> # rename the datafiles and online redo logs
8> SET NEWNAME FOR DATAFILE 1 to 'd:\oracle\undb\SYSTEM01.DBF';
9> SET NEWNAME FOR DATAFILE 2 to 'd:\oracle\undb\UNDOTBS01.DBF';
10> SET NEWNAME FOR DATAFILE 3 to 'd:\oracle\undb\SYSAUX01.DBF';
11> SET NEWNAME FOR DATAFILE 4 to 'd:\oracle\undb\USERS01.DBF';
12> SET NEWNAME FOR DATAFILE 5 to 'd:\oracle\undb\ZE_DATA01.ORA';
13> SET NEWNAME FOR DATAFILE 6 to 'd:\oracle\undb\ZE_DATA02.ORA';
14> SET NEWNAME FOR DATAFILE 7 to 'd:\oracle\undb\ZE_INDEX01.ORA';
15> SET NEWNAME FOR DATAFILE 8 to '\oracle\undb\CAISO01.ORA';
16> SET NEWNAME FOR DATAFILE 9 to '\oracle\undb\CAISO02.ORA';
17> SET NEWNAME FOR DATAFILE 10 to '\oracle\undb\ZE_DATA03.ORA';
18>
19> SET NEWNAME FOR DATAFILE 11 to '\oracle\undb\ZE_INDEX02.ORA';
20> SET NEWNAME FOR DATAFILE 12 to '\oracle\undb\ZE_DATA_XML01.ORA';
21> SET NEWNAME FOR DATAFILE 13 to '\oracle\undb\ZE_METADATA_01.ORA';
22> SET NEWNAME FOR DATAFILE 14 to '\oracle\undb\PERFSTAT.ORA';
23> SET NEWNAME FOR DATAFILE 15 to '\oracle\undb\RMAN01.ORA';
24> SET NEWNAME FOR DATAFILE 16 to '\oracle\undb\ZE_DATA04.ORA';
25> SET NEWNAME FOR DATAFILE 17 to '\oracle\undb\ZE_HELPDESK.ORA';
26> SET NEWNAME FOR DATAFILE 18 to '\oracle\undb\ZE_INDEX03.ORA';
27> SET NEWNAME FOR DATAFILE 19 to '\oracle\undb\CAISO03.ORA';
28> SET NEWNAME FOR DATAFILE 20 to '\oracle\undb\UNDB\ZE_DATA_2000.ORA';
29>
30> SET NEWNAME FOR DATAFILE 21 to '\oracle\undb\UNDB\ZE_DATA_2001.ORA';
31> SET NEWNAME FOR DATAFILE 22 to '\oracle\undb\UNDB\ZE_DATA_2002.ORA';
32> SET NEWNAME FOR DATAFILE 23 to '\oracle\undb\UNDB\ZE_DATA_2003.ORA';
33> SET NEWNAME FOR DATAFILE 24 to '\oracle\undb\UNDB\ZE_DATA_2004.ORA';
34> SET NEWNAME FOR DATAFILE 25 to '\oracle\undb\UNDB\ZE_DATA_2005.ORA';
35> SET NEWNAME FOR DATAFILE 26 to '\oracle\undb\UNDB\ZE_DATA_2006.ORA';
36> SET NEWNAME FOR DATAFILE 27 to '\oracle\undb\UNDB\ZE_DATA_2007.ORA';
37> SET NEWNAME FOR DATAFILE 28 to '\oracle\undb\UNDB\ZE_DATA_2008.ORA';
38> SET NEWNAME FOR DATAFILE 29 to '\oracle\undb\UNDB\ZE_DATA_2009.ORA';
39> SET NEWNAME FOR DATAFILE 30 to '\oracle\undb\UNDB\ZE_DATA_2010.ORA';
40> SET NEWNAME FOR DATAFILE 31 to '\oracle\undb\UNDB\ZE_INDEX_DUI.ORA';
41>
42> # SQL "ALTER DATABASE RENAME FILE ''d:\oradata\richdb\redo01.log '' TO
''d:\oracle\richdb\redo04.log'' ";
43> # SQL "ALTER DATABASE RENAME FILE ''d:\oradata\richdb\redo02.log '' TO
''d:\oracle\richdb\redo05.log'' ";
44> # SQL "ALTER DATABASE RENAME FILE ''d:\oradata\richdb\redo03.log '' TO
''d:\oracle\richdb\redo06.log'' ";
45>
46> # Do a SET UNTIL to prevent recovery of the online logs
47> # set until time ="to_date('DEC-05-2007:15:00:00','MON-DD-YYYY:HH24:MI:SS')";
48> SET UNTIL SCN 9240193413409;
49> # restore the database and switch the datafile names
50> RESTORE DATABASE;
51> # from TAG='RMAN FULL BACK_120507014653';
52>
53> SWITCH DATAFILE ALL;
54>
55> # recover the database
56> RECOVER DATABASE;
57> }
allocated channel: c1
channel c1: sid=156 devtype=DISK
executing command: SET NEWNAME
...
(total 31 executing command: SET NEWNAME,
in order to short the post, omitted some executing command: SET NEWNAME here)
Starting restore at 07-DEC-07
released channel: c1
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 12/07/2007 11:56:56
RMAN-06026: some targets not found - aborting restore
RMAN-06023: no backup or copy of datafile 15 found to restore
RMAN-06023: no backup or copy of datafile 14 found to restore
RMAN-06023: no backup or copy of datafile 13 found to restore
RMAN-06023: no backup or copy of datafile 12 found to restore
RMAN-06023: no backup or copy of datafile 11 found to restore
RMAN-06023: no backup or copy of datafile 10 found to restore
RMAN-06023: no backup or copy of datafile 9 found to restore
RMAN-06023: no backup or copy of datafile 8 found to restore
RMAN-06023: no backup or copy of datafile 7 found to restore
RMAN-06023: no backup or copy of datafile 6 found to restore
RMAN-06023: no backup or copy of datafile 5 found to restore
RMAN-06023: no backup or copy of datafile 4 found to restore
RMAN-06023: no backup or copy of datafile 3 found to restore
RMAN-06023: no backup or copy of datafile 2 found to restore
RMAN-06023: no backup or copy of datafile 1 found to restore
RMAN> **end-of-file**
No matter what the channel format I changed, got the same error message.
My question is why RMAN can't find these backups, how to change the recovery area?
here is my pfile:
undb.__db_cache_size=1023410176
undb.__java_pool_size=16777216
undb.__large_pool_size=16777216
undb.__shared_pool_size=167772160
undb.__streams_pool_size=16777216
*.audit_file_dest='C:\oracle\product\10.2.0\admin\undb\adump'
*.background_dump_dest='C:\oracle\product\10.2.0\admin\undb\bdump'
*.compatible='10.2.0.3.0'
*.control_files='D:\oracle\undb\control01.ctl','D:\oracle\undb\control02.ctl','D:\oracle\undb\control03.ctl'
*.core_dump_dest='C:\oracle\product\10.2.0\admin\undb\cdump'
*.db_block_size=8192
*.db_domain='zepower.com'
*.db_file_multiblock_read_count=16
*.db_name='undb'
*.db_recovery_file_dest='d:\flash_recovery_area'
*.db_recovery_file_dest_size=85899345920
*.dispatchers='(PROTOCOL=TCP) (SERVICE=undbXDB)'
*.job_queue_processes=10
*.open_cursors=300
*.pga_aggregate_target=417333248
*.processes=150
*.remote_login_passwordfile='EXCLUSIVE'
*.sga_target=1254096896
*.undo_management='AUTO'
*.undo_tablespace='UNDOTBS1'
*.user_dump_dest='C:\oracle\product\10.2.0\admin\undb\udump'
Before the test, I created a small database in another PC, made a full backup into the new host d:\rman_backup,
followed the same procedure and successfully restored the database, but the production backup restore
really made me frustrated. I have researched and tested for couple days.
Please give some comment or suggestion, really appreciate it.