探索Oracle之RMAN_07 磁盘损坏数据丢失恢复

php中文网
发布: 2016-06-07 17:15:57
原创
1409人浏览过

探索oracle之rman_07 磁盘损坏数据丢失恢复,有的时候在企业里面难免会出现由于磁盘损坏而导致数据库的故障乃至数据的丢失,那么

探索oracle之rman_07 磁盘损坏数据丢失恢复

[日期:2012-07-07] 来源:Linux社区  作者:吴伟龙 [字体:]

有的时候在企业里面难免会出现由于磁盘损坏而导致数据库的故障乃至数据的丢失,那么这个时候,那么这个时候数据的备份就显得尤为的重要。在这一节我们重点讨论下由于装载数据文件,redo日志文件,,controlfile控制文件的磁盘损坏的数据恢复。 

6.1 通过强制卸载磁盘模拟数据磁盘损坏:

[root@wwldb ~]# umount -f /DBData/

umount2: 资源或设备忙

umount: /DBData: device is busy

umount2: 资源或设备忙

umount: /DBData: device is busy

 

[root@wwldb ~]# fuser -m -k /DBData/     查看设备占用情况

/DBData/: 3508 3510  3512  3514 3516  3518  3529 3531  3535  3541 3610c

 

[root@wwldb ~]# fuser -m -k -i -k /DBData/   强制kill  /DBData相关进程

[root@wwldb ~]# umount -f /DBData/       卸载/DBData

[root@wwldb ~]#

 

看到实例也随之宕机了。

Fri Jul  616:03:33 2012

Errors in file/DBSoft/admin/WWL/bdump/wwl_pmon_3502.trc:

ORA-00471: DBWR process terminated with error

Fri Jul  616:03:33 2012

PMON: terminating instance due to error 471

Instance terminated by PMON, pid = 3502

 

[root@wwldb bdump]# ps -ef|grep ora

root     2965  2943  0 14:39 ?        00:00:00 hald-addon-storage: polling/dev/hdc

root     3944  3050  0 16:07 pts/2    00:00:00 su - Oracle

oracle   3945  3944  0 16:07 pts/2    00:00:00 -bash

oracle   3977  3945  0 16:07 pts/2    00:00:00 rlwrap sqlplus / as sysdba

oracle   3978  3977  0 16:07 pts/3    00:00:00 sqlplus   as sysdba

oracle   3979  3978  0 16:07 ?        00:00:00 oracleWWL(DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))

root     4022  3980  0 16:10 pts/4    00:00:00 grep ora

[root@wwldb bdump]#

 

状态才能恢复

SQL> startup

ORACLE instance started.

 

Total System Global Area  100663296 bytes

Fixed Size                  1217884 bytes

Variable Size              88083108 bytes

Database Buffers            8388608 bytes

纳米搜索
纳米搜索

纳米搜索:360推出的新一代AI搜索引擎

纳米搜索 30
查看详情 纳米搜索

Redo Buffers               2973696 bytes

ORA-00205: error in identifying control file, checkalert log for more info

 

Fri Jul  616:13:24 2012

ORA-00202: control file:'/DBData/oradata/WWL/control02.ctl'

ORA-27037: unable to obtain file status

Linux Error: 2: No such file or directory

Additional information: 3

Fri Jul  616:13:24 2012

ORA-205 signalled during: ALTER DATABASE   MOUNT...

 

 

SQL> show parameter control

 

NAME                                 TYPE        VALUE

----------------------------------------------- ------------------------------

control_file_record_keep_time        integer     7

control_files                        string      /DBSoft/oradata/WWL/control01.ctl, /DBData/oradata/WWL/control02.ctl, /DBData/oradata/WWL/control03.ctl

 

 

 

SQL> alter system set control_files ='/DBSoft/oradata/WWL/control01.ctl' scope=spfile;

System altered.

 

SQL> shutdown immediate

ORA-01507: database not mounted

ORACLE instance shut down.

 

SQL> startup mount;

ORACLE instance started.

 

Total System Global Area  100663296 bytes

Fixed Size                  1217884 bytes

Variable Size              88083108 bytes

Database Buffers            8388608 bytes

Redo Buffers                2973696 bytes

Database mounted.

SQL>

linux

最佳 Windows 性能的顶级免费优化软件
最佳 Windows 性能的顶级免费优化软件

每个人都需要一台速度更快、更稳定的 PC。随着时间的推移,垃圾文件、旧注册表数据和不必要的后台进程会占用资源并降低性能。幸运的是,许多工具可以让 Windows 保持平稳运行。

下载
来源:php中文网
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系admin@php.cn
最新问题
热门教程
更多>
最新下载
更多>
网站特效
网站源码
网站素材
前端模板
关于我们 免责申明 意见反馈 讲师合作 广告合作 最新更新 English
php中文网:公益在线php培训,帮助PHP学习者快速成长!
关注服务号 技术交流群
PHP中文网订阅号
每天精选资源文章推送
PHP中文网APP
随时随地碎片化学习

Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号