Home » RDBMS Server » Backup & Recovery » restore issue (11.2.0.1 windows xp)
restore issue [message #531681] Thu, 17 November 2011 05:11 Go to next message
andy huang
Messages: 498
Registered: July 2011
Senior Member
Dear all,
I was confused my restore command,how does oracle know where the backupsets are store? for example,if the location is 'c:\mybakup' when backup,then i move the backupsets to 'd:\mybackup', how does oracle know the new location?


run
{
  allocate channel c1  type for disk;
  allocate channel c21 type for disk;
  restore database;
  recover database;
  alter database open resetlogs;
  release channel c1;
  release channel c2;
}

Re: restore issue [message #531686 is a reply to message #531681] Thu, 17 November 2011 05:16 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Quote:
I was confused my restore command,how does oracle know where the backupsets are store?


It is recorded in the control file.

Quote:
how does oracle know the new location?


It does not know.

Regards
Michel
Re: restore issue [message #531699 is a reply to message #531686] Thu, 17 November 2011 05:50 Go to previous messageGo to next message
andy huang
Messages: 498
Registered: July 2011
Senior Member
hi,
Michel,Oracle does not the new location,how to restore the database base on new location where the backupset restore?
Re: restore issue [message #531702 is a reply to message #531699] Thu, 17 November 2011 05:56 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

Giving it the new location using CATALOG command.

Regards
Michel
Re: restore issue [message #531712 is a reply to message #531702] Thu, 17 November 2011 07:27 Go to previous messageGo to next message
andy huang
Messages: 498
Registered: July 2011
Senior Member
Thanks Michel!
But i have a new issue,if i cope the backupsets from HostA to HostB,and then i want to restore the database using the backupsets in HostB,how to do?
Re: restore issue [message #531714 is a reply to message #531712] Thu, 17 November 2011 07:43 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
The same way.
Host does not matter for RMAN.

Regards
Michel
Re: restore issue [message #531718 is a reply to message #531714] Thu, 17 November 2011 07:49 Go to previous messageGo to next message
andy huang
Messages: 498
Registered: July 2011
Senior Member
Thanks Michel,
If HostB does not install oracle software,does it can restore?
Re: restore issue [message #531723 is a reply to message #531718] Thu, 17 November 2011 07:58 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
No.
How could restore an Oracle database if you have Oracle software?

Regards
Michel
Re: restore issue [message #531726 is a reply to message #531723] Thu, 17 November 2011 08:10 Go to previous messageGo to next message
andy huang
Messages: 498
Registered: July 2011
Senior Member
Thanks,
Michel,Back to the first issue of my.
if i move the backupset "c:\mybackup\test.bak" to "d:\mybackup\test.bak" as HostA,do i must run the flowing command before restore?
CATALOG BACKUPPIECE 'd:\mybackup\test.bak';
Re: restore issue [message #531729 is a reply to message #531726] Thu, 17 November 2011 08:13 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Yes but the best way to know is to do it.

Regards
Michel
Re: restore issue [message #531736 is a reply to message #531729] Thu, 17 November 2011 08:22 Go to previous messageGo to next message
andy huang
Messages: 498
Registered: July 2011
Senior Member
Thanks,
If i cope the backupset from HostA to HostB,and want to restore it in HostB,is it must do the flowing?
1.install oracle software in HostB
2.using the oradim the add a SID in windows, which command in linux?
3.Does the SID must be the same as HostA?
4.how to restore? and how does oracle to know the backupset which copy from HostA?
Re: restore issue [message #531749 is a reply to message #531736] Thu, 17 November 2011 08:45 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
2. There is no service in Linusx, skip this step.
3. No.
4. You catalog them!

Regards
Michel
Re: restore issue [message #531755 is a reply to message #531749] Thu, 17 November 2011 08:50 Go to previous messageGo to next message
andy huang
Messages: 498
Registered: July 2011
Senior Member
Thanks,
Michel, Can you please explain the item 3,how to change to sid? I think the sid must be the same, because the backupset have record the SID of HostA.

Quote:
3.Does the SID must be the same as HostA?

Re: restore issue [message #531757 is a reply to message #531755] Thu, 17 November 2011 08:57 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
No, the backupset records the database id and its content contains the database name, instance name is irrelevant for RMAN.

Regards
Michel
Re: restore issue [message #531758 is a reply to message #531757] Thu, 17 November 2011 09:01 Go to previous messageGo to next message
andy huang
Messages: 498
Registered: July 2011
Senior Member
Thanks,
Michel,do it the DBID in target host HostB must be same as source host HostA?
Re: restore issue [message #531767 is a reply to message #531758] Thu, 17 November 2011 10:15 Go to previous messageGo to next message
babuknb
Messages: 1736
Registered: December 2005
Location: NJ
Senior Member

Michel already answered your question.

You should use different SID if it's same host.

Use NID to change the db name & Use ORADIM for instance creation.

- Babu
Re: restore issue [message #531787 is a reply to message #531758] Thu, 17 November 2011 11:22 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
andy huang wrote on Thu, 17 November 2011 16:01
Thanks,
Michel,do it the DBID in target host HostB must be same as source host HostA?


It will be the same after restore (no way to do it other way) but, as gentlebabu said, you can use NID to change it afterwards.

Regards
Michel

[Updated on: Thu, 17 November 2011 11:22]

Report message to a moderator

Re: restore issue [message #531819 is a reply to message #531787] Thu, 17 November 2011 18:25 Go to previous message
andy huang
Messages: 498
Registered: July 2011
Senior Member
Thanks,
Michel,I appreciate your help very much.
Previous Topic: Cloning Error: - RMAN-06758
Next Topic: rman and Tivoli backup
Goto Forum:
  


Current Time: Thu Apr 18 23:39:59 CDT 2024