How to recover an Oracle database with only good data files

Source: Internet
Author: User
Tags character set oracle database
1. Re-create initialization files, important parameters include

Control_files,db_name,instance_name,
Background_dump_dest,core_dump_dest,user_dump_dest,\
Db_block_size=8192,db_cache_size,db_domain,
Large_pool_size,pga_aggregate_target,shared_pool_size,
Sort_area_size,undo_management,undo_retention,undo_tablespace

You can create an initial parameter file for modification in the following ways:

@ From the backup parameter file.

@ from other normal-running Oracle instances, run the following command:

Create pfile= ' parameter file path and name ' from SPFile

To modify this file, note that this file is important for recovery and be sure to check that it is correct.

To check for the existence of a directory with parameter settings such as Background_dump_dest,core_dump_dest,user_dump_dest

2. Modify the Listener configuration file. Check the database parameters that are listening.

3. Set the environment variable ORACLE_SID at the system level.

4. Create an instance:

Oradim-new-sid Sid-startmode m

5. Create Oracle Password file:

Orapwd File=oracle_home/database/pwdsid.ora password=*****

The password file location must be correct, otherwise the seventh step will be an error.

6. Startup instance:

@sqlplus "/As SYSDBA" If your parameter file is in the default location and the name meets the standard requirements, run @startup nomount; otherwise @startup nomount ' parameter file path and name '.

7. Create control File:

CREATE controlfile SET DATABASE
"Db_name" Resetlogs Noarchivelog
Maxlogfiles 50
Maxlogmembers 5
Maxdatafiles 100
Maxinstances 1
Maxloghistory 453
LOGFILE
GROUP 1 ' log file path and name ' SIZE 100M,
GROUP 2 ' log file path and name ' SIZE 100M,
GROUP 3 ' log file path and name ' SIZE 100M
DataFile
' Data file path and name ',
....................
...................
CHARACTER SET ZHS16GBK;

8. Open the database:

Alter Database Open resetlogs;

9. Additional temporary documents for temporary table spaces:

Because the creation of the temporary file is not included in the script that creates the control file, you need to add temporary files manually to the temporary table space, otherwise the execution of some commands will be abnormal.

ALTER tablespace "TEMP"
ADD Tempfile
' C:\ORACLE9I\ORADATA\SHARK\Temp01.DBF ' [reuse] SIZE 200M

Here's your recovery work done and you can run some commands to check

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.