Issues encountered after applying Database Proactive Bundle Patch + OJVM PSU 12.1.0.2.180717

(Picture by Jannes Glas, via Unsplash)

I have to admit that I always volunteer at work when a patching has to be done. I like patching. Not the patching process itself, but the learning process. Sometimes it even helps me get better at troubleshooting.
Today I just want to gather in one post a few things that came up after applying Database Proactive Bundle Patch + OJVM PSU 12.1.0.2.180717, hoping this can help someone somewhere 🙂 I will update this post later if I encouter new issues.

RMAN-06091: no channel allocated for maintenance (of an appropriate type)

There is already a very interesting blog post by Mike Dietrich explaning the problem and pointing to relevant documentation.

In my case, after applying the patch on several servers and databases, my colleague noticed that cumulative backups on freshly patched databases generated the following error :

RMAN-06091: no channel allocated for maintenance (of an appropriate type)

But … only for databases residing on specific servers. Why ? What was the difference with other servers, then ?

It was the backup script ! For a group of legacy servers, we have an old script containing :

run {
CONFIGURE CONTROLFILE AUTOBACKUP ON;
sql "alter system archive log current " ;
allocate channel ch1 type 'SBT_TAPE' parms="xxx";
BACKUP INCREMENTAL LEVEL 1 CUMULATIVE DATABASE tag='CUMUL' format 'xxx' ;
sql "alter system archive log current " ;
backup archivelog like '%xxx%' not backed up 1 times tag 'xxx' format 'xxx' ;
DELETE NOPROMPT ARCHIVELOG LIKE '%xxx%' BACKED UP 1 TIMES TO DEVICE TYPE sbt;
release channel ch1;
}

Note that the DELETE NOPROMPT ARCHIVELOG is inside the run block. This was the problem. You can find patch 28432129 on my Oracle Support, but the note of Bug 28391990 suggests the following workaround : “remove delete from run block & run the delete outside run block”. So we tried :

run {
CONFIGURE CONTROLFILE AUTOBACKUP ON;
sql "alter system archive log current " ;
allocate channel ch1 type 'SBT_TAPE' parms="xxx";
BACKUP INCREMENTAL LEVEL 1 CUMULATIVE DATABASE tag='CUMUL' format 'xxx' ;
sql "alter system archive log current " ;
backup archivelog like '%xxx%' not backed up 1 times tag 'xxx' format 'xxx' ;
release channel ch1;
}
DELETE NOPROMPT ARCHIVELOG LIKE '%xxx%' BACKED UP 1 TIMES TO DEVICE TYPE sbt;

And it worked ! No need to patch again, at least in this case.

On more recent servers with another backup script, we also have DELETE NOPROMPT ARCHIVELOG inside the run block but we did not hit the bug. Maybe because RMAN channels are directly configured inside the database and not inside the block run ? I don’t know for sure.

ORA-39142: incompatible version number 4.2 in dump file

While importing with Data Pump a dump file from a patched database to an unpatched database, we had the following error :

Connected to: Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production
With the Partitioning, Automatic Storage Management, OLAP, Advanced Analytics
and Real Application Testing options
ORA-39000: bad dump file specification
ORA-39142: incompatible version number 4.2 in dump file "xxx"

Doc ID 2422236.1 on My Oracle Support indicates that the problem was introduced with 12.1.0.2.180417 (Apr 2018) Database Proactive Bundle Patch. There is either the possiblity to install patch 21480031 or to re-run the export with option VERSION=12.1. We used the latter …

expdp system/******** DIRECTORY=nice_directory dumpfile=nice_dumpfile.dp SCHEMAS=nice_schema logfile=nice_logfile.log VERSION=12.1

… and it worked as expected.

release of Java system classes in the database (12.1.0.2.0 1.6) does not match that of the oracle executable (12.1.0.2.180717 1.6)

This last problem is not a real one but I want to take notes in order to prevent myself from doing the same careless mistake 🙂

My dev colleagues have the ability to create restore point by themselves, and then launch flashbacks if needed. A few days ago, one of them asked for help about an error he got after running a script :

ERROR at line 1:
ORA-29548: Java system class reported: release of Java system classes in the database (12.1.0.2.0 1.6) does not match that of the oracle executable (12.1.0.2.180717 1.6)
ORA-06512: at "NICE_SCHEMA.OBJECT1", line 56
ORA-06512: at "NICE_SCHEMA.OBJECT1", line 66
ORA-06512: at "NICE_SCHEMA.OBJECT2", line 18
ORA-04088: error during execution of trigger 'NICE_SCHEMA.OBJECT2'
ORA-06512: at "NICE_SCHEMA.OBJECT3", line 613
ORA-06512: at "NICE_SCHEMA.OBJECT4", line 449
ORA-06512: at "NICE_SCHEMA.OBJECT4", line 498
ORA-06512: at line 1223

I quickly found out that before running his script, my colleague launched a flashback to a restore point … which was created BEFORE I patched the Oracle Home and ran datapatch against his database 😉

I just had to re-run the datapatch and it was fine.

PS : I am on airport train, on my way to #POUG2018 🤩😎✌🤪🍻

Advertisements

2 thoughts on “Issues encountered after applying Database Proactive Bundle Patch + OJVM PSU 12.1.0.2.180717

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s