Upgrade from Oracle 19c to 26ai between two different servers using PDB unplug/plug with AutoUpgrade

In this article, I’ll walk through upgrading a single 19c PDB by relocating it from Server A to Server B and upgrading it to 26ai using AutoUpgrade.

Note: this approach is handy when the target database version or operating system differs from the source, or when a full CDB upgrade is not desirable.

Scope and assumptions

  • The source is Oracle Database 19c RU 29 (the same approach applies to 21c, although it is already out of support).

  • The target database is Oracle AI Database 26ai (23.26.0).

  • Only a single PDB is moved and upgraded; the source CDB remains untouched.

  • Source and target systems have the same endianness, although they may run different OS releases.

Environment overview

Source:
  • Oracle Linux 7.9
  • Oracle Database 19c (RU 19.29.0)
Target:
  • Oracle Linux 8.7
  • Oracle AI Database 26ai (RU 23.26.0)

With these prerequisites in place, we can use PDB relocation combined with AutoUpgrade to perform the move and upgrade in a controlled and supported way.

Getting Started

Before moving the PDB, still in 19c, we need to do some prechecks and fixups to ensure nothing is going to fail. Please note you can’t perform those checks after you plug into the new 26ai database, as the dictionary becomes invalid until you finish the upgrade process.

So, connected to my server A, first I create the AutoUpgrade config file:

global.global_log_dir=/home/oracle/autopatch/logs
upg1.sid=orcl
upg1.source_home=/u01/app/oracle/product/19c/dbhome_1
upg1.target_home=/u01/app/oracle/product/26ai/dbhome_1
upg1.pdbs=PDB01
upg1.restoration=NO
upg1.target_version=23

Next, I will run the AutoUpgrade pre-checks:

$ $ORACLE_HOME/jdk/bin/java -jar autoupgrade.jar -config upgrade_pdb.cfg -mode analyze
AutoUpgrade 25.6.251016 launched with default internal options
Processing config file ...
+--------------------------------+
| Starting AutoUpgrade execution |
+--------------------------------+
1 CDB(s) plus 2 PDB(s) will be analyzed
Type 'help' to list console commands
upg> Job 100 completed
------------------- Final Summary --------------------
Number of databases            [ 1 ]

Jobs finished                  [1]
Jobs failed                    [0]

Please check the summary report at:
/home/oracle/autopatch/logs/cfgtoollogs/upgrade/auto/status/status.html
/home/oracle/autopatch/logs/cfgtoollogs/upgrade/auto/status/status.log

Checking the logs, we are good to fly:

$ cat /home/oracle/autopatch/logs/cfgtoollogs/upgrade/auto/status/status.log
==========================================
          Autoupgrade Summary Report
==========================================
[Date]           Wed Jan 14 16:10:32 GMT 2026
[Number of Jobs] 1
==========================================
[Job ID] 100
==========================================
[DB Name]                orcl
[Version Before Upgrade] 19.29.0.0.0
[Version After Upgrade]  19.29.0.0.0
------------------------------------------
[Stage Name]    PRECHECKS
[Status]        SUCCESS
[Start Time]    2026-01-14 16:09:48
[Duration]      0:00:43
[Log Directory] /home/oracle/autopatch/logs/orcl/100/prechecks
[Detail]        /home/oracle/autopatch/logs/orcl/100/prechecks/orcl_preupgrade.log
                Check passed and no manual intervention needed
------------------------------------------

Now let’s run the fixups:

$ $ORACLE_HOME/jdk/bin/java -jar autoupgrade.jar -config upgrade_pdb.cfg -mode fixups
AutoUpgrade 25.6.251016 launched with default internal options
Processing config file ...
+--------------------------------+
| Starting AutoUpgrade execution |
+--------------------------------+
1 CDB(s) plus 2 PDB(s) will be processed
Type 'help' to list console commands
upg> Job 101 completed
------------------- Final Summary --------------------
Number of databases            [ 1 ]

Jobs finished                  [1]
Jobs failed                    [0]

Please check the summary report at:
/home/oracle/autopatch/logs/cfgtoollogs/upgrade/auto/status/status.html
/home/oracle/autopatch/logs/cfgtoollogs/upgrade/auto/status/status.log

Checking the logs:

$ cat /home/oracle/autopatch/logs/cfgtoollogs/upgrade/auto/status/status.log
==========================================
          Autoupgrade Summary Report
==========================================
[Date]           Wed Jan 14 16:18:57 GMT 2026
[Number of Jobs] 1
==========================================
[Job ID] 101
==========================================
[DB Name]                orcl
[Version Before Upgrade] 19.29.0.0.0
[Version After Upgrade]  19.29.0.0.0
------------------------------------------
[Stage Name]    PRECHECKS
[Status]        SUCCESS
[Start Time]    2026-01-14 16:12:11
[Duration]      0:00:36
[Log Directory] /home/oracle/autopatch/logs/orcl/101/prechecks
[Detail]        /home/oracle/autopatch/logs/orcl/101/prechecks/orcl_preupgrade.log
                Check passed and no manual intervention needed
