Get the App
SLTechnology News&Howtos  ›  Database  › 

How to manually create a control file in the database

Shulou Source: shulou.com Published: 2022-05-31 15:13:02 10月04日 Update

This article mainly shows you "how to create control files manually in the database". The content is simple and clear. I hope it can help you solve your doubts. Let the editor lead you to study and learn this article "how to create control files manually in the database".

Background description:

A set of oracle databases is migrated from window to Linux

Backup on Windows and restore on Linux, but the restored control file contains the archive on Windows, which cannot be deleted on Linux, and the control file needs to be rebuilt.

RMAN > crosscheck archivelog all

Allocated channel: ORA_DISK_1

Channel ORA_DISK_1: SID=592 device type=DISK

Validation succeeded for archived log

Archived log file name=/oradata/orabak/O1_MF_1_12714_DNK7Y6DG_.ARC RECID=72

RMAN-03009: failure of crosscheck command on ORA_DISK_1 channel at 06/20/2017 15:50:44

ORA-19633: control file record 1 is out of sync with recovery catalog

Back up the oracle database first

Rman > backup database

Rman > backup current controlfile

Cd / u01/app/oracle/diag/rdbms/orcl/orcl/trace

Tail-100f alert*

Alter database backup controlfile to trace

Sql > startup nomount

Sql > CREATE CONTROLFILE REUSE DATABASE "ORCL" NORESETLOGS ARCHIVELOG

MAXLOGFILES 16

MAXLOGMEMBERS 3

MAXDATAFILES 100

MAXINSTANCES 8

MAXLOGHISTORY 292

LOGFILE

GROUP 11'/ oradata/orcl/redo11.log' SIZE 50m BLOCKSIZE 512

GROUP 12'/ oradata/orcl/redo12.log' SIZE 50m BLOCKSIZE 512

GROUP 13'/ oradata/orcl/redo13.log' SIZE 50m BLOCKSIZE 512

-- STANDBY LOGFILE

DATAFILE

'/ oradata/orcl/SYSTEM01.DBF'

'/ oradata/orcl/SYSAUX01.DBF'

'/ oradata/orcl/UNDOTBS01.DBF'

'/ oradata/orcl/USERS01.DBF'

'/ oradata/orcl/JINYI.DBF'

CHARACTER SET AL32UTF8

Sql > alter database open

The above is all the contents of the article "how to manually create control files in the database". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!

Tags: Data database file control manual content article backup learning help easy to understand more organization knowledge editing background industry information information channel channel Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Linux Redmi Microsoft OPPO Reno Shulou Information