2

Oracle version = Oracle 8i (817_312) //Yes I know this is old.

Database id = LED

OS = Solaris 8

Oracle USERID = oraled

Oracle DBA group = dba

rman backups to disk.

Sorry this is so long. I am not a DBA, I am UNIX/Linux system administrator. We lost our DBA a while ago, and I was told to keep it running. What am I missing or doing wrong?

I am trying to restore an oracle database from a good backup and I am getting errors that there is a problem with the controlfiles. The oracle DB is up, mounted and open when this script runs. This is how we are backing up the oracle DB from Oracle's cron.

rman target / nocatalog cmdfile=/oracle/admin/led/rman/LEDlvl0 log=$LOGFILE

and in /oracle/admin/led/rman/LEDlvl0.sh we have

run {
set command id to 'LED_rman_test';
allocate channel disk1 type disk format '/apps1/backup/%d.LVL0.%s.%t.%p.dbf';
allocate channel disk2 type disk format '/apps2/backup/%d.LVL0.%s.%t.%p.dbf';
allocate channel disk3 type disk format '/apps3/backup/%d.LVL0.%s.%t.%p.dbf';
allocate channel disk5 type disk format '/apps5/backup/%d.LVL0.%s.%t.%p.dbf';
allocate channel disk6 type disk format '/apps6/backup/%d.LVL0.%s.%t.%p.dbf';


backup incremental level=0 setsize=7000000 database ;
backup (current controlfile format '/apps4/backup/%d.%s.%t.%p.ctl');


release channel disk1;
release channel disk2;
release channel disk3;
release channel disk5;
release channel disk6;

This ran succesfully. I want to restore this backup. I have removed the data files and copied the control file (/apps4/backup/LED.22010.973362972.1.ctl) file back to the the locations specified by the initLED.ora file.

As the Oracle user these are the commands I am running.

$ rman nocatalog

RMAN> connect target sys/********@LED

RMAN>  startup mount

and I get this error

RMAN-06196: Oracle instance started
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-06003: ORACLE error from target database: ORA-00205: error in identifying controlfile, check alert log for more info
RMAN-06097: text of failing SQL statement: alter database mount
RMAN-06099: error occurred in source file: krmk.pc, line: 4192

and the alertLED.log shows:

Tue Apr 24 16:57:04 2018
Starting ORACLE instance (normal)
LICENSE_MAX_SESSION = 0
LICENSE_SESSIONS_WARNING = 0
LICENSE_MAX_USERS = 0
Starting up ORACLE RDBMS Version: 8.1.7.0.0.
System parameters with non-default values:
  processes                = 150
  sessions                 = 170
  timed_statistics         = TRUE
  event                    = 10183 trace name context forever, level 1,   
10191 trace name context forever, level 1
  shared_pool_size         = 400000000
  enqueue_resources        = 8000
  control_files = /oracle/LED/sapdata1/cntrl/cntrlLED.dbf, /oracle/LED/sapdata2/cntrl/cntrlLED.dbf, /oracle/LED/sapdata3/cntrl/cntrlLED.dbf
  db_block_buffers         = 142000
  db_block_size            = 8192
  db_block_lru_latches     = 4
  compatible               = 8.1.0
  log_archive_start        = TRUE
  log_archive_dest         = /oracle/LED/saparch/R3Parch
  log_archive_min_succeed_dest= 1
  log_buffer               = 1048576 
  log_checkpoint_interval  = 300000
  log_checkpoint_timeout   = 0
  db_files                 = 254
  db_file_multiblock_read_count= 8
  log_checkpoints_to_alert = TRUE
  control_file_record_keep_time= 45
  dml_locks                = 2500
  row_locking              = always
  replication_dependency_tracking= FALSE
  transactions_per_rollback_segment= 20
  max_rollback_segments    = 400
  rollback_segments        = PRS_0, PRS_1, PRS_2, PRS_3, PRS_4, PRS_5, PRS_6, PRS_7, PRS_8, PRS_9
  transaction_auditing     = FALSE
  remote_os_authent        = TRUE
  remote_login_passwordfile= EXCLUSIVE
  db_domain                = world
  audit_trail              = TRUE
  sort_area_size           = 2097152
  sort_area_retained_size  = 0
  db_name                  = LED
  open_cursors             = 800
  optimizer_mode           = choose
  optimizer_index_cost_adj = 10
  cursor_space_for_time    = FALSE
  parallel_max_servers     = 20
  hash_join_enabled        = FALSE
  background_dump_dest     = /oracle/LED/saptrace/background
  user_dump_dest           = /oracle/LED/saptrace/usertrace
  core_dump_dest           = /oracle/LED/saptrace/background
PMON started with pid=2
DBW0 started with pid=3
LGWR started with pid=4
CKPT started with pid=5
SMON started with pid=6
RECO started with pid=7
Tue Apr 24 16:57:07 2018
ARCH: STARTING ARCH PROCESSES
ARC0 started with pid=8
Tue Apr 24 16:57:07 2018
ARCH: STARTING ARCH PROCESSES COMPLETE
Tue Apr 24 16:57:07 2018
ARC0: Archival started
Tue Apr 24 16:57:07 2018
alter database mount
Tue Apr 24 16:57:07 2018
ORA-00202: controlfile: '/oracle/LED/sapdata1/cntrl/cntrlLED.dbf'
Tue Apr 24 16:57:10 2018
ORA-205 signalled during: alter database mount...

and

oerr 205 give me this:

$ oerr ora 205
00205, 00000, "error in identifying controlfile, check alert log for more info"
// *Cause:  The system could not find a controlfile of the specified name and
//         size.
// *Action: Check that ALL controlfiles are online and that they are the same
//         files that the system created at cold start time.

So I check the controlfiles:

$ ls -l /oracle/LED/sapdata1/cntrl/cntrlLED.dbf /oracle/LED/sapdata2/cntrl/cntrlLED.dbf /oracle/LED/sapdata3/cntrl/cntrlLED.dbf
-rw-r-----   1 oraled   dba      29876736 Apr 23 23:19 /oracle/LED/sapdata1/cntrl/cntrlLED.dbf
-rw-r-----   1 oraled   dba      29876736 Apr 23 23:19 /oracle/LED/sapdata2/cntrl/cntrlLED.dbf
-rw-r-----   1 oraled   dba      29876736 Apr 23 23:19 /oracle/LED/sapdata3/cntrl/cntrlLED.dbf

So I try and restore the controlfile.

$ rman nocatalog

RMAN> connect target sys/********@LED

RMAN> startup nomount


RMAN-06196: Oracle instance started

Total System Global Area    1609240736 bytes

Fixed Size                       73888 bytes
Variable Size                444837888 bytes
Database Buffers            1163264000 bytes
Redo Buffers                   1064960 bytes

RMAN> run {
2> allocate channel ch1 type disk;
3> allocate channel ch2 type disk;
4> allocate channel ch3 type disk;
5> allocate channel ch5 type disk;
6> allocate channel ch6 type disk;
7>
8> restore controlfile to '/apps6/backup/jimt.ctl';
9> }

RMAN-03022: compiling command: allocate
RMAN-03023: executing command: allocate
RMAN-08030: allocated channel: ch1
RMAN-08500: channel ch1: sid=10 devtype=DISK

RMAN-03022: compiling command: allocate
RMAN-03023: executing command: allocate
RMAN-08030: allocated channel: ch2
RMAN-08500: channel ch2: sid=11 devtype=DISK

RMAN-03022: compiling command: allocate
RMAN-03023: executing command: allocate
RMAN-08030: allocated channel: ch3
RMAN-08500: channel ch3: sid=12 devtype=DISK

RMAN-03022: compiling command: allocate
RMAN-03023: executing command: allocate
RMAN-08030: allocated channel: ch5
RMAN-08500: channel ch5: sid=13 devtype=DISK

RMAN-03022: compiling command: allocate
RMAN-03023: executing command: allocate
RMAN-08030: allocated channel: ch6
RMAN-08500: channel ch6: sid=14 devtype=DISK

RMAN-03022: compiling command: restore

RMAN-03022: compiling command: IRESTORE
RMAN-03026: error recovery releasing channel resources
RMAN-08031: released channel: ch1
RMAN-08031: released channel: ch2
RMAN-08031: released channel: ch3
RMAN-08031: released channel: ch5
RMAN-08031: released channel: ch6
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure during compilation of command
RMAN-03013: command type: restore
RMAN-03002: failure during compilation of command
RMAN-03013: command type: IRESTORE
RMAN-06003: ORACLE error from target database: ORA-01507: database not mounted
ORA-06512: at "SYS.X$DBMS_RCVMAN", line 4461
ORA-06512: at line 1
RMAN-06097: text of failing SQL statement: begin dbms_rcvman . setDatabase ( upper ( :dbname:dbname_i ) , :rlscn , :rltime , :fhdbi:fhdbi_i ) ; end ;
RMAN-06099: error occurred in source file: krmk.pc, line: 9196

I am stuck. Any ideas of what I should try next?

Thanks JiM T

1

The controlfile BACKUP you copied is not the same as a controlfile.

Can you try

restore controlfile from '/path/to/controlfile_backup.ctl';

or failing that, check this out "Oracle8i Recovery Manager User's Guide and Reference" "Restoring the Control File from a Backup Set Without Using RMAN" https://docs.oracle.com/cd/A87860_01/doc/server.817/a76990/rmanreco.htm#441496

  • I tried the above restore command and it failed.: Here is the Error message: RMAN> restore controlfile from '/apps4/backup/LED.22010.973362972.1.ctl'; RMAN-00558: error encountered while parsing input commands RMAN-01005: syntax error: found "restore": expecting one of: "allocate, alter, beginline, catalog, change, connect, create, crosscheck, configure, debug, delete, drop, exit, endinline, host, {, library, list, mount, open, print, register, release, replace, report, renormalize, reset, resync, rman, rpct" RMAN-01007: at line 1 column 1 file: standard input – Jim T Apr 26 '18 at 17:40
  • My version of oracle is so old it doesn't support the restore from syntax. – Jim T Apr 26 '18 at 17:42
  • Check out the second part of my answer where I give you a link to the Oracle doc that shows how to do a controlfile restore in 8i using PL/SQL, you don't need RESTORE FROM for that. Another thing you could try, copy the controlfile backup piece to a file called fred.zip. Try and unzip fred.zip. The very early versions of RMAN used zip. – user125152 Apr 27 '18 at 10:15
  • When do you backup your ARCHIVELOGS? – user125152 Apr 27 '18 at 10:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.