------------------------------------------
[Stage Name]    PREFIXUPS
[Status]        SUCCESS
[Start Time]    2026-01-14 16:12:47
[Duration]      0:06:10
[Log Directory] /home/oracle/autopatch/logs/orcl/101/prefixups
[Detail]        /home/oracle/autopatch/logs/orcl/101/prefixups/prefixups.html
------------------------------------------

Check prefixups.html if you want to get all the actions performed on your PDB to prepare it, like purge recyclebin, collecting dictionary statistics, etc.

Now we are good to fly. Since we are in 2 different servers, I will unplug the PDB from the first server.

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

SQL> alter pluggable database PDB01 close immediate;

Pluggable database altered.

SQL> alter pluggable database PDB01 unplug into '/u01/app/oradata/PDB01.xml';

Pluggable database altered.

Now it is time to move the PDB data files and XML to the new server:

$ rsync -avz /u01/app/oradata/ORCL/PDB01/ oracle@server-26ai:/u01/app/oradata/ORCL/PDB01/
sending incremental file list
./
sysaux01.dbf
system01.dbf
temp01.dbf
undotbs01.dbf
users01.dbf

sent 377,057,144 bytes  received 114 bytes  9,545,753.37 bytes/sec
total size is 1,458,610,176  speedup is 3.87

$ rsync -avz /u01/app/oradata/PDB01.xml oracle@server-26ai:/u01/app/oradata/PDB01.xml
sending incremental file list
PDB01.xml

sent 1,751 bytes  received 107 bytes  1,238.67 bytes/sec
total size is 7,628  speedup is 4.11

Now moving to the new 26ai server, it is time to plug our new database and trigger the Replay Upgrade by simply opening the PDB:

Connected to:
Oracle AI Database 26ai Enterprise Edition Release 23.26.0.0.0 - for Oracle Cloud and Engineered Systems
Version 23.26.0.0.0

SQL> show pdbs

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

SQL> create pluggable database PDB01 using '/u01/app/oradata/PDB01.xml' nocopy tempfile reuse;

Pluggable database created.

SQL> alter pluggable database PDB01 open upgrade;

Pluggable database altered.

SQL> exit

Now that the PDB is opened in upgrade state, we can call AutoUpgrade in the last of the 3 modes (upgrade).

Please note that we use the same config file. Calling AutoUpgrade:

$ $ORACLE_HOME/jdk/bin/java -jar autoupgrade.jar -config upgrade_pdb.cfg -mode upgrade
AutoUpgrade 25.6.251016 launched with default internal options
Processing config file ...
+--------------------------------+
| Starting AutoUpgrade execution |
+--------------------------------+
1 PDB(s) will be processed
Type 'help' to list console commands
upg> Job 102 completed
------------------- Final Summary --------------------
Number of databases            [ 1 ]

Jobs finished                  [1]
Jobs failed                    [0]

Please check the summary report at:
/home/oracle/autopatch/logs/cfgtoollogs/upgrade/auto/status/status.html
/home/oracle/autopatch/logs/cfgtoollogs/upgrade/auto/status/status.log

Checking the logs:

$ cat /home/oracle/autopatch/logs/cfgtoollogs/upgrade/auto/status/status.log
==========================================
          Autoupgrade Summary Report
==========================================
[Date]           Wed Jan 14 18:00:58 GMT 2026
[Number of Jobs] 1
==========================================
[Job ID] 102
==========================================
[DB Name]                orcl
[Version Before Upgrade] 23.26.0.0.0
[Version After Upgrade]  23.26.0.0.0
------------------------------------------
[Stage Name]    DBUPGRADE
[Status]        SUCCESS
[Start Time]    2026-01-14 17:31:10
[Duration]      0:20:08
[Log Directory] /home/oracle/autopatch/logs/orcl/102/dbupgrade
------------------------------------------
[Stage Name]    POSTCHECKS
[Status]        SUCCESS
[Start Time]    2026-01-14 17:51:25
[Duration]      0:00:06
[Log Directory] /home/oracle/autopatch/logs/orcl/102/postchecks
[Detail]        /home/oracle/autopatch/logs/orcl/102/postchecks/orcl_postupgrade.log
                Check passed and no manual intervention needed
------------------------------------------
[Stage Name]    POSTFIXUPS
[Status]        SUCCESS
[Start Time]    2026-01-14 17:51:32
[Duration]      0:09:25
[Log Directory] /home/oracle/autopatch/logs/orcl/102/postfixups
[Detail]        /home/oracle/autopatch/logs/orcl/102/postfixups/postfixups.html
------------------------------------------
[Stage Name]    SYSUPDATES
[Status]        SUCCESS
[Start Time]    2026-01-14 18:00:58
[Duration]      0:00:00
[Log Directory] /home/oracle/autopatch/logs/orcl/102/sysupdates
------------------------------------------
Summary:/home/oracle/autopatch/logs/orcl/102/dbupgrade/upg_summary.log

Our PDB was successfully upgraded. Finally, the last step is to check if PDB is up and running :

Oracle AI Database 26ai Enterprise Edition Release 23.26.0.0.0 - for Oracle Cloud and Engineered Systems Version 23.26.0.0.0

SQL> show pdbs

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

SQL>

That’s it! PDB successfully updated to 26ai.

Have you enjoyed? Please leave a comment or give a 👍!

Leave a Reply

Your email address will not be published.