RE: Oracle 19c DBUA Upgrade Fails

From: Scott Canaan <srcdco_at_rit.edu>
Date: Mon, 14 Sep 2020 17:56:11 +0000
Message-ID: <ceece93b2ec44cf4a446338c5a2d27d3_at_ex04test91d.ad.rit.edu>



Thank you for the detailed response. I will put a check in our upgrade document and drop that database link if it exists in future upgrades. That’s a great idea.

Scott Canaan ‘88
Sr Database Administrator
Information & Technology Services
Finance & Administration
Rochester Institute of Technology
o: (585) 475-7886 | f: (585) 475-7520
srcdco_at_rit.edu<mailto:srcdco_at_rit.edu> | c: (585) 339-8659

CONFIDENTIALITY NOTE: The information transmitted, including attachments, is intended only for the person(s) or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and destroy any copies of this information.

From: Mikhail Velikikh <mvelikikh_at_gmail.com> Sent: Monday, September 14, 2020 1:47 PM To: Scott Canaan <srcdco_at_rit.edu>
Cc: oracle-l_at_freelists.org
Subject: Re: Oracle 19c DBUA Upgrade Fails

CAUTION: This message came from outside RIT. If you are unsure about the source or content of this message, please contact the RIT Service Center at 585-475-5000 or help.rit.edu before clicking links, opening attachments or responding.

Hi Scott,

I have not come across that issue but I have done a few tests after reading your email.

The following document explains the use of that database link and whether it can be deleted: What Is The Use Of DataBase Link SYS.sys_hub And Can It Be Deleted(Doc ID 2413797.1)

This one explains how to create that database link: How to Drop and Create SYS_HUB (Database Link) ? (Doc ID 2442938.1)

The last article mentions the relevant procedure: dbms_pq_internal.create_db_link_for_hub

It is called in prvtpq.plb in my 19.7:
[oracle_at_rac2 admin]$ grep -i for_hub *
grep: backport_files: Is a directory
prvtpq.plb:execute dbms_pq_internal.create_db_link_for_hub

Firstly, I reproduced that error by calling that procedure: SQL> alter session set events 'sql_trace';

Session altered.

SQL> exec dbms_pq_internal.create_db_link_for_hub BEGIN dbms_pq_internal.create_db_link_for_hub; END;

*
ERROR at line 1:

ORA-20000: Could not create database link: sys-hub
ORA-06512: at "SYS.DBMS_PQ_INTERNAL", line 15
ORA-06512: at line 1

Oracle developers actually put an ingenious WHEN OTHERS THEN NULL handler there. That is why I enabled SQL Trace before running that procedure. That is what I got in the trace file:
PARSING IN CURSOR #140188464645392 len=42 dep=1 uid=0 oct=32 lid=0 tim=19421396586 hv=233820831 ad='7f802b9fd8b0' sql id='fx4pas86yznnz'
create database link sys_hub using 'RACDB' END OF STMT
PARSE #140188464645392:c=346,e=346,p=0,cr=0,cu=0,mis=1,r=0,dep=1,og=1,plh=0,tim=19421396581 EXEC #140188464645392:c=6128,e=6174,p=0,cr=0,cu=0,mis=0,r=0,dep=1,og=1,plh=0,tim=19421402813 ERROR #140188464645392:err=2011 tim=19421402837

RACDB is my V$DATABASE.NAME<http://DATABASE.NAME>.

The corresponding error code is 2011:
[oracle_at_rac2 admin]$ oerr ora 2011

02011, 00000, "duplicate database link name" // *Cause:
// *Action:

Sure enough, there was a database link SYS_HUB in my database. I dropped it and was able to run the procedure successfully: SQL> drop database link sys_hub;

Database link dropped.

SQL> exec dbms_pq_internal.create_db_link_for_hub

PL/SQL procedure successfully completed.

Depending on what error you are getting internally and what script is called when you get that error, you could try to drop that database link before doing the actual upgrade.

Best regards,
Mikhail Velikikh

On Mon, 14 Sep 2020 at 18:16, Scott Canaan <srcdco_at_rit.edu<mailto:srcdco_at_rit.edu>> wrote: I’m trying to upgrade an Oracle 12.2.0.1 database to Oracle 19.8 using DBUA on Red Hat Linux 7. I’ve done a number of Oracle 19c upgrades with no issues. This time, it gets part way through then throws the following error:

ORA-20000: Could not create database link: sys-hub ORA-06512: at "SYS.DBMS_PQ_INTERNAL", line 15 ORA-06512: at line 1

ORA-06512: at "SYS.DBMS_PQ_INTERNAL", line 15 ORA-06512: at line 1

ORA-06512: at line 1
Oracle Server INVALID 19.8.0.0.0 00:13:32 Oracle Real Application Clusters OPTION OFF 19.8.0.0.0 00:00:00 Oracle XML Database UPGRADED 19.8.0.0.0 00:01:52 Datapatch 00:02:03
Final Actions 00:02:12
Post Upgrade 00:00:16

Total Upgrade Time: 00:20:03

It only gets to 49% complete before it pops up a window saying that it failed and the only options given are “Retry” and “Abort”. I’ve opened an SR with Oracle, but they have not been at all helpful. The response is that the upgrade is complete and I just have to run utlrp 4 or 5 times within 3 minutes (I tried it, it doesn’t help) and then run the final upgrade step manually followed by the time zone upgrade. I’ve tried that, but it all fails. What I’m looking for is what needs to be fixed before starting the upgrade so the error doesn’t occur. I’ve tried asking for that and the response was to do the same thing that already doesn’t work.

Any ideas?

Scott Canaan ‘88
Sr Database Administrator
Information & Technology Services
Finance & Administration
Rochester Institute of Technology
o: (585) 475-7886 | f: (585) 475-7520
srcdco_at_rit.edu<mailto:srcdco_at_rit.edu> | c: (585) 339-8659 CONFIDENTIALITY NOTE: The information transmitted, including attachments, is intended only for the person(s) or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and destroy any copies of this information.

--
http://www.freelists.org/webpage/oracle-l
Received on Mon Sep 14 2020 - 19:56:11 CEST

Original text of this message