Skip to Main Content
  • Questions
  • Performance issue after migrate from 10g to 19c

Breadcrumb

Question and Answer

Connor McDonald

Thanks for the question, Vince.

Asked: August 26, 2024 - 10:46 am UTC

Last updated: August 29, 2024 - 3:35 am UTC

Version: 19.21

Viewed 1000+ times

You Asked

We are doing upgrade of Oracle 10g DB to 19c.
for the data migration, we use export the data pump from 10g DB and import it into the new 19c DB.
After the data migration was completed and start the performance testing, We found that many Query SQL runs much slower than on 10g DB.
We checked the explain plan, tables' statistics etc.. but there was no solution.
Then we try to collect statistics for all tables.
The first time we used "DBMS_STATS" package which is suggested by Oracle, but it didn't work.(execution time ~43 mins.)
The second time we used "analyze" script, the performance back to normal.(execution time ~2 secs.)

My questions are:
1. What causes the execution time to slow down after migrate to 19c?
2. Why use analyze script can be fixed the issue, but DBMS_STATS?
3. Which parameters(or table statistics info) do I need to check?

and Connor said...

1. What causes the execution time to slow down after migrate to 19c?

we use export the data pump from 10g DB and import it into the new 19c DB.

Here's the challenge you're facing. A datapump unload/reload is a clone of the data not the organization of the data. What you effectively have is a brand new database, that just happens to have same tables from the previous one.

It is hence quite probable that you will have

- some queries that run the same
- some queries that run faster
- some queries that run slower

2. Why use analyze script can be fixed the issue, but DBMS_STATS?

My suspicion would be this



3. Which parameters(or table statistics info) do I need to check?

Rather than parameters and stats, start with problematic SQL. Tackle each one in turn looking at root causes (could be stats, could be the fresh data organization, could be many things).


More to Explore

Data Pump

All of the database utilities including Data Pump are explained in the Utilities guide.