Oracle database 16章 数据库恢复 整个数据库的完全恢复 恢复整个数据库 理论试验
2013-04-07 20:15
405 查看
1、使用RMAN恢复整个数据库
先 shutdown database,然后连接上RMAN,把数据库startup 到 mount状态,使用 database restore命令直接恢复整个数据库,要在恢复文件的目录下有备份文件。
2、recover database
3、最后打开数据库
先 shutdown database,然后连接上RMAN,把数据库startup 到 mount状态,使用 database restore命令直接恢复整个数据库,要在恢复文件的目录下有备份文件。
~/app/oracle/flash_recovery_area> sqlplus / as sysdba SQL*Plus: Release 11.2.0.1.0 Production on Sun Apr 7 20:21:31 2013 Copyright (c) 1982, 2009, Oracle. All rights reserved. Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options SQL> shutdown immediate; Database closed. Database dismounted. ORACLE instance shut down. SQL> exit Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options oracle@linux-tpch:~/app/oracle/flash_recovery_area> rman target / Recovery Manager: Release 11.2.0.1.0 - Production on Sun Apr 7 20:22:21 2013 Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved. connected to target database (not started) RMAN> startup mount; Oracle instance started database mounted Total System Global Area 107963772928 bytes Fixed Size 2218032 bytes Variable Size 58518931408 bytes Database Buffers 49392123904 bytes Redo Buffers 50499584 bytes RMAN> restore database; Starting restore at 07-APR-13 using target database control file instead of recovery catalog allocated channel: ORA_DISK_1 channel ORA_DISK_1: SID=2186 device type=DISK channel ORA_DISK_1: starting datafile backup set restore channel ORA_DISK_1: specifying datafile(s) to restore from backup set channel ORA_DISK_1: restoring datafile 00001 to /home/oracle/app/oracle/oradata/test/system01.dbf channel ORA_DISK_1: restoring datafile 00002 to /home/oracle/app/oracle/oradata/test/sysaux01.dbf channel ORA_DISK_1: restoring datafile 00003 to /home/oracle/app/oracle/oradata/test/undotbs01.dbf channel ORA_DISK_1: restoring datafile 00004 to /home/oracle/app/oracle/oradata/test/users01.dbf channel ORA_DISK_1: restoring datafile 00005 to /home/oracle/app/oracle/oradata/test/example01.dbf channel ORA_DISK_1: reading from backup piece /home/oracle/app/oracle/flash_recovery_area/TEST/backupset/2013_04_05/o1_mf_nnndf_TAG20130405T194349_8oxg84o4_.bkp channel ORA_DISK_1: piece handle=/home/oracle/app/oracle/flash_recovery_area/TEST/backupset/2013_04_05/o1_mf_nnndf_TAG20130405T194349_8oxg84o4_.bkp tag=TAG20130405T194349 channel ORA_DISK_1: restored backup piece 1 channel ORA_DISK_1: restore complete, elapsed time: 00:00:15 Finished restore at 07-APR-13 RMAN>
2、recover database
RMAN> restore database; Starting restore at 07-APR-13 using target database control file instead of recovery catalog allocated channel: ORA_DISK_1 channel ORA_DISK_1: SID=2186 device type=DISK channel ORA_DISK_1: starting datafile backup set restore channel ORA_DISK_1: specifying datafile(s) to restore from backup set channel ORA_DISK_1: restoring datafile 00001 to /home/oracle/app/oracle/oradata/test/system01.dbf channel ORA_DISK_1: restoring datafile 00002 to /home/oracle/app/oracle/oradata/test/sysaux01.dbf channel ORA_DISK_1: restoring datafile 00003 to /home/oracle/app/oracle/oradata/test/undotbs01.dbf
3、最后打开数据库
media recovery complete, elapsed time: 00:01:16 Finished recover at 07-APR-13 RMAN> alter database open ; database opened RMAN>
相关文章推荐
- Oracle database 15章 恢复管理器 连接到RMAN 理论试验
- Oracle database 15章 恢复管理器 闪回恢复区 理论试验
- Oracle database 15章 恢复管理器 RMAN脚本 理论试验
- MSSQLSERVER数据库部份恢复的完全修复试验
- 不完全恢复试验(11.2g 64位win2003数据库恢复到32位linux服务器)
- Exchange 2013 拨号音数据库恢复数据理论阐述
- 第6天-3 RMAN不完全恢复】【用scn恢复到特定的时刻】【控制文件损坏】【损坏日志文件状态非INACTIVE时,数据库打不开】【增加联机日志文件】【修改所有联机日志大小同义10M】
- Oracle归档模式下恢复-数据库完全恢复方法1
- 使用oracle自带的DATABASE ADMINISTRATION 恢复整个数据库
- RMAN备份与恢复(1)——对数据库进行完全介质恢复!
- Rman全备份不完全恢复数据库(linux下)
- Oracle database 使用SQL转换数据 使用 merge语句 理论试验
- 数据库完全恢复与差异恢复问题
- [RMAN]使用RMAN备份将数据库不完全恢复到指定时间点
- 4.手工备份恢复--关闭数据库的完全和不完全恢复(练习3、4)
- Oracle归档模式下恢复-数据库完全恢复方法2
- Rman全备份不完全恢复数据库(linux下)
- postgresql 备份 和 恢复 整个数据库
- Oracle归档模式下恢复-数据库完全恢复方法2
- Rman全备份不完全恢复数据库(linux下)