Oracle operation notes

Source: Internet
Author: User

Oracle related operation Notes 1. database recovery in cold data, scenarios, including database files of all strength, including ORA, DBF, CTL files, and other logs. 10g 1. scenario 1: If the directory structure of the recovered target database and the source database is the same, it is easy to create an identical database instance and copy the database files. 2. Scenario 2: If the target database to be restored is different from the installation directory of the source database, the following procedure can be used. 1. Create a database instance with the same name. 2. go to the oraclehome/admin/sid/pfile/directory (copy the pfile content of other available instances to the files in this directory) and modify the consolefile address, and Instance name.

 # File Configuration###########################################control_files=("E:\oracle\product\10.2.0\db_1/oradata/cqyyjk/\control01.ctl", "E:\oracle\product\10.2.0\db_1/oradata/cqyyjk/\control02.ctl", "E:\oracle\product\10.2.0\db_1/oradata/cqyyjk/\control03.ctl")db_recovery_file_dest=E:\oracle\product\10.2.0\db_1/flash_recovery_areadb_recovery_file_dest_size=2147483648############################################ Cursors and Library Cache

 

3. Save the source file to the target server by creating a folder according to the original directory, and then start the login. 4. Supplement: if an error is reported after successful login, We Can recompile the database. The specific process is to enter the command line and execute the following command:
      set oracle_sid=sid      sqlplus /nolog     conn username/password as sysdba     shutdown immediate    startup upgrade @oraclehome/RDBMS/ADMIN/utlirp.sql;   shutdown immediatestartup

 

2. Database Upgrade causes the original instance to be unable to use normally, view oraclehome/admin/sid/bdump/log, find the ORA-01092 error, we can use the following method to execute the upgrade statement.
 set oracle_sid=sidsqlplus /nologconn username/password as sysdbastartup upgrade@oraclehome/RDBMS/ADMIN/catupgrd.sqlshutdown immediatestartup

 

So far. This process takes a long time. Appendix: Control File Creation statement:
CREATE CONTROLFILE REUSE DATABASE "sid" RESETLOGS  NOARCHIVELOG     MAXLOGFILES 50     MAXLOGMEMBERS 5     MAXDATAFILES 100     MAXINSTANCES 1     MAXLOGHISTORY 680 LOGFILE   GROUP 1 'D:\ORACLE\PRODUCT\10.2.0\ORADATA\sid\REDO01.LOG'  SIZE 100M,   GROUP 2 'D:\ORACLE\PRODUCT\10.2.0\ORADATA\sid\REDO02.LOG'  SIZE 100M,   GROUP 3 'D:\ORACLE\PRODUCT\10.2.0\ORADATA\sid\REDO03.LOG'  SIZE 100M DATAFILE   'D:\ORACLE\PRODUCT\10.2.0\ORADATA\sid\ZFXFZB\test.DBF',   'D:\ORACLE\PRODUCT\10.2.0\ORADATA\sid\test.DBF',   'D:\ORACLE\PRODUCT\10.2.0\ORADATA\sid\test.DBF',   'D:\ORACLE\PRODUCT\10.2.0\ORADATA\sid\test.DBF',   'D:\ORACLE\PRODUCT\10.2.0\ORADATA\sid\test.DBF',  'D:\ORACLE\PRODUCT\10.2.0\ORADATA\sid\test.ORA',  'D:\ORACLE\PRODUCT\10.2.0\ORADATA\sid\test.ORA',  'D:\ORACLE\PRODUCT\10.2.0\ORADATA\sid\test.ORA'CHARACTER SET ZHS16GBK

 


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.