(RMAN)使用恢复目录数据库执行RMAN步骤 推荐
2009-10-14 10:50
483 查看
我想建立一个RMAN备份机制,本机为目标数据库,sid为orcl10的数据库为恢复目录来做备份,但总不成功,以下是我的执行步骤:
SQL> conn sys/e2000jl@orcl10 as sysdba
Connected.
SQL> create user rman
2 identified by rman123;
User created.
SQL> grant dba to rman;
Grant succeeded.
C:\Documents and Settings\zouyang>rman target sys/system catalog rman/rman123@orcl10
Recovery Manager: Release 10.1.0.2.0 - Production
Copyright (c) 1995, 2004, Oracle. All rights reserved.
connected to target database: ORCL (DBID=1227672490)
connected to recovery catalog database
recovery catalog is not installed
RMAN> show channel for device type disk;
recovery catalog is not installed
recovery catalog is not installed
RMAN-00571: ===============================================
RMAN-00569: =========ERROR MESSAGE STACK FOLLOWS ========
RMAN-00571: ===============================================
RMAN-03002: failure of show command at 10/14/2009 09:30:02
RMAN-06429: RCVCAT database is not compatible with this version of RMAN
RMAN>
可以连接上恢复目录数据库,但是无法使用这个恢复目录,Oracle报错“recovery catalog is not installed”。
在网上搜了下,重新建立步骤如下:
第一步:Create Recovery Catalog
First create a user to hold the recovery catalog:
-- Create tablepsace to hold repository
SQL> create tablespace rman_tools
2 datafile
3 'D:\ORACLE\PRODUCT\10.1.0\ORADATA\ORCL10\rman01.dbf'
4 size 100m;
Tablespace created
-- Create rman schema owner
SQL> create user rman
2 identified by rman123
3 default tablespace rman_tools
4 quota unlimited on rman_tools;
User created
C:\Documents and Settings\zouyang>rman catalog rman/rman123@orcl10
Recovery Manager: Release 10.1.0.2.0 - Production
Copyright (c) 1995, 2004, Oracle. All rights reserved.
RMAN-00571: ===============================================
RMAN-00569: ====== ERROR MESSAGE STACK FOLLOWS ==========
RMAN-00571: ===============================================
RMAN-00554: initialization of internal recovery manager package failed
RMAN-04004: error from recovery catalog database: ORA-01045: user RMAN lacks CREATE SESSION privilege; logon denied
-- 报错!要给rman用户分配一定的权限!
SQL> grant connect,resource,create session,recovery_catalog_owner
2 to rman;
Grant succeeded
C:\Documents and Settings\zouyang>rman catalog rman/rman123@orcl10
Recovery Manager: Release 10.1.0.2.0 - Production
Copyright (c) 1995, 2004, Oracle. All rights reserved.
connected to recovery catalog database
recovery catalog is not installed
RMAN> create catalog tablespace rman_tools;
recovery catalog created ——很好!!建立了!!
可是,当我重新连接,显示RMAN设置信息时又报错了!!
C:\Documents and Settings\zouyang>rman target sys/system catalog rman/rman123@orcl10
Recovery Manager: Release 10.1.0.2.0 - Production
Copyright (c) 1995, 2004, Oracle. All rights reserved.
connected to target database: ORCL (DBID=1227672490)
connected to recovery catalog database
RMAN> show channel for device type disk;
RMAN configuration parameters are:
RMAN-00571: ===============================================
RMAN-00569: ========= ERROR MESSAGE STACK FOLLOWS =======
RMAN-00571: ===============================================
RMAN-03002: failure of show command at 10/14/2009 10:32:36
RMAN-06004: ORACLE error from recovery catalog database: RMAN-20001: target database not found in recovery catalog
RMAN>
又在网上查找原因,原来还需要注册数据库!!
第二步:Register Database
Each database to be backed up by RMAN must be registered!
RMAN> register database;
database registered in recovery catalog
starting full resync of recovery catalog
full resync complete
RMAN> show channel for device type disk;
RMAN configuration parameters are:CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT 'D:\BACKUP\RMAN\%d_%s.bak';
RMAN>
成功啦!!!
SQL> conn sys/e2000jl@orcl10 as sysdba
Connected.
SQL> create user rman
2 identified by rman123;
User created.
SQL> grant dba to rman;
Grant succeeded.
C:\Documents and Settings\zouyang>rman target sys/system catalog rman/rman123@orcl10
Recovery Manager: Release 10.1.0.2.0 - Production
Copyright (c) 1995, 2004, Oracle. All rights reserved.
connected to target database: ORCL (DBID=1227672490)
connected to recovery catalog database
recovery catalog is not installed
RMAN> show channel for device type disk;
recovery catalog is not installed
recovery catalog is not installed
RMAN-00571: ===============================================
RMAN-00569: =========ERROR MESSAGE STACK FOLLOWS ========
RMAN-00571: ===============================================
RMAN-03002: failure of show command at 10/14/2009 09:30:02
RMAN-06429: RCVCAT database is not compatible with this version of RMAN
RMAN>
可以连接上恢复目录数据库,但是无法使用这个恢复目录,Oracle报错“recovery catalog is not installed”。
在网上搜了下,重新建立步骤如下:
第一步:Create Recovery Catalog
First create a user to hold the recovery catalog:
-- Create tablepsace to hold repository
SQL> create tablespace rman_tools
2 datafile
3 'D:\ORACLE\PRODUCT\10.1.0\ORADATA\ORCL10\rman01.dbf'
4 size 100m;
Tablespace created
-- Create rman schema owner
SQL> create user rman
2 identified by rman123
3 default tablespace rman_tools
4 quota unlimited on rman_tools;
User created
C:\Documents and Settings\zouyang>rman catalog rman/rman123@orcl10
Recovery Manager: Release 10.1.0.2.0 - Production
Copyright (c) 1995, 2004, Oracle. All rights reserved.
RMAN-00571: ===============================================
RMAN-00569: ====== ERROR MESSAGE STACK FOLLOWS ==========
RMAN-00571: ===============================================
RMAN-00554: initialization of internal recovery manager package failed
RMAN-04004: error from recovery catalog database: ORA-01045: user RMAN lacks CREATE SESSION privilege; logon denied
-- 报错!要给rman用户分配一定的权限!
SQL> grant connect,resource,create session,recovery_catalog_owner
2 to rman;
Grant succeeded
C:\Documents and Settings\zouyang>rman catalog rman/rman123@orcl10
Recovery Manager: Release 10.1.0.2.0 - Production
Copyright (c) 1995, 2004, Oracle. All rights reserved.
connected to recovery catalog database
recovery catalog is not installed
RMAN> create catalog tablespace rman_tools;
recovery catalog created ——很好!!建立了!!
可是,当我重新连接,显示RMAN设置信息时又报错了!!
C:\Documents and Settings\zouyang>rman target sys/system catalog rman/rman123@orcl10
Recovery Manager: Release 10.1.0.2.0 - Production
Copyright (c) 1995, 2004, Oracle. All rights reserved.
connected to target database: ORCL (DBID=1227672490)
connected to recovery catalog database
RMAN> show channel for device type disk;
RMAN configuration parameters are:
RMAN-00571: ===============================================
RMAN-00569: ========= ERROR MESSAGE STACK FOLLOWS =======
RMAN-00571: ===============================================
RMAN-03002: failure of show command at 10/14/2009 10:32:36
RMAN-06004: ORACLE error from recovery catalog database: RMAN-20001: target database not found in recovery catalog
RMAN>
又在网上查找原因,原来还需要注册数据库!!
第二步:Register Database
Each database to be backed up by RMAN must be registered!
RMAN> register database;
database registered in recovery catalog
starting full resync of recovery catalog
full resync complete
RMAN> show channel for device type disk;
RMAN configuration parameters are:CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT 'D:\BACKUP\RMAN\%d_%s.bak';
RMAN>
成功啦!!!
相关文章推荐
- (RMAN)使用恢复目录数据库执行RMAN步骤
- (RMAN)使用恢复目录数据库执行RMAN
- 某客户使用RMAN数据库恢复测试步骤
- RMAN复制数据库(使用恢复目录库)
- Rman使用前的准备工作,创建恢复目录所需要使用的表空间,在目录数据库创建rman用户,在目录数据库建立恢复目录
- Exchange2013使用拨号音恢复恢复数据库 推荐
- 使用RMAN恢复用户DML误操作的步骤
- rman异常案例二: 归档日志被人移动到其他目录,导致数据库恢复异常(续)
- 使用恢复目录(catalog)数据库
- RMAN简明教程之七——恢复目录与恢复目录的使用
- RMAN-使用catalog恢复目录进行备份与恢复
- 使用RMAN恢复数据库
- OCP读书笔记(7) - 使用RMAN执行恢复
- Oracle RMAN异机恢复归档RMAN-07518(供日志挖掘使用)及修改dbid步骤
- 使用Rman将Windows Oracle 11gR2 32位中数据库恢复至Windows Oracle 11gR2 64位 与 centos 6.5 Oracle 11gR2 32位
- 使用Rman将Windows Oracle 11gR2 32位中数据库恢复至Windows Oracle 11gR2 64位 与 centos 6.5 Oracle 11gR2 32位
- 连接目标数据库+无恢复目录连接目标数据库+使用有恢复目录连接目标数据库+注册数据库+目录同步+取消目标数据库的连接
- 使用xtrabackup对mariadb数据库进行增量备份以及恢复 推荐
- RMAN实战5:RMAN中恢复目录的使用和清理
- Oracle学习(11)---使用rman备份进行数据库的恢复