Monday, April 29, 2024

ORA-19751: could not create the change tracking file ORA-19750: change tracking file: ORA-17502: ksfdcre:4 Failed to create file


ISSUE

SQL> alter database open resetlogs;

alter database open resetlogs
*
ERROR at line 1:
ORA-19751: could not create the change tracking file
ORA-19750: change tracking file:
'+DATA/DB_NAME/CHANGETRACKING/ctf.281.1234567789'
ORA-17502: ksfdcre:4 Failed to create file
+DATA/DB_NAME/CHANGETRACKING/ctf.281.1234567789
ORA-15046: ASM file name
'+DATA/DB_NAME/CHANGETRACKING/ctf.281.1234567789' is not in
single-file creation form
ORA-17503: ksfdopn:2 Failed to open file
+DATA/DB_NAME/CHANGETRACKING/ctf.281.1234567789
ORA-15012: ASM file '+DATA/DB_NAME/CHANGETRACKING/ctf.281.1234567789'

does not exist


ACTIONS PERFORMED

Database was restored and recovered using rman and attempted to open with resetlogs.

Source Database using a 'block change tracking' file stored in ASM. Controlfile and Database is restored and recovered successfully but the open resetlogs fails with above errors.


ISSUE IS DUE TO

The change tracking file is originally created like this:
.
SQL> alter database enable block change tracking using file '+<DGNAME>';

Because the change tracking file is created by only specifying the ASM Diskgroup, a fully qualified ASM name is used for this file and stored in the DataDictionary.
When this file is not found during the open phase, the same filename will be used to recreate the file automatically by using the fully qualified ASM name which is not allowed, hence the error.

Bug 5362418 is opened for this has been closed as a duplicate of 11744544.



SOLUTION

Disable  the block change tracking 

- try OPEN RESTLOGS again, if any error, open normally.

- And enable block chnage tracking again, Use an ASM alias in the diskgroup. This way, the alias will be recreated successfully (which in turn will be linked to a new ASM fully qualified name behind the scenes)



SQL> alter database disable BLOCK CHANGE TRACKING;

Database altered.


SQL> alter database open resetlogs;

alter database open resetlogs

*

ERROR at line 1:

ORA-01139: RESETLOGS option only valid after an incomplete database recovery


SQL>  alter database open;

Database altered.


SQL> ALTER DATABASE ENABLE BLOCK CHANGE TRACKING USING FILE '+DATA';

Database altered.








Friday, February 9, 2024

ORA-04063: package body "SYS.DBMS_RCVMAN" has errors

 

ISSUE DESCRIPTION

rman target /


Recovery Manager: Release 12.2.0.1.0 - Production on Fri Feb 9 19:26:23 2024


Copyright (c) 1982, 2017, Oracle and/or its affiliates.  All rights reserved.


ORACLE error from target database:

ORA-04063: package body "SYS.DBMS_RCVMAN" has errors

ORA-06508: PL/SQL: could not find program unit being called: "SYS.DBMS_RCVMAN"


error executing package DBMS_RCVMAN in TARGET database

RMAN-00571: ===========================================================

RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============

RMAN-00571: ===========================================================

RMAN-00554: initialization of internal recovery manager package failed

RMAN-06429: TARGET database is not compatible with this version of RMAN









COMPILE the objects

rman target /


Recovery Manager: Release 12.2.0.1.0 - Production on Fri Feb 9 19:26:23 2024





STATUS of the OBJECTS 

select owner,object_name,object_type,status from dba_objects where status='INVALID'

OWNER OBJECT_NAME OBJECT_TYPE STATUS
-------------------- ------------------------------ ----------------------- -------
SYS DBMS_RCVMAN PACKAGE BODY INVALID




SOLUTION

SQL> alter PACKAGE SYS.DBMS_RCVMAN compile BODY;

Warning: Package Body altered with compilation errors.

SQL>
SQL>
SQL>
SQL> sho error
Errors for PACKAGE BODY SYS.DBMS_RCVMAN:

LINE/COL ERROR
-------- -----------------------------------------------------------------
462/1    PL/SQL: Item ignored
463/8    PLS-00400: different number of columns between cursor SELECT
         statement and return value

8247/1   PL/SQL: Item ignored
8248/8   PLS-00400: different number of columns between cursor SELECT
         statement and return value




SQL>

SQL> @?/rdbms/admin/prvtrmns.plb

Session altered.

Package body created.

Session altered.

SQL>

SQL>

SQL> !



rman target /

Recovery Manager: Release 12.2.0.1.0 - Production on Fri Feb 9 21:07:36 2024

Copyright (c) 1982, 2017, Oracle and/or its affiliates.  All rights reserved.

connected to target database: DBNAME (DBID=123456789)

RMAN> exit

Recovery Manager complete.