How to re-create a control file ?
1) select name from v$controlfile;
2) Create control file:
show parameter user_dump_dest
ALTER DATABASE BACKUP CONTROLFILE TO TRACE;
ALTER DATABASE BACKUP CONTROLFILE TO TRACE AS '/tmp/create_ctl.sql';
3) Issue create control file statment:
STARTUP NOMOUNT
CREATE CONTROLFILE SET DATABASE "REMEDY" NORESETLOGS ARCHIVELOG
MAXLOGFILES 16
MAXLOGMEMBERS 3
MAXDATAFILES 100
MAXINSTANCES 8
MAXLOGHISTORY 2920
LOGFILE
GROUP 1 (
'+DG1/jaydb/onlinelog/group_1.290.821033159',
'+DG1/jaydb/onlinelog/group_1.289.821033159'
) SIZE 50M BLOCKSIZE 512,
GROUP 2 (
'+DG1/jaydb/onlinelog/group_2.291.821033183',
'+DG1/jaydb/onlinelog/group_2.268.821033183'
) SIZE 50M BLOCKSIZE 512,
GROUP 3 (
'+DG1/jaydb/onlinelog/group_3.288.821033283',
'+DG1/jaydb/onlinelog/group_3.286.821033285'
) SIZE 50M BLOCKSIZE 512,
GROUP 4 (
'+DG1/jaydb/onlinelog/group_4.276.821033337',
'+DG1/jaydb/onlinelog/group_4.287.821033339'
) SIZE 50M BLOCKSIZE 512,
GROUP 5 (
'+DG1/jaydb/onlinelog/group_5.275.821033345',
'+DG1/jaydb/onlinelog/group_5.256.821033347'
) SIZE 50M BLOCKSIZE 512
-- STANDBY LOGFILE
DATAFILE
'+DG1/jaydb/datafile/system.262.821036305',
'+DG1/jaydb/datafile/sysaux.263.821036305',
'+DG1/jaydb/datafile/undotbs1.258.821036305',
'+DG1/jaydb/datafile/users.261.821036543',
'+DG1/jaydb/datafile/aratt_tbl.264.821036305',
'+DG1/jaydb/datafile/aratt_idx.265.821036381',
'+DG1/jaydb/datafile/armd_tbl.271.821036303',
'+DG1/jaydb/datafile/armd_idx.270.821036305',
'+DG1/jaydb/datafile/arsh_tbl.259.821036305',
'+DG1/jaydb/datafile/arsh_idx.267.821036385',
'+DG1/jaydb/datafile/jaydb_idx.266.821036393',
'+DG1/jaydb/datafile/arsystem.257.821036301'
CHARACTER SET WE8MSWIN1252
;
4) Performa media recovery:
RECOVER DATABASE
5) Open the database:
ALTER DATABASE OPEN
1) select name from v$controlfile;
2) Create control file:
show parameter user_dump_dest
ALTER DATABASE BACKUP CONTROLFILE TO TRACE;
ALTER DATABASE BACKUP CONTROLFILE TO TRACE AS '/tmp/create_ctl.sql';
3) Issue create control file statment:
STARTUP NOMOUNT
CREATE CONTROLFILE SET DATABASE "REMEDY" NORESETLOGS ARCHIVELOG
MAXLOGFILES 16
MAXLOGMEMBERS 3
MAXDATAFILES 100
MAXINSTANCES 8
MAXLOGHISTORY 2920
LOGFILE
GROUP 1 (
'+DG1/jaydb/onlinelog/group_1.290.821033159',
'+DG1/jaydb/onlinelog/group_1.289.821033159'
) SIZE 50M BLOCKSIZE 512,
GROUP 2 (
'+DG1/jaydb/onlinelog/group_2.291.821033183',
'+DG1/jaydb/onlinelog/group_2.268.821033183'
) SIZE 50M BLOCKSIZE 512,
GROUP 3 (
'+DG1/jaydb/onlinelog/group_3.288.821033283',
'+DG1/jaydb/onlinelog/group_3.286.821033285'
) SIZE 50M BLOCKSIZE 512,
GROUP 4 (
'+DG1/jaydb/onlinelog/group_4.276.821033337',
'+DG1/jaydb/onlinelog/group_4.287.821033339'
) SIZE 50M BLOCKSIZE 512,
GROUP 5 (
'+DG1/jaydb/onlinelog/group_5.275.821033345',
'+DG1/jaydb/onlinelog/group_5.256.821033347'
) SIZE 50M BLOCKSIZE 512
-- STANDBY LOGFILE
DATAFILE
'+DG1/jaydb/datafile/system.262.821036305',
'+DG1/jaydb/datafile/sysaux.263.821036305',
'+DG1/jaydb/datafile/undotbs1.258.821036305',
'+DG1/jaydb/datafile/users.261.821036543',
'+DG1/jaydb/datafile/aratt_tbl.264.821036305',
'+DG1/jaydb/datafile/aratt_idx.265.821036381',
'+DG1/jaydb/datafile/armd_tbl.271.821036303',
'+DG1/jaydb/datafile/armd_idx.270.821036305',
'+DG1/jaydb/datafile/arsh_tbl.259.821036305',
'+DG1/jaydb/datafile/arsh_idx.267.821036385',
'+DG1/jaydb/datafile/jaydb_idx.266.821036393',
'+DG1/jaydb/datafile/arsystem.257.821036301'
CHARACTER SET WE8MSWIN1252
;
4) Performa media recovery:
RECOVER DATABASE
5) Open the database:
ALTER DATABASE OPEN
No comments:
Post a Comment