嘉善博客
个人首页管理博客
Oracle RMAN物理备份技术详解
【IT168 技术文档】ORACLE备份分为物理备份和逻辑备份两种。物理备份就是转储ORACLE物理文件(如数据文件、控制文件、归档日志文件等),一旦数据库发生故障,可以利用这些文件进行还原;逻辑备份就是对数据库对象(如用户、表、存储过程等)利用EXPORT等工具进行导出工作,可以利用IMPORT等工具把逻辑备份文件导入到数据库。RMAN备份是一种物理备份,可以用RMAN来备份数据文件、控制文件、参数文件、归档日志文件。在数据库出现问题的时候可以通过RMAN物理备份恢复到数据库的失效点。

    开始和退出RMAN

进入RMAN恢复管理器有两种方式:

1、 直接在系统命令提示符敲入rman命令,进入rman控制台后执行connect。

D:\>rman
恢复管理器: Release 10.2.0.2.0 - Production on 星期四 1月 4 10:08:52
Copyright (c) 1982, 2005, Oracle. All rights reserved.
RMAN> connect target /
连接到目标数据库: ROME (DBID=252956976)
RMAN>

2、在系统命令提示符下敲入target和catalog(没有此项默认非catalog方式,控制文件记录rman操作的详细信息)的用户和密码。

# example of operating system authentication
D:\>rman TARGET /
# example of Oracle Net authentication
D:\>rman TARGET SYS/oracle@orcl NOCATALOG

D:\>rman TARGET / CATALOG rman/rman@catdb
D:\>rman TARGET SYS/oracle@orcl CATALOG rman/rman@catdb
RMAN> exit
恢复管理器完成。

注:我们将在以后章节讲述带有恢复目录的RMAN操作。

我们可以看一下rman可以连接的数据库的类型如下:
Target database RMAN connects you to the target database, which is the database that you are backing up or recovering, with the SYSDBA privilege. If you do not have this privilege, then the connection fails.
Recovery catalog database This database is optional. By default, RMAN runs in NOCATALOG mode.
Auxiliary database You can connect to a standby database, duplicate database, or auxiliary instance (standby instance or tablespace point-in-time recovery instance).

Note:
You do not need to specify the SYSDBA option because RMAN uses this option implicitly and automatically.



标签:{blog_tag}