模拟“ORA-30012"故障测试

1、模拟故障:

[oracle@dg1 dbs]$ cp -r initdg1.ora /oracle/initdg1.ora
[oracle@dg1 dbs]$ mv spfiledg1.ora spfiledg1.orabak
[oracle@dg1 dbs]$ vi initdg1.ora
修改“*.undo_tablespace='UNDOTBS1'” 为“*.undo_tablespace='UNDOTBS2'

2、启动数据库:

SQL> startup
ORACLE instance started.

Total System Global Area  511705088 bytes
Fixed Size                  1220288 bytes
Variable Size             163578176 bytes
Database Buffers          343932928 bytes
Redo Buffers                2973696 bytes
Database mounted.
ORA-01092: ORACLE instance terminated. Disconnection forced

3、查看ALERT日志:

Errors in file /oracle/admin/dg1/udump/dg1_ora_3488.trc:
ORA-30012: undo tablespace 'UNDOTBS2' does not exist or of wrong type
Mon Sep 15 21:26:13 2008
Error 30012 happened during db open, shutting down database
USER: terminating instance due to error 30012
Instance terminated by USER, pid = 3488
ORA-1092 signalled during: ALTER DATABASE OPEN...

4、解决办法:
[oracle@dg1 bdump]$  oerr ORA 30012
30012, 00000, "undo tablespace '%s' does not exist or of wrong type"
// *Cause:   the specified undo tablespace does not exist or of the
//           wrong type.
// *Action:  Correct the tablespace name and reissue the statement.

5、分析原因:

SQL> select ts#,name from v$datafile;

         0
/oracle/oradata/dg1/system01.dbf

         1
/oracle/oradata/dg1/undotbs01.dbf


察看目前参数文件的状态:


SQL> show parameter undo;

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
undo_management                      string      AUTO
undo_retention                       integer     900

undo_tablespace                      string      UNDOTBS2


6、解决办法:

将PFILE文件中的表空间修改成UNDOTBS1,就解决问题。

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/8334342/viewspace-448504/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/8334342/viewspace-448504/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值