跳转到内容

RAC 攻击 - Oracle 集群数据库实战/闪回数据库

来自 Wikibooks,开放书籍,开放世界


  1. 在打开数据库之前,启用闪回数据库。 SQL> alter database flashback on; Database altered. SQL> alter database open; Database altered. SQL> select flashback_on from v$database; FLASHBACK_ON ------------------ YES SQL> select oldest_flashback_scn,flashback_size from v$flashback_database_log; OLDEST_FLASHBACK_SCN FLASHBACK_SIZE -------------------- -------------- 610425 8192000
  2. 现在,登录到collabn2并从sqlplus启动数据库。 您将收到错误消息。 collabn2:/home/oracle[RAC2]$ ss SQL*Plus: Release 11.1.0.6.0 - Production on Mon May 4 09:21:25 2009 SQL> startup ORACLE instance started. Total System Global Area 318054400 bytes Fixed Size 1299624 bytes Variable Size 142609240 bytes Database Buffers 167772160 bytes Redo Buffers 6373376 bytes Database mounted. ORA-38760: This database instance failed to turn on flashback database SQL> select flashback_on from v$database; FLASHBACK_ON ------------------ YES SQL> select oldest_flashback_scn,flashback_size from v$flashback_database_log; OLDEST_FLASHBACK_SCN FLASHBACK_SIZE -------------------- -------------- 0 16384000
  3. 有趣的是,数据库似乎正常运行。 检查警报日志以获取错误消息。 collabn2:/home/oracle[RAC2]$ cdd collabn2:/u01/app/oracle/diag[RAC2]$ cd rdbms/rac/RAC2/trace/ collabn2:/u01/app/oracle/diag/rdbms/rac/RAC2/trace[RAC2]$ less alert_RAC2.log Mon May 04 09:22:07 2009 Errors in file /u01/app/oracle/diag/rdbms/rac/RAC2/trace/RAC2_ora_22856.trc: ORA-38701: Flashback database log 1 seq 1 thread 1: "/u01/app/oradata/RAC/flashb ack/o1_mf_4zxxs99n_.flb" ORA-27037: unable to obtain file status Linux Error: 2: No such file or directory Additional information: 3
  4. 检查collabn1上的警报日志 - 这里是否出现任何错误消息? 还会出现其他问题吗?
  5. 禁用闪回数据库。 您不需要关闭disable操作。 SQL> alter database flashback off; Database altered.


华夏公益教科书