Oracle AutoUpgrade between two servers – and Plugin?

In my previous blog post I demonstrated how you can upgrade with AutoUpgrade between two servers. This a very typical scenario where you get new server, often also with a newer operating system version installed. But I was wondering if you can use Oracle AutoUpgrade between two servers – and Plugin?

AutoUpgrade between two servers

Please see my previous blog post about all the details:

Upgrade and Plugin?

At the end of it, I was curious if I couldn’t just plugin afterwards. But I failed at first.

It turned out that I needed a slight change in actions and parameters. And it works smoothly.

Starting point is again my DB12 database, but now upgraded to Oracle Database 19.8.0. And I have an existing container database, CDB2, up and running in 19.8.0 as well.

Adjustments to the config file

I recycle my config file but make some adjustments:

  • source_home
  • target_cdb
  • target_pdb_name

I certainly could have added target_pdb_copy_option as well. But I wanted to have my files stay in place.

This is how my config file DB12NEW.cfg looks like now:


Call it with DEPLOY

The secret to make this work is now that you must have the database open regularly – and use -mode deploy to start the plugin.

I kick it off with:

java -jar $OH19/rdbms/admin/autoupgrade.jar -config DB12NEW.cfg -mode deploy

After a few minutes, I receive confirmation from the AutoUpgrade job console:

$ java -jar $OH19/rdbms/admin/autoupgrade.jar -config DB12NEW.cfg -mode deploy

AutoUpgrade tool launched with default options
Processing config file ...
| Starting AutoUpgrade execution |
1 databases will be processed
Type 'help' to list console commands

upg> lsj
| 101|   DB12|NONCDBTOPDB|EXECUTING|RUNNING|20/07/31 17:23|17:23:39|Executing describe|
Total jobs 1

upg> Job 101 completed
------------------- Final Summary --------------------
Number of databases            [ 1 ]

Jobs finished successfully     [1]
Jobs failed                    [0]
Jobs pending                   [0]
------------- JOBS FINISHED SUCCESSFULLY -------------
Job 101 for DB12

Let me check this …

It really works. Very cool!

But let me check my receiving CDB:

[oracle@hol auto]$ . cdb2
[CDB2] oracle@hol:~/logs/cfgtoollogs/upgrade/auto

$ sqlplus / as sysdba

SQL*Plus: Release - Production on Fri Jul 31 17:42:58 2020

Copyright (c) 1982, 2020, Oracle.  All rights reserved.

Connected to:
Oracle Database 19c Enterprise Edition Release - Production

SQL> show pdbs

     CON_ID CON_NAME                      OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ ONLY  NO
         3 PDB1                           READ WRITE NO

Here we go – plugged in safely! It has a new name now. But still the old files which you can easily rename and move around if needed:

SQL> alter session set container=pdb1;

Session altered.

SQL> select name from v$datafile;


Further Information and Links


Share this: