Simulate Oracle Database Server disconnection using implicit parameters, and redo log loss to open the database

Source: Internet
Author: User

The simulated server suddenly loses power, the database is lost, and the transaction cannot be recovered from the rollback failure.
The database status is as follows:
SQL> select instance_name, status from v $ instance;
INSTANCE_NAME STATUS
----------------------------
Marven OPEN
Non-archive mode:
SQL> archive log list
Database log mode No Archive Mode
Automatic archival Disabled
Archive destination/u01/app/Oracle/product/10.2.0/db_1/dbs/arch
Oldest online log sequence 25
Current log sequence 27

SQL & gt; set linesize 150 pagesize 300
SQL> select * from v $ log;

GROUP # THREAD # SEQUENCE # bytes members arc status FIRST_CHANGE # FIRST_TIM
-------------------------------------------------------------------------------------------
1 1 25 52428800 1 no current 384492 29-JAN-12
2 1 23 52428800 1 no inactive 371795 29-JAN-12
3 1 24 52428800 1 no inactive 377698 29-JAN-12
Use shutdown abort to simulate sudden power loss and database shutdown. In this case, the database can be started to MOUNT normally.
SQL> shutdown abort
ORACLE instance shut down.
SQL> startup mount
ORACLE instance started.

Total System Global Area 1610612736 bytes
Fixed Size 2084296 bytes
Variable Size 385876536 bytes
Database Buffers 1207959552 bytes
Redo Buffers 14692352 bytes
Database mounted.
The log status is as follows:
SQL> select * from v $ log;

GROUP # THREAD # SEQUENCE # bytes members arc status FIRST_CHANGE # FIRST_TIM
-------------------------------------------------------------------------------------------
1 1 25 52428800 1 no active 384492 29-JAN-12
3 1 27 52428800 1 no current 391086 29-JAN-12
2 1 26 52428800 1 no active 389733 29-JAN-12
Delete all redo log files:
SQL>! Rm/u01/app/oracle/oradata/marven/redo *. log
SQL> shutdown abort
ORACLE instance shut down.

SQL> startup nomount

Total System Global Area 1610612736 bytes
Fixed Size 2084296 bytes
Variable Size 385876536 bytes
Database Buffers 1207959552 bytes
Redo Buffers 14692352 bytes
SQL> alter database mount;

Database altered.

The database cannot be opened normally when it is opened.
SQL> alter database open;
Alter database open
*
ERROR at line 1:
ORA-00313: open failed for members of log group 1 of thread 1
ORA-00312: online log 1 thread 1: '/u01/app/oracle/oradata/marven/redo01.log'
ORA-27037: unable to obtain file status
Linux-x86_64 Error: 2: No such file or directory
Additional information: 3
An attempt to open the database through resetlog is not feasible:
SQL> alter database open resetlogs;
Alter database open resetlogs
*
ERROR at line 1:
ORA-01139: RESETLOGS option only valid after an incomplete database recovery

The Directory of the spfile parameter file is as follows:
SQL> show parameter spfile;

NAME TYPE VALUE
-----------------------------------------------------------------------------
Spfile string/u01/app/oracle/product/10.2.0
/Db_1/dbs/spfilemarven. ora

  • 1
  • 2
  • 3
  • Next Page

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.