Skip to main content

Migrate Oracle Database from Linux to Windows via RMAN

Migrate Oracle Database from Linux to Windows via RMAN

Introduction

In this article, we will migrate a database from Linux to Windows via RMAN, step by step. This can also be referred to as cross-platform restoration using RMAN. This is the second of two posts covering cross-platform RMAN restoration between Windows and Linux, the reverse direction, Windows to Linux, is covered in our companion guide.

Patch Consideration

Oracle ships separate patch bundles for Windows and Linux, so a Windows RU patch and a Linux RU patch at the "same" version number aren't actually the same binary patch. Because of this, always run datapatch -verbose after the restore to reconcile the database's patch registry with whatever RU is actually installed on the target Windows binary, this post walks through that reconciliation in Steps 14 through 20 below, including a Java class mismatch that needed its own separate fix.

Environment Used in this Guide

Source Database
Hostname devdb.oraeasy.com
OS OL 7
Database Name DEVDB
Database Version 19c (19.25)
Oracle Home /u01/app/oracle/product/19c/db_home
Datafile Location /u01/app/oracle/oradata/devdb

Target Database
Hostname oraeasy
OS Windows 11
Database Version 19c (19.27)
Oracle Home D:\app\oracle\product\19c\db_home1
Datafile Location D:\app\oracle\oradata\devdb

Now let's proceed with the migration activity, step by step.

Step 1: Take a Precheck at the Source

As before, create a test table first so there's a known dataset to validate after the migration. Also capture the database size, invalid object count, registry components, and, critically for this migration, the full patch history. This source database has already been through several RU cycles (19.3 to 19.25 to 19.27 to a rollback back to 19.25), so the patch registry snapshot here matters more than usual, since it's what determines what datapatch will try to reconcile once this database is running on the Windows binary.


SQL> show user
USER is "TEST"
SQL>
SQL> def
DEFINE _DATE           = "19-SEP-25" (CHAR)
DEFINE _CONNECT_IDENTIFIER = "devdbpdb" (CHAR)
DEFINE _USER           = "TEST" (CHAR)
DEFINE _PRIVILEGE      = "" (CHAR)
DEFINE _SQLPLUS_RELEASE = "1925000000" (CHAR)
DEFINE _EDITOR         = "Notepad" (CHAR)
DEFINE _O_VERSION      = "Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.25.0.0.0" (CHAR)
DEFINE _O_RELEASE      = "1925000000" (CHAR)
SQL>
SQL> CREATE TABLE COMPANY (EMP_ID INT,NAME VARCHAR(255), COMPANY VARCHAR(255));

Table created.

SQL> INSERT INTO COMPANY VALUES (101,'Yash','WIPRO');

1 row created.

SQL> INSERT INTO COMPANY VALUES (102,'Vijay','AIRTEL');

1 row created.

SQL> INSERT INTO COMPANY VALUES (103,'Riya','TCS');

1 row created.

SQL> commit;

Commit complete.

SQL> select count(*) from company;

  COUNT(*)
----------
         3

SQL> show pdbs

    CON_ID CON_NAME         OPEN MODE  RESTRICTED
---------- ---------------- ---------- ----------
         2 PDB$SEED          READ ONLY  NO
         3 DEVDBPDB          READ WRITE NO
         
SQL> SELECT name,db_unique_name,database_role,log_mode from v$database;

NAME      DB_UNIQUE_NAME    DATABASE_ROLE    LOG_MODE
--------- ----------------- ---------------- ------------
DEVDB      devdb              PRIMARY          ARCHIVELOG

SQL>
SQL> SELECT
    (SELECT SUM(bytes)/1024/1024/1024 FROM dba_data_files) +
    (SELECT NVL(SUM(bytes),0)/1024/1024/1024 FROM dba_temp_files) +
    (SELECT SUM(bytes)/1024/1024/1024 FROM sys.v_$log) +
    (SELECT SUM(block_size*file_size_blks)/1024/1024/1024 FROM v$controlfile) "Size in GB"
   FROM dual;

Size in GB
----------
3.60083008

SQL> COLUMN action_time FORMAT A20
SQL> COLUMN action FORMAT A10
SQL> COLUMN status FORMAT A10
SQL> COLUMN description FORMAT A60
SQL> SELECT patch_uid, patch_id, source_version, target_version, 
     action, status, action_time, description 
     FROM dba_registry_sqlpatch;

 PATCH_UID   PATCH_ID SOURCE_VERSION  TARGET_VERSION  ACTION     STATUS     ACTION_TIME          DESCRIPTION
---------- ---------- --------------- --------------- ---------- ---------- -------------------- ------------------------------------------------------------
  22862832   29517242 19.1.0.0.0      19.3.0.0.0      APPLY      SUCCESS    31-JUL-25 01.45.40.8 Database Release Update : 19.3.0.0.190416 (29517242)
                                                                            62490 PM

  25871884   36912597 19.3.0.0.0      19.25.0.0.0     APPLY      SUCCESS    02-SEP-25 12.35.34.6 Database Release Update : 19.25.0.0.241015 (36912597)
                                                                            01504 PM

  27123174   37642901 19.25.0.0.0     19.27.0.0.0     APPLY      SUCCESS    02-SEP-25 03.58.08.9 Database Release Update : 19.27.0.0.250415 (37642901)
                                                                            34050 PM

  27123174   37642901 19.27.0.0.0     19.25.0.0.0     ROLLBACK   SUCCESS    02-SEP-25 05.52.00.0 Database Release Update : 19.27.0.0.250415 (37642901)
                                                                            03677 PM
SQL> COLUMN comp_id FORMAT A10
SQL> COLUMN version FORMAT A11
SQL> COLUMN status FORMAT A10
SQL> COLUMN comp_name FORMAT A37
SQL> SELECT comp_id, comp_name, version, status FROM dba_registry;

COMP_ID    COMP_NAME                             VERSION     STATUS
---------- ------------------------------------- ----------- ----------
CATALOG    Oracle Database Catalog Views         19.0.0.0.0  VALID
CATPROC    Oracle Database Packages and Types    19.0.0.0.0  VALID
JAVAVM     JServer JAVA Virtual Machine          19.0.0.0.0  VALID
XML        Oracle XDK                            19.0.0.0.0  VALID
CATJAVA    Oracle Database Java Packages         19.0.0.0.0  VALID
APS        OLAP Analytic Workspace               19.0.0.0.0  VALID
RAC        Oracle Real Application Clusters      19.0.0.0.0  OPTION OFF
XDB        Oracle XML Database                   19.0.0.0.0  VALID
OWM        Oracle Workspace Manager              19.0.0.0.0  VALID
CONTEXT    Oracle Text                           19.0.0.0.0  VALID
ORDIM      Oracle Multimedia                     19.0.0.0.0  VALID
SDO        Spatial                               19.0.0.0.0  VALID
XOQ        Oracle OLAP API                       19.0.0.0.0  VALID
OLS        Oracle Label Security                 19.0.0.0.0  VALID
DV         Oracle Database Vault                 19.0.0.0.0  VALID

15 rows selected.

SQL> select count(*) from dba_objects where status='INVALID';

  COUNT(*)
----------
         0

SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ ONLY  NO
         3 DEVDBPDB                       READ WRITE NO
SQL>
SQL> alter session set container=DEVDBPDB;

Session altered.

SQL> SELECT
    (SELECT SUM(bytes)/1024/1024/1024 FROM dba_data_files) +
    (SELECT NVL(SUM(bytes),0)/1024/1024/1024 FROM dba_temp_files) +
    (SELECT SUM(bytes)/1024/1024/1024 FROM sys.v_$log) +
    (SELECT SUM(block_size*file_size_blks)/1024/1024/1024 FROM v$controlfile) "Size in GB"
    FROM dual; 

Size in GB
----------
2.49243164

SQL> SELECT comp_id, comp_name, version, status FROM dba_registry;

COMP_ID    COMP_NAME                             VERSION     STATUS
---------- ------------------------------------- ----------- ----------
CATALOG    Oracle Database Catalog Views         19.0.0.0.0  VALID
CATPROC    Oracle Database Packages and Types    19.0.0.0.0  VALID
JAVAVM     JServer JAVA Virtual Machine          19.0.0.0.0  VALID
XML        Oracle XDK                            19.0.0.0.0  VALID
CATJAVA    Oracle Database Java Packages         19.0.0.0.0  VALID
APS        OLAP Analytic Workspace               19.0.0.0.0  VALID
RAC        Oracle Real Application Clusters      19.0.0.0.0  OPTION OFF
XDB        Oracle XML Database                   19.0.0.0.0  VALID
OWM        Oracle Workspace Manager              19.0.0.0.0  VALID
CONTEXT    Oracle Text                           19.0.0.0.0  VALID
ORDIM      Oracle Multimedia                     19.0.0.0.0  VALID
SDO        Spatial                               19.0.0.0.0  VALID
XOQ        Oracle OLAP API                       19.0.0.0.0  VALID
OLS        Oracle Label Security                 19.0.0.0.0  VALID
DV         Oracle Database Vault                 19.0.0.0.0  VALID

15 rows selected.

SQL> select count(*) from dba_objects where status='INVALID';

  COUNT(*)
----------
         0

Step 2: Take a Full Database Backup Using RMAN

As with the Windows to Linux direction, back up the full database, all archived logs, and the current control file, all three are needed since the target's entire directory structure is different.


[oracle@devdb rman]$ rman target /

Recovery Manager: Release 19.0.0.0.0 - Production on Fri Sep 19 11:36:43 2025
Version 19.25.0.0.0

Copyright (c) 1982, 2019, Oracle and/or its affiliates.  All rights reserved.

connected to target database: DEVDB (DBID=1110684393)

RMAN> run
{
allocate channel ch1 device type disk;
allocate channel ch2 device type disk;
backup as compressed backupset database format '/home/oracle/rman/Fullback_%T_%U';
backup as compressed backupset archivelog all format '/home/oracle/rman/Archive_%T_%U';
backup current controlfile format '/home/oracle/rman/Controlback_%T_%U';
release channel ch1;
release channel ch2;
} run
2> {
3> allocate channel ch1 device type disk;
4> allocate channel ch2 device type disk;
5> backup as compressed backupset database format '/home/oracle/rman/Fullback_%T_%U';
6> backup as compressed backupset archivelog all format '/home/oracle/rman/Archive_%T_%U';
7> backup current controlfile format '/home/oracle/rman/Controlback_%T_%U';
8> release channel ch1;
9> release channel ch2;
10>
}
using target database control file instead of recovery catalog
allocated channel: ch1
channel ch1: SID=45 device type=DISK

allocated channel: ch2
channel ch2: SID=289 device type=DISK

Starting backup at 19-SEP-25
channel ch1: starting compressed full datafile backup set
channel ch1: specifying datafile(s) in backup set
input datafile file number=00001 name=/u01/app/oracle/oradata/devdb/system01.dbf
input datafile file number=00007 name=/u01/app/oracle/oradata/devdb/users01.dbf
channel ch1: starting piece 1 at 19-SEP-25
channel ch2: starting compressed full datafile backup set
channel ch2: specifying datafile(s) in backup set
input datafile file number=00003 name=/u01/app/oracle/oradata/devdb/sysaux01.dbf
input datafile file number=00004 name=/u01/app/oracle/oradata/devdb/undotbs01.dbf
channel ch2: starting piece 1 at 19-SEP-25
channel ch2: finished piece 1 at 19-SEP-25
piece handle=/home/oracle/rman/Fullback_20250919_0v442e34_31_1_1 tag=TAG20250919T113708 comment=NONE
channel ch2: backup set complete, elapsed time: 00:01:05
channel ch2: starting compressed full datafile backup set
channel ch2: specifying datafile(s) in backup set
input datafile file number=00009 name=/u01/app/oracle/oradata/devdb/devdbpdb/system01.dbf
input datafile file number=00011 name=/u01/app/oracle/oradata/devdb/devdbpdb/undotbs01.dbf
channel ch2: starting piece 1 at 19-SEP-25
channel ch1: finished piece 1 at 19-SEP-25
piece handle=/home/oracle/rman/Fullback_20250919_0u442e34_30_1_1 tag=TAG20250919T113708 comment=NONE
channel ch1: backup set complete, elapsed time: 00:02:21
channel ch1: starting compressed full datafile backup set
channel ch1: specifying datafile(s) in backup set
input datafile file number=00006 name=/u01/app/oracle/oradata/devdb/pdbseed/sysaux01.dbf
input datafile file number=00008 name=/u01/app/oracle/oradata/devdb/pdbseed/undotbs01.dbf
channel ch1: starting piece 1 at 19-SEP-25
channel ch2: finished piece 1 at 19-SEP-25
piece handle=/home/oracle/rman/Fullback_20250919_10442e56_32_1_1 tag=TAG20250919T113708 comment=NONE
channel ch2: backup set complete, elapsed time: 00:01:50
channel ch2: starting compressed full datafile backup set
channel ch2: specifying datafile(s) in backup set
input datafile file number=00005 name=/u01/app/oracle/oradata/devdb/pdbseed/system01.dbf
channel ch2: starting piece 1 at 19-SEP-25
channel ch1: finished piece 1 at 19-SEP-25
piece handle=/home/oracle/rman/Fullback_20250919_11442e7h_33_1_1 tag=TAG20250919T113708 comment=NONE
channel ch1: backup set complete, elapsed time: 00:00:44
channel ch1: starting compressed full datafile backup set
channel ch1: specifying datafile(s) in backup set
input datafile file number=00010 name=/u01/app/oracle/oradata/devdb/devdbpdb/sysaux01.dbf
input datafile file number=00012 name=/u01/app/oracle/oradata/devdb/devdbpdb/users01.dbf
channel ch1: starting piece 1 at 19-SEP-25
channel ch1: finished piece 1 at 19-SEP-25
piece handle=/home/oracle/rman/Fullback_20250919_13442e8t_35_1_1 tag=TAG20250919T113708 comment=NONE
channel ch1: backup set complete, elapsed time: 00:00:35
channel ch2: finished piece 1 at 19-SEP-25
piece handle=/home/oracle/rman/Fullback_20250919_12442e8l_34_1_1 tag=TAG20250919T113708 comment=NONE
channel ch2: backup set complete, elapsed time: 00:01:22
Finished backup at 19-SEP-25

Starting backup at 19-SEP-25
current log archived
channel ch1: starting compressed archived log backup set
channel ch1: specifying archived log(s) in backup set
input archived log thread=1 sequence=93 RECID=92 STAMP=1212233639
channel ch1: starting piece 1 at 19-SEP-25
channel ch2: starting compressed archived log backup set
channel ch2: specifying archived log(s) in backup set
input archived log thread=1 sequence=98 RECID=97 STAMP=1212233796
input archived log thread=1 sequence=99 RECID=98 STAMP=1212234089
channel ch2: starting piece 1 at 19-SEP-25
channel ch1: finished piece 1 at 19-SEP-25
piece handle=/home/oracle/rman/Archive_20250919_14442eb9_36_1_1 tag=TAG20250919T114129 comment=NONE
channel ch1: backup set complete, elapsed time: 00:00:01
channel ch1: starting compressed archived log backup set
channel ch1: specifying archived log(s) in backup set
input archived log thread=1 sequence=94 RECID=93 STAMP=1212233779
input archived log thread=1 sequence=95 RECID=94 STAMP=1212233784
input archived log thread=1 sequence=96 RECID=95 STAMP=1212233787
input archived log thread=1 sequence=97 RECID=96 STAMP=1212233793
channel ch1: starting piece 1 at 19-SEP-25
channel ch2: finished piece 1 at 19-SEP-25
piece handle=/home/oracle/rman/Archive_20250919_15442eb9_37_1_1 tag=TAG20250919T114129 comment=NONE
channel ch2: backup set complete, elapsed time: 00:00:01
channel ch1: finished piece 1 at 19-SEP-25
piece handle=/home/oracle/rman/Archive_20250919_16442eba_38_1_1 tag=TAG20250919T114129 comment=NONE
channel ch1: backup set complete, elapsed time: 00:00:01
Finished backup at 19-SEP-25

Starting backup at 19-SEP-25
channel ch1: starting full datafile backup set
channel ch1: specifying datafile(s) in backup set
including current control file in backup set
channel ch1: starting piece 1 at 19-SEP-25
channel ch1: finished piece 1 at 19-SEP-25
piece handle=/home/oracle/rman/Controlback_20250919_17442ebc_39_1_1 tag=TAG20250919T114132 comment=NONE
channel ch1: backup set complete, elapsed time: 00:00:01
Finished backup at 19-SEP-25

Starting Control File and SPFILE Autobackup at 19-SEP-25
piece handle=/u01/app/oracle/fast_recovery_area/devdb/DEVDB/autobackup/2025_09_19/o1_mf_s_1212234094_ndsx0q8k_.bkp comment=NONE
Finished Control File and SPFILE Autobackup at 19-SEP-25

released channel: ch1

released channel: ch2

RMAN>

Step 3: Create a Pfile


SQL> create pfile='/home/oracle/rman/LinPfile.ora' from spfile;

File created.

Step 4: Transfer the Backup to the Windows Machine Using WinSCP

Since the target is Windows this time, a GUI transfer tool like WinSCP is a convenient way to pull the backup pieces across from the Linux source rather than scripting the transfer from the command line.

Transferring RMAN backup pieces from Linux to Windows using WinSCP

Step 5: Modify the Pfile for Windows and Create Required Directories

Rewrite the pfile's Linux-style paths as Windows paths, then create the matching directory structure on the target, including separate folders for the PDB seed and the pluggable database.


C:\Windows\System32>cd E:\RMAN
C:\Windows\System32>E:
E:\RMAN>dir
 Volume in drive E is Personal
 Volume Serial Number is 340F-6A45

 Directory of E:\RMAN

19-09-2025  12:20              .
19-09-2025  11:41         2,061,312 Archive_20250919_14442eb9_36_1_1
19-09-2025  11:41           275,456 Archive_20250919_15442eb9_37_1_1
19-09-2025  11:41            77,312 Archive_20250919_16442eba_38_1_1
19-09-2025  11:41        19,103,744 Controlback_20250919_17442ebc_39_1_1
19-09-2025  11:39       665,616,384 Fullback_20250919_0u442e34_30_1_1
19-09-2025  11:38       186,482,688 Fullback_20250919_0v442e34_31_1_1
19-09-2025  11:39       451,624,960 Fullback_20250919_10442e56_32_1_1
19-09-2025  11:40       186,957,824 Fullback_20250919_11442e7h_33_1_1
19-09-2025  11:41       451,592,192 Fullback_20250919_12442e8l_34_1_1
19-09-2025  11:40       129,449,984 Fullback_20250919_13442e8t_35_1_1
19-09-2025  12:49             1,191 LinPfile.ora
              11 File(s)  2,093,243,047 bytes
               1 Dir(s)  132,913,451,008 bytes free

E:\RMAN>
E:\RMAN>type LinPfile.ora
devdb.__data_transfer_cache_size=0
devdb.__db_cache_size=184549376
devdb.__inmemory_ext_roarea=0
devdb.__inmemory_ext_rwarea=0
devdb.__java_pool_size=184549376
devdb.__large_pool_size=16777216
devdb.__oracle_base='/u01/app/oracle'#ORACLE_BASE set from environment
devdb.__pga_aggregate_target=402653184
devdb.__sga_target=1174405120
devdb.__shared_io_pool_size=67108864
devdb.__shared_pool_size=687865856
devdb.__streams_pool_size=16777216
devdb.__unified_pga_pool_size=0
*.audit_file_dest='D:\app\oracle\admin\devdb\adump'
*.audit_trail='db'
*.compatible='19.0.0'
*.control_files='D:\app\oracle\oradata\devdb\control01.ctl','D:\app\oracle\fast_recovery_area\devdb\control02.ctl'
*.db_block_size=8192
*.db_name='devdb'
*.db_recovery_file_dest='D:\app\oracle\fast_recovery_area\devdb'
*.db_recovery_file_dest_size=16106127360
*.diagnostic_dest='D:\app\oracle'
*.dispatchers='(PROTOCOL=TCP) (SERVICE=devdbXDB)'
*.enable_pluggable_database=true
*.log_archive_format='%t_%s_%r.dbf'
*.nls_language='AMERICAN'
*.nls_territory='AMERICA'
*.open_cursors=300
*.pga_aggregate_target=386924544
*.processes=300
*.remote_login_passwordfile='EXCLUSIVE'
*.sga_target=1160773632
*.undo_tablespace='UNDOTBS1'

E:\RMAN>
E:\RMAN>mkdir -p D:\app\oracle\admin\devdb\adump
E:\RMAN>mkdir -p D:\app\oracle\fast_recovery_area\devdb
E:\RMAN>mkdir -p D:\app\oracle\oradata\devdb
E:\RMAN>mkdir -p D:\app\oracle\oradata\devdb\PDBSEED
E:\RMAN>mkdir -p D:\app\oracle\oradata\devdb\ORCLPDB
E:\RMAN>

Step 6: Create the Windows Service for the Database

Unlike Linux, where an instance just needs an /etc/oratab entry, Windows manages Oracle instances as OS services. oradim registers the service and creates the instance metadata Windows needs to start and stop it, without this, sqlplus won't have anything to connect to yet.

oradim -NEW -SID "<sid>"


E:\RMAN>oradim -NEW -SID devdb 
Instance created.

Verify in services.msc:

Oracle Windows service created by oradim visible in Services.msc

Step 7: Set the Environment and Start the Database in Nomount State

On Windows, the instance name comes from the ORACLE_SID environment variable rather than a session utility like oraenv. RMAN needs a running instance to connect to before it can restore a control file, so start it in nomount mode using the edited pfile.


E:\RMAN>set ORACLE_SID=devdb
E:\RMAN>
E:\RMAN>sqlplus / as sysdba

SQL*Plus: Release 19.0.0.0.0 - Production on Fri Sep 19 13:02:35 2025
Version 19.27.0.0.0

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

Connected to an idle instance.

SQL> startup nomount pfile='E:\RMAN\LinPfile.ora';
ORACLE instance started.

Total System Global Area 1174402832 bytes
Fixed Size                  9312016 bytes
Variable Size             905969664 bytes
Database Buffers          251658240 bytes
Redo Buffers                7462912 bytes
SQL>
SQL> def
DEFINE _DATE           = "19-SEP-25" (CHAR)
DEFINE _CONNECT_IDENTIFIER = "devdb" (CHAR)
DEFINE _USER           = "SYS" (CHAR)
DEFINE _PRIVILEGE      = "AS SYSDBA" (CHAR)
DEFINE _SQLPLUS_RELEASE = "1927000000" (CHAR)
DEFINE _EDITOR         = "Notepad" (CHAR)
DEFINE _O_VERSION      = "Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.27.0.0.0" (CHAR)
DEFINE _O_RELEASE      = "1927000000" (CHAR)
SQL>

Step 8: Restore the Control File and Mount the Database


E:\RMAN>rman target /

Recovery Manager: Release 19.0.0.0.0 - Production on Fri Sep 19 13:06:31 2025
Version 19.27.0.0.0

Copyright (c) 1982, 2025, Oracle and/or its affiliates.  All rights reserved.

connected to target database: DEVDB (not mounted)

RMAN> restore controlfile from 'E:\RMAN\Controlback_20250919_17442ebc_39_1_1';
restore controlfile from 'E:\RMAN\Controlback_20250919_17442ebc_39_1_1';
Starting restore at 19-SEP-25
using target database control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=355 device type=DISK

channel ORA_DISK_1: restoring control file
channel ORA_DISK_1: restore complete, elapsed time: 00:00:07
output file name=D:\APP\ORACLE\ORADATA\DEVDB\CONTROL01.CTL
output file name=D:\APP\ORACLE\FAST_RECOVERY_AREA\DEVDB\CONTROL02.CTL
Finished restore at 19-SEP-25

RMAN> alter database mount;
alter database mount;
released channel: ORA_DISK_1
Statement processed

RMAN>
RMAN> report schema;
report schema;
Starting implicit crosscheck backup at 19-SEP-25
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=128 device type=DISK
Crosschecked 9 objects
Finished implicit crosscheck backup at 19-SEP-25

Starting implicit crosscheck copy at 19-SEP-25
using channel ORA_DISK_1
Crosschecked 2 objects
Finished implicit crosscheck copy at 19-SEP-25

searching for all files in the recovery area
cataloging files...
no files cataloged

RMAN-06139: warning: control file is not current for REPORT SCHEMA
Report of database schema for database with db_unique_name DEVDB

List of Permanent Datafiles
===========================
File Size(MB) Tablespace           RB segs Datafile Name
---- -------- -------------------- ------- ------------------------
1    0        SYSTEM               ***     /u01/app/oracle/oradata/devdb/system01.dbf
3    0        SYSAUX               ***     /u01/app/oracle/oradata/devdb/sysaux01.dbf
4    0        UNDOTBS1             ***     /u01/app/oracle/oradata/devdb/undotbs01.dbf
5    0        PDB$SEED:SYSTEM      ***     /u01/app/oracle/oradata/devdb/pdbseed/system01.dbf
6    0        PDB$SEED:SYSAUX      ***     /u01/app/oracle/oradata/devdb/pdbseed/sysaux01.dbf
7    0        USERS                ***     /u01/app/oracle/oradata/devdb/users01.dbf
8    0        PDB$SEED:UNDOTBS1    ***     /u01/app/oracle/oradata/devdb/pdbseed/undotbs01.dbf
9    0        DEVDBPDB:SYSTEM      ***     /u01/app/oracle/oradata/devdb/devdbpdb/system01.dbf
10   0        DEVDBPDB:SYSAUX      ***     /u01/app/oracle/oradata/devdb/devdbpdb/sysaux01.dbf
11   0        DEVDBPDB:UNDOTBS1    ***     /u01/app/oracle/oradata/devdb/devdbpdb/undotbs01.dbf
12   0        DEVDBPDB:USERS       ***     /u01/app/oracle/oradata/devdb/devdbpdb/users01.dbf

List of Temporary Files
=======================
File Size(MB) Tablespace           Maxsize(MB) Tempfile Name
---- -------- -------------------- ----------- --------------------
1    20       TEMP                 32767       /u01/app/oracle/oradata/devdb/temp01.dbf
2    64       PDB$SEED:TEMP        32767       /u01/app/oracle/oradata/devdb/pdbseed/temp012025-07-08_19-21-44-241-PM.dbf
3    64       DEVDBPDB:TEMP        32767       /u01/app/oracle/oradata/devdb/devdbpdb/temp01.dbf
RMAN>

Step 9: Catalog the Backup Files


RMAN>  catalog start with 'E:\RMAN';
 catalog start with 'E:\RMAN';
searching for all files that match the pattern E:\RMAN

List of Files Unknown to the Database
=====================================
File Name: E:\RMAN\ARCHIVE_20250919_14442EB9_36_1_1
File Name: E:\RMAN\ARCHIVE_20250919_15442EB9_37_1_1
File Name: E:\RMAN\ARCHIVE_20250919_16442EBA_38_1_1
File Name: E:\RMAN\CONTROLBACK_20250919_17442EBC_39_1_1
File Name: E:\RMAN\FULLBACK_20250919_0U442E34_30_1_1
File Name: E:\RMAN\FULLBACK_20250919_0V442E34_31_1_1
File Name: E:\RMAN\FULLBACK_20250919_10442E56_32_1_1
File Name: E:\RMAN\FULLBACK_20250919_11442E7H_33_1_1
File Name: E:\RMAN\FULLBACK_20250919_12442E8L_34_1_1
File Name: E:\RMAN\FULLBACK_20250919_13442E8T_35_1_1
File Name: E:\RMAN\LINPFILE.ORA

Do you really want to catalog the above files (enter YES or NO)? YES
cataloging files...
cataloging done

List of Cataloged Files
=======================
File Name: E:\RMAN\ARCHIVE_20250919_14442EB9_36_1_1
File Name: E:\RMAN\ARCHIVE_20250919_15442EB9_37_1_1
File Name: E:\RMAN\ARCHIVE_20250919_16442EBA_38_1_1
File Name: E:\RMAN\CONTROLBACK_20250919_17442EBC_39_1_1
File Name: E:\RMAN\FULLBACK_20250919_0U442E34_30_1_1
File Name: E:\RMAN\FULLBACK_20250919_0V442E34_31_1_1
File Name: E:\RMAN\FULLBACK_20250919_10442E56_32_1_1
File Name: E:\RMAN\FULLBACK_20250919_11442E7H_33_1_1
File Name: E:\RMAN\FULLBACK_20250919_12442E8L_34_1_1
File Name: E:\RMAN\FULLBACK_20250919_13442E8T_35_1_1

List of Files Which Were Not Cataloged
=======================================
File Name: E:\RMAN\LINPFILE.ORA
  RMAN-07517: Reason: The file header is corrupted
RMAN>

Step 10: Execute the Restoration Script

As before, SET NEWNAME redirects every datafile and tempfile to its Windows path, then restore database, switch, and recover database bring the data across. This time recovery hits an ORA-00600 internal error applying a specific redo change to a SYSAUX block, rather than simply running out of archived logs. This kind of block-level error during cross-platform recovery is worth taking seriously rather than assuming it's benign, in this environment the subsequent steps proceeded successfully, but always validate thoroughly (as the closing note on this post recommends) before relying on this outcome for a production migration.


RMAN>RUN
{
ALLOCATE CHANNEL c1 DEVICE TYPE disk;
ALLOCATE CHANNEL c2 DEVICE TYPE disk;
set newname for datafile 1  to 'D:\app\oracle\oradata\devdb\SYSTEM01.DBF';
set newname for datafile 3  to 'D:\app\oracle\oradata\devdb\SYSAUX01.DBF';
set newname for datafile 4  to 'D:\app\oracle\oradata\devdb\UNDOTBS01.DBF';
set newname for datafile 5  to 'D:\app\oracle\oradata\devdb\PDBSEED\SYSTEM01.DBF';
set newname for datafile 6  to 'D:\app\oracle\oradata\devdb\PDBSEED\SYSAUX01.DBF';
set newname for datafile 7  to 'D:\app\oracle\oradata\devdb\USERS01.DBF';
set newname for datafile 8  to 'D:\app\oracle\oradata\devdb\PDBSEED\UNDOTBS01.DBF';
set newname for datafile 9  to 'D:\app\oracle\oradata\devdb\ORCLPDB\SYSTEM01.DBF';
set newname for datafile 10 to 'D:\app\oracle\oradata\devdb\ORCLPDB\SYSAUX01.DBF';
set newname for datafile 11 to 'D:\app\oracle\oradata\devdb\ORCLPDB\UNDOTBS01.DBF';
set newname for datafile 12 to 'D:\app\oracle\oradata\devdb\ORCLPDB\USERS01.DBF';
set newname for tempfile  1 to 'D:\app\oracle\oradata\devdb\TEMP01.DBF';
set newname for tempfile  2 to 'D:\app\oracle\oradata\devdb\PDBSEED\TEMP01.DBF';
set newname for tempfile  3 to 'D:\app\oracle\oradata\devdb\ORCLPDB\TEMP01.DBF';
restore database;
switch datafile all;
switch tempfile all;
recover database;
release channel c1;
release channel c2;
}

RMAN> 
   RUN
2> {
3> ALLOCATE CHANNEL c1 DEVICE TYPE disk;
4> ALLOCATE CHANNEL c2 DEVICE TYPE disk;
5> set newname for datafile 1  to 'D:\app\oracle\oradata\devdb\SYSTEM01.DBF';
6> set newname for datafile 3  to 'D:\app\oracle\oradata\devdb\SYSAUX01.DBF';
7> set newname for datafile 4  to 'D:\app\oracle\oradata\devdb\UNDOTBS01.DBF';
8> set newname for datafile 5  to 'D:\app\oracle\oradata\devdb\PDBSEED\SYSTEM01.DBF';
9> set newname for datafile 6  to 'D:\app\oracle\oradata\devdb\PDBSEED\SYSAUX01.DBF';
10> set newname for datafile 7  to 'D:\app\oracle\oradata\devdb\USERS01.DBF';
11> set newname for datafile 8  to 'D:\app\oracle\oradata\devdb\PDBSEED\UNDOTBS01.DBF';
12> set newname for datafile 9  to 'D:\app\oracle\oradata\devdb\ORCLPDB\SYSTEM01.DBF';
13> set newname for datafile 10 to 'D:\app\oracle\oradata\devdb\ORCLPDB\SYSAUX01.DBF';
14> set newname for datafile 11 to 'D:\app\oracle\oradata\devdb\ORCLPDB\UNDOTBS01.DBF';
15> set newname for datafile 12 to 'D:\app\oracle\oradata\devdb\ORCLPDB\USERS01.DBF';
16> set newname for tempfile  1 to 'D:\app\oracle\oradata\devdb\TEMP01.DBF';
17> set newname for tempfile  2 to 'D:\app\oracle\oradata\devdb\PDBSEED\TEMP01.DBF';
18> set newname for tempfile  3 to 'D:\app\oracle\oradata\devdb\ORCLPDB\TEMP01.DBF';
19> restore database;
20> switch datafile all;
21> switch tempfile all;
22> recover database;
23> release channel c1;
24> release channel c2;
25> }
allocated channel: c1
channel c1: SID=128 device type=DISK

allocated channel: c2
channel c2: SID=247 device type=DISK

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

Starting restore at 19-SEP-25

channel c1: starting datafile backup set restore
channel c1: specifying datafile(s) to restore from backup set
channel c1: restoring datafile 00001 to D:\app\oracle\oradata\devdb\SYSTEM01.DBF
channel c1: restoring datafile 00007 to D:\app\oracle\oradata\devdb\USERS01.DBF
channel c1: reading from backup piece E:\RMAN\FULLBACK_20250919_0U442E34_30_1_1
channel c2: starting datafile backup set restore
channel c2: specifying datafile(s) to restore from backup set
channel c2: restoring datafile 00003 to D:\app\oracle\oradata\devdb\SYSAUX01.DBF
channel c2: restoring datafile 00004 to D:\app\oracle\oradata\devdb\UNDOTBS01.DBF
channel c2: reading from backup piece E:\RMAN\FULLBACK_20250919_0V442E34_31_1_1
channel c2: piece handle=E:\RMAN\FULLBACK_20250919_0V442E34_31_1_1 tag=TAG20250919T113708
channel c2: restored backup piece 1
channel c2: restore complete, elapsed time: 00:01:55
channel c2: starting datafile backup set restore
channel c2: specifying datafile(s) to restore from backup set
channel c2: restoring datafile 00009 to D:\app\oracle\oradata\devdb\ORCLPDB\SYSTEM01.DBF
channel c2: restoring datafile 00011 to D:\app\oracle\oradata\devdb\ORCLPDB\UNDOTBS01.DBF
channel c2: reading from backup piece E:\RMAN\FULLBACK_20250919_10442E56_32_1_1
channel c1: piece handle=E:\RMAN\FULLBACK_20250919_0U442E34_30_1_1 tag=TAG20250919T113708
channel c1: restored backup piece 1
channel c1: restore complete, elapsed time: 00:03:00
channel c1: starting datafile backup set restore
channel c1: specifying datafile(s) to restore from backup set
channel c1: restoring datafile 00005 to D:\app\oracle\oradata\devdb\PDBSEED\SYSTEM01.DBF
channel c1: reading from backup piece E:\RMAN\FULLBACK_20250919_12442E8L_34_1_1
channel c2: piece handle=E:\RMAN\FULLBACK_20250919_10442E56_32_1_1 tag=TAG20250919T113708
channel c2: restored backup piece 1
channel c2: restore complete, elapsed time: 00:01:31
channel c2: starting datafile backup set restore
channel c2: specifying datafile(s) to restore from backup set
channel c2: restoring datafile 00006 to D:\app\oracle\oradata\devdb\PDBSEED\SYSAUX01.DBF
channel c2: restoring datafile 00008 to D:\app\oracle\oradata\devdb\PDBSEED\UNDOTBS01.DBF
channel c2: reading from backup piece E:\RMAN\FULLBACK_20250919_11442E7H_33_1_1
channel c1: piece handle=E:\RMAN\FULLBACK_20250919_12442E8L_34_1_1 tag=TAG20250919T113708
channel c1: restored backup piece 1
channel c1: restore complete, elapsed time: 00:01:21
channel c1: starting datafile backup set restore
channel c1: specifying datafile(s) to restore from backup set
channel c1: restoring datafile 00010 to D:\app\oracle\oradata\devdb\ORCLPDB\SYSAUX01.DBF
channel c1: restoring datafile 00012 to D:\app\oracle\oradata\devdb\ORCLPDB\USERS01.DBF
channel c1: reading from backup piece E:\RMAN\FULLBACK_20250919_13442E8T_35_1_1
channel c2: piece handle=E:\RMAN\FULLBACK_20250919_11442E7H_33_1_1 tag=TAG20250919T113708
channel c2: restored backup piece 1
channel c2: restore complete, elapsed time: 00:00:56
channel c1: piece handle=E:\RMAN\FULLBACK_20250919_13442E8T_35_1_1 tag=TAG20250919T113708
channel c1: restored backup piece 1
channel c1: restore complete, elapsed time: 00:00:35
Finished restore at 19-SEP-25

datafile 1 switched to datafile copy
input datafile copy RECID=18 STAMP=1212240236 file name=D:\APP\ORACLE\ORADATA\DEVDB\SYSTEM01.DBF
datafile 3 switched to datafile copy
input datafile copy RECID=19 STAMP=1212240236 file name=D:\APP\ORACLE\ORADATA\DEVDB\SYSAUX01.DBF
datafile 4 switched to datafile copy
input datafile copy RECID=20 STAMP=1212240236 file name=D:\APP\ORACLE\ORADATA\DEVDB\UNDOTBS01.DBF
datafile 5 switched to datafile copy
input datafile copy RECID=21 STAMP=1212240237 file name=D:\APP\ORACLE\ORADATA\DEVDB\PDBSEED\SYSTEM01.DBF
datafile 6 switched to datafile copy
input datafile copy RECID=22 STAMP=1212240237 file name=D:\APP\ORACLE\ORADATA\DEVDB\PDBSEED\SYSAUX01.DBF
datafile 7 switched to datafile copy
input datafile copy RECID=23 STAMP=1212240237 file name=D:\APP\ORACLE\ORADATA\DEVDB\USERS01.DBF
datafile 8 switched to datafile copy
input datafile copy RECID=24 STAMP=1212240237 file name=D:\APP\ORACLE\ORADATA\DEVDB\PDBSEED\UNDOTBS01.DBF
datafile 9 switched to datafile copy
input datafile copy RECID=25 STAMP=1212240238 file name=D:\APP\ORACLE\ORADATA\DEVDB\ORCLPDB\SYSTEM01.DBF
datafile 10 switched to datafile copy
input datafile copy RECID=26 STAMP=1212240238 file name=D:\APP\ORACLE\ORADATA\DEVDB\ORCLPDB\SYSAUX01.DBF
datafile 11 switched to datafile copy
input datafile copy RECID=27 STAMP=1212240238 file name=D:\APP\ORACLE\ORADATA\DEVDB\ORCLPDB\UNDOTBS01.DBF
datafile 12 switched to datafile copy
input datafile copy RECID=28 STAMP=1212240238 file name=D:\APP\ORACLE\ORADATA\DEVDB\ORCLPDB\USERS01.DBF

renamed tempfile 1 to D:\app\oracle\oradata\devdb\TEMP01.DBF in control file
renamed tempfile 2 to D:\app\oracle\oradata\devdb\PDBSEED\TEMP01.DBF in control file
renamed tempfile 3 to D:\app\oracle\oradata\devdb\ORCLPDB\TEMP01.DBF in control file

Starting recover at 19-SEP-25

starting media recovery

channel c1: starting archived log restore to default destination
channel c1: restoring archived log
archived log thread=1 sequence=99
channel c1: reading from backup piece E:\RMAN\ARCHIVE_20250919_15442EB9_37_1_1
channel c1: piece handle=E:\RMAN\ARCHIVE_20250919_15442EB9_37_1_1 tag=TAG20250919T114129
channel c1: restored backup piece 1
channel c1: restore complete, elapsed time: 00:00:01
archived log file name=D:\APP\ORACLE\FAST_RECOVERY_AREA\DEVDB\DEVDB\ARCHIVELOG\2025_09_19\O1_MF_1_99_NDT30Z5F_.ARC thread=1 sequence=99
RMAN Command Id : 2025-09-19T13:06:31
RMAN Command Id : 2025-09-19T13:06:31
RMAN Command Id : 2025-09-19T13:06:31
released channel: c1
released channel: c2
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 09/19/2025 13:24:19
RMAN-11003: failure during parse/execution of SQL statement: alter database recover logfile 'D:\APP\ORACLE\FAST_RECOVERY_AREA\DEVDB\DEVDB\ARCHIVELOG\2025_09_19\O1_MF_1_99_NDT30Z5F_.ARC'
ORA-10562: Error occurred while applying redo to data block (file# 3, block# 111892)
ORA-10564: tablespace SYSAUX
ORA-01110: data file 3: 'D:\APP\ORACLE\ORADATA\DEVDB\SYSAUX01.DBF'
ORA-10561: block type 'TRANSACTION MANAGED DATA BLOCK', data object# 406
ORA-00607: Internal error occurred while making a change to a data block
ORA-00600: internal error code, arguments: [ktbair2: illegal  inheritance], [], [], [], [], [], [], [], [], [], [], []

RMAN>

Step 11: Try to Open the Database Despite the Error

Even with the recovery error above, the restore itself completed and the datafiles are in place, so it's worth attempting to open the database before assuming the migration has failed outright.


SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       MOUNTED
         3 DEVDBPDB                       MOUNTED
SQL>
SQL> alter database open;
alter database open
*
ERROR at line 1:
ORA-01589: must use RESETLOGS or NORESETLOGS option for database open

SQL> alter database open RESETLOGS;
alter database open RESETLOGS
*
ERROR at line 1:
ORA-00344: unable to re-create online log
'/u01/app/oracle/oradata/devdb/redo01.log'
ORA-27040: file create error, unable to create file
OSD-04002: unable to open file
O/S-Error: (OS 3) The system cannot find the path specified.

Step 12: Rename the Redo Log Files

The control file still points at the source Linux redo log paths, which don't exist on Windows. Rename each member to its Windows path, then retry the open.


SQL> select member from v$logfile;

MEMBER
------------------------------------------------------------
/u01/app/oracle/oradata/devdb/redo03.log
/u01/app/oracle/oradata/devdb/redo02.log
/u01/app/oracle/oradata/devdb/redo01.log

SQL> alter database rename file '/u01/app/oracle/oradata/devdb/redo01.log' to 'D:\app\oracle\oradata\devdb\redo01.log';

Database altered.

SQL> alter database rename file '/u01/app/oracle/oradata/devdb/redo02.log' to 'D:\app\oracle\oradata\devdb\redo02.log';

Database altered.

SQL> alter database rename file '/u01/app/oracle/oradata/devdb/redo03.log' to 'D:\app\oracle\oradata\devdb\redo03.log';

Database altered.

SQL> select member from v$logfile;

MEMBER
------------------------------------------------------------
D:\APP\ORACLE\ORADATA\DEVDB\REDO03.LOG
D:\APP\ORACLE\ORADATA\DEVDB\REDO02.LOG
D:\APP\ORACLE\ORADATA\DEVDB\REDO01.LOG

SQL>
SQL> alter database open RESETLOGS;
alter database open RESETLOGS
*
ERROR at line 1:
ORA-00392: log 1 of thread 1 is being cleared, operation not allowed
ORA-00312: online log 1 thread 1: 'D:\APP\ORACLE\ORADATA\DEVDB\REDO01.LOG'

SQL> ALTER DATABASE CLEAR UNARCHIVED LOGFILE GROUP 1;

Database altered.

SQL> alter database open RESETLOGS;

SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ ONLY  NO
         3 DEVDBPDB                       READ WRITE NO
SQL>

Step 13: Create an spfile and Bounce the Database

With the database open, persist a proper spfile instead of relying on the temporary pfile going forward, then confirm the patch registry carried over from Linux, this is the full history datapatch will need to reconcile in the next few steps.


SQL> create spfile from pfile='E:\RMAN\LinPfile.ora';

File created.

SQL> shut immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL>
SQL> startup
ORACLE instance started.

Total System Global Area 1174402832 bytes
Fixed Size                  9312016 bytes
Variable Size             905969664 bytes
Database Buffers          251658240 bytes
Redo Buffers                7462912 bytes
Database mounted.
Database opened.
SQL> show pdbs

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

SQL> COLUMN action_time FORMAT A20
SQL> COLUMN action FORMAT A10
SQL> COLUMN status FORMAT A10
SQL> COLUMN description FORMAT A60
SQL> SELECT patch_uid, patch_id, source_version, target_version,
     action, status, action_time, description
     FROM dba_registry_sqlpatch;
  
   PATCH_UID   PATCH_ID SOURCE_VERSION  TARGET_VERSION  ACTION     STATUS     ACTION_TIME          DESCRIPTION
---------- ---------- --------------- --------------- ---------- ---------- -------------------- ------------------------------------------------------------
  22862832   29517242 19.1.0.0.0      19.3.0.0.0      APPLY      SUCCESS    31-JUL-25 01.45.40.8 Database Release Update : 19.3.0.0.190416 (29517242)
                                                                            62490 PM

  25871884   36912597 19.3.0.0.0      19.25.0.0.0     APPLY      SUCCESS    02-SEP-25 12.35.34.6 Database Release Update : 19.25.0.0.241015 (36912597)
                                                                            01504 PM

  27123174   37642901 19.25.0.0.0     19.27.0.0.0     APPLY      SUCCESS    02-SEP-25 03.58.08.9 Database Release Update : 19.27.0.0.250415 (37642901)
                                                                            34050 PM

  27123174   37642901 19.27.0.0.0     19.25.0.0.0     ROLLBACK   SUCCESS    02-SEP-25 05.52.00.0 Database Release Update : 19.27.0.0.250415 (37642901)
                                                                            03677 PM

Step 14: Run datapatch Verbose

The binary here is on Windows RU 250422102456 (19.27), ahead of what the registry currently reflects (19.25 after the earlier rollback), so this time datapatch needs to Apply forward rather than roll back. It fails the same way as the other direction, though, with an ORA-29548 Java class mismatch.


D:\app\oracle\product\19c\db_home1\OPatch>datapatch -verbose
SQL Patching tool version 19.27.0.0.0 Production on Fri Sep 19 13:46:45 2025
Copyright (c) 2012, 2025, Oracle.  All rights reserved.

Log file for this invocation: D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\sqlpatch_3612_2025_09_19_13_46_45\sqlpatch_invocation.log

Connecting to database...OK
Gathering database info...done

Note:  Datapatch will only apply or rollback SQL fixes for PDBs
       that are in an open state, no patches will be applied to closed PDBs.
       Please refer to Note: Datapatch: Database 12c Post Patch SQL Automation
       (Doc ID 1585822.1)

Bootstrapping registry and package to current versions...done
Determining current state...done

Current state of interim SQL patches:
  No interim patches found

Current state of release update SQL patches:
  Binary registry:
    19.27.0.0.0 Release_Update 250422102456: Installed
  PDB CDB$ROOT:
    Rolled back to 19.25.0.0.0 Release_Update 241010184253 successfully on 02-SEP-25 05.52.00.003677 PM
  PDB DEVDBPDB:
    Rolled back to 19.25.0.0.0 Release_Update 241010184253 successfully on 02-SEP-25 05.58.12.818460 PM
  PDB PDB$SEED:
    Rolled back to 19.25.0.0.0 Release_Update 241010184253 successfully on 02-SEP-25 05.58.26.368952 PM

Adding patches to installation queue and performing prereq checks...done
Installation queue:
  For the following PDBs: CDB$ROOT PDB$SEED DEVDBPDB
    No interim patches need to be rolled back
    Patch 37532350 (Windows Database Bundle Patch : 19.27.0.0.250415 (37532350)):
      Apply from 19.25.0.0.0 Release_Update 241010184253 to 19.27.0.0.0 Release_Update 250422102456
    No interim patches need to be applied

Installing patches...
Patch installation complete.  Total patches installed: 3

Validating logfiles...done
Patch 37532350 apply (pdb CDB$ROOT): WITH ERRORS
  logfile: D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\37532350\26102912/37532350_apply_DEVDB_CDBROOT_2025Sep19_13_55_09.log (errors)
  -> Error at line 91447: script md/admin/catsem.sql
      - ORA-29548: Java system class reported: release of Java system classes in the
      - database (19.0.0.0.0 1.8) does not match that of the oracle executable
      - (19.3.0.0.0 1.8)
      - ORA-06512: at "SYS.DBMS_JAVA", line 587
      - ORA-06512: at line 1
Patch 37532350 apply (pdb PDB$SEED): WITH ERRORS
  logfile: D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\37532350\26102912/37532350_apply_DEVDB_PDBSEED_2025Sep19_14_04_32.log (errors)
  -> Error at line 91447: script md/admin/catsem.sql
      - ORA-29548: Java system class reported: release of Java system classes in the
      - database (19.0.0.0.0 1.8) does not match that of the oracle executable
      - (19.3.0.0.0 1.8)
      - ORA-06512: at "SYS.DBMS_JAVA", line 587
      - ORA-06512: at line 1
Patch 37532350 apply (pdb DEVDBPDB): WITH ERRORS
  logfile: D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\37532350\26102912/37532350_apply_DEVDB_DEVDBPDB_2025Sep19_14_04_32.log (errors)
  -> Error at line 91447: script md/admin/catsem.sql
      - ORA-29548: Java system class reported: release of Java system classes in the
      - database (19.0.0.0.0 1.8) does not match that of the oracle executable
      - (19.3.0.0.0 1.8)
      - ORA-06512: at "SYS.DBMS_JAVA", line 587
      - ORA-06512: at line 1

Adding patches to retry installation queue...done
Retry installation queue:
  For the following PDBs: CDB$ROOT PDB$SEED DEVDBPDB
    No interim patches need to be rolled back
    Patch 37532350 (Windows Database Bundle Patch : 19.27.0.0.250415 (37532350)):
      Apply from 19.25.0.0.0 Release_Update 241010184253 to 19.27.0.0.0 Release_Update 250422102456
    No interim patches need to be applied

Installing patches...
Patch installation complete.  Total patches installed: 3

Validating logfiles...done
Patch 37532350 apply (pdb CDB$ROOT): WITH ERRORS
  logfile: D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\37532350\26102912/37532350_apply_DEVDB_CDBROOT_2025Sep19_14_16_46.log (errors)
  -> Error at line 91457: script md/admin/catsem.sql
      - ORA-29548: Java system class reported: release of Java system classes in the
      - database (19.0.0.0.0 1.8) does not match that of the oracle executable
      - (19.3.0.0.0 1.8)
      - ORA-06512: at "SYS.DBMS_JAVA", line 587
      - ORA-06512: at line 1
Patch 37532350 apply (pdb PDB$SEED): WITH ERRORS
  logfile: D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\37532350\26102912/37532350_apply_DEVDB_PDBSEED_2025Sep19_14_26_24.log (errors)
  -> Error at line 91457: script md/admin/catsem.sql
      - ORA-29548: Java system class reported: release of Java system classes in the
      - database (19.0.0.0.0 1.8) does not match that of the oracle executable
      - (19.3.0.0.0 1.8)
      - ORA-06512: at "SYS.DBMS_JAVA", line 587
      - ORA-06512: at line 1
Patch 37532350 apply (pdb DEVDBPDB): WITH ERRORS
  logfile: D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\37532350\26102912/37532350_apply_DEVDB_DEVDBPDB_2025Sep19_14_26_23.log (errors)
  -> Error at line 91457: script md/admin/catsem.sql
      - ORA-29548: Java system class reported: release of Java system classes in the
      - database (19.0.0.0.0 1.8) does not match that of the oracle executable
      - (19.3.0.0.0 1.8)
      - ORA-06512: at "SYS.DBMS_JAVA", line 587
      - ORA-06512: at line 1

Please refer to MOS Note 1609718.1 and/or the invocation log
D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\sqlpatch_3612_2025_09_19_13_46_45\sqlpatch_invocation.log
for information on how to resolve the above errors.

SQL Patching tool complete on Fri Sep 19 14:35:14 2025

Step 15: Bounce the Database, Then Run update_javavm_db.sql

The failed datapatch attempt above already left both PDBs in a restricted state, so bounce the database first this time before applying the Java class fix, then run update_javavm_db.sql once at the CDB root and once inside the PDB, since each container tracks its Java system classes separately.


SQL> shut immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup
ORACLE instance started.

Total System Global Area 1174402832 bytes
Fixed Size                  9312016 bytes
Variable Size             872415232 bytes
Database Buffers          285212672 bytes
Redo Buffers                7462912 bytes
Database mounted.
Database opened.
SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ ONLY  YES
         3 DEVDBPDB                       READ WRITE YES
SQL>

For CDB:

SQL>  @?/javavm/install/update_javavm_db.sql
SQL> SET FEEDBACK 1
SQL> SET NUMWIDTH 10
SQL> SET LINESIZE 80
SQL> SET TRIMSPOOL ON
SQL> SET TAB OFF
SQL> SET PAGESIZE 100
SQL>
SQL> alter session set "_ORACLE_SCRIPT"=true;

Session altered.

SQL>
SQL> -- If Java is installed, do CJS.
SQL>
SQL> -- If CJS can deal with the SROs inconsistent with the new JDK,
SQL> -- the drop_sros() call here can be removed.
SQL> call initjvmaux.drop_sros();

Call completed.

SQL>
SQL> create or replace java system;
  2  /

Java created.

SQL>
SQL> update dependency$
  2    set p_timestamp=(select stime from obj$ where obj#=p_obj#)
  3    where (select stime from obj$ where obj#=p_obj#)!=p_timestamp and
  4          (select type# from obj$ where obj#=p_obj#)=29  and
  5          (select owner# from obj$ where obj#=p_obj#)=0;

0 rows updated.

SQL>
SQL> commit;

Commit complete.

SQL>
SQL> alter session set "_ORACLE_SCRIPT"=false;

Session altered.

SQL>

For PDB:

SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ WRITE YES
         3 DEVDBPDB                       READ WRITE YES
SQL>
SQL> alter session set container=DEVDBPDB;

Session altered.

SQL>
SQL>
SQL>  @?/javavm/install/update_javavm_db.sql
SQL> Rem
SQL> Rem $Header: javavm/install/update_javavm_db.sql /main/6 2017/07/03 21:56:55 stanaya Exp $
SQL> Rem
SQL> Rem update_javavm_db.sql
SQL> Rem
SQL> Rem Copyright (c) 2011, 2017, Oracle and/or its affiliates.
SQL> Rem All rights reserved.
SQL> Rem
SQL> Rem    NAME
SQL> Rem      update_javavm_db.sql - update JDK in the database
SQL> Rem
SQL> Rem    DESCRIPTION
SQL> Rem
SQL> Rem    NOTES
SQL> Rem      To be run as SYS.
SQL> Rem
SQL> Rem    BEGIN SQL_FILE_METADATA
SQL> Rem    SQL_SOURCE_FILE: javavm/install/update_javavm_db.sql
SQL> Rem    SQL_SHIPPED_FILE: javavm/install/update_javavm_db.sql
SQL> Rem    SQL_PHASE: UTILITY
SQL> Rem    SQL_STARTUP_MODE: NORMAL
SQL> Rem    SQL_IGNORABLE_ERRORS: NONE
SQL> Rem    END SQL_FILE_METADATA
SQL> Rem
SQL> Rem    MODIFIED   (MM/DD/YY)
SQL> Rem    nneeluru    01/22/14 - Fix ORA-65023; Also set/unset _ORACLE_SCRIPT
SQL> Rem    nneeluru    09/13/12 - Fix timestamps
SQL> Rem    nneeluru    07/04/12 - Drop SROs
SQL> Rem    nneeluru    10/03/11 - Script to be run in the database to switch JDK
SQL> Rem    nneeluru    10/03/11 - Created
SQL> Rem
SQL>
SQL> SET ECHO ON
SQL> SET FEEDBACK 1
SQL> SET NUMWIDTH 10
SQL> SET LINESIZE 80
SQL> SET TRIMSPOOL ON
SQL> SET TAB OFF
SQL> SET PAGESIZE 100
SQL>
SQL> alter session set "_ORACLE_SCRIPT"=true;

Session altered.

SQL>
SQL> -- If Java is installed, do CJS.
SQL>
SQL> -- If CJS can deal with the SROs inconsistent with the new JDK,
SQL> -- the drop_sros() call here can be removed.
SQL> call initjvmaux.drop_sros();

Call completed.

SQL>
SQL> create or replace java system;
  2  /

Java created.

SQL>
SQL> update dependency$
  2    set p_timestamp=(select stime from obj$ where obj#=p_obj#)
  3    where (select stime from obj$ where obj#=p_obj#)!=p_timestamp and
  4          (select type# from obj$ where obj#=p_obj#)=29  and
  5          (select owner# from obj$ where obj#=p_obj#)=0;

0 rows updated.

SQL>
SQL> commit;

Commit complete.

SQL>
SQL> alter session set "_ORACLE_SCRIPT"=false;

Session altered.

SQL>

Step 16: Run datapatch Verbose Again

CDB$ROOT and DEVDBPDB now apply successfully, but PDB$SEED still hits the same Java error. Same as the other direction, PDB$SEED stays read-only by default and wasn't included in the fix above, it needs the same treatment applied from inside its own container.


D:\app\oracle\product\19c\db_home1\OPatch>datapatch -verbose
SQL Patching tool version 19.27.0.0.0 Production on Fri Sep 19 16:18:03 2025
Copyright (c) 2012, 2025, Oracle.  All rights reserved.

Log file for this invocation: D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\sqlpatch_10384_2025_09_19_16_18_03\sqlpatch_invocation.log

Connecting to database...OK
Gathering database info...done

Note:  Datapatch will only apply or rollback SQL fixes for PDBs
       that are in an open state, no patches will be applied to closed PDBs.
       Please refer to Note: Datapatch: Database 12c Post Patch SQL Automation
       (Doc ID 1585822.1)

Bootstrapping registry and package to current versions...done
Determining current state...done

Current state of interim SQL patches:
  No interim patches found

Current state of release update SQL patches:
  Binary registry:
    19.27.0.0.0 Release_Update 250422102456: Installed
  PDB CDB$ROOT:
    Applied 19.27.0.0.0 Release_Update 250422102456 with errors on 19-SEP-25 02.25.23.986000 PM
  PDB DEVDBPDB:
    Applied 19.27.0.0.0 Release_Update 250422102456 with errors on 19-SEP-25 02.33.33.013000 PM
  PDB PDB$SEED:
    Applied 19.27.0.0.0 Release_Update 250422102456 with errors on 19-SEP-25 02.33.33.033000 PM

Adding patches to installation queue and performing prereq checks...done
Installation queue:
  For the following PDBs: CDB$ROOT PDB$SEED DEVDBPDB
    No interim patches need to be rolled back
    Patch 37532350 (Windows Database Bundle Patch : 19.27.0.0.250415 (37532350)):
      Apply from 19.25.0.0.0 Release_Update 241010184253 to 19.27.0.0.0 Release_Update 250422102456
    No interim patches need to be applied

Installing patches...
Patch installation complete.  Total patches installed: 3

Validating logfiles...done
Patch 37532350 apply (pdb CDB$ROOT): SUCCESS
  logfile: D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\37532350\26102912/37532350_apply_DEVDB_CDBROOT_2025Sep19_16_22_34.log (no errors)
Patch 37532350 apply (pdb PDB$SEED): WITH ERRORS
  logfile: D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\37532350\26102912/37532350_apply_DEVDB_PDBSEED_2025Sep19_16_29_06.log (errors)
  -> Error at line 91457: script md/admin/catsem.sql
      - ORA-29548: Java system class reported: release of Java system classes in the
      - database (19.0.0.0.0 1.8) does not match that of the oracle executable
      - (19.3.0.0.0 1.8)
      - ORA-06512: at "SYS.DBMS_JAVA", line 587
      - ORA-06512: at line 1
Patch 37532350 apply (pdb DEVDBPDB): SUCCESS
  logfile: D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\37532350\26102912/37532350_apply_DEVDB_DEVDBPDB_2025Sep19_16_29_05.log (no errors)

Adding patches to retry installation queue...done
Retry installation queue:
  For the following PDBs: PDB$SEED
    No interim patches need to be rolled back
    Patch 37532350 (Windows Database Bundle Patch : 19.27.0.0.250415 (37532350)):
      Apply from 19.25.0.0.0 Release_Update 241010184253 to 19.27.0.0.0 Release_Update 250422102456
    No interim patches need to be applied

Installing patches...
Patch installation complete.  Total patches installed: 1

Validating logfiles...done
Patch 37532350 apply (pdb PDB$SEED): WITH ERRORS
  logfile: D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\37532350\26102912/37532350_apply_DEVDB_PDBSEED_2025Sep19_16_36_30.log (errors)
  -> Error at line 91457: script md/admin/catsem.sql
      - ORA-29548: Java system class reported: release of Java system classes in the
      - database (19.0.0.0.0 1.8) does not match that of the oracle executable
      - (19.3.0.0.0 1.8)
      - ORA-06512: at "SYS.DBMS_JAVA", line 587
      - ORA-06512: at line 1

Please refer to MOS Note 1609718.1 and/or the invocation log
D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\sqlpatch_10384_2025_09_19_16_18_03\sqlpatch_invocation.log
for information on how to resolve the above errors.

SQL Patching tool complete on Fri Sep 19 16:41:52 2025

Step 17: Check the Patch Registry and Bounce the Database


SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ ONLY  YES
         3 DEVDBPDB                       READ WRITE YES
SQL> shut immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup
ORACLE instance started.

Total System Global Area 1174402832 bytes
Fixed Size                  9312016 bytes
Variable Size             838860800 bytes
Database Buffers          318767104 bytes
Redo Buffers                7462912 bytes
Database mounted.
Database opened.
SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ ONLY  YES
         3 DEVDBPDB                       READ WRITE NO
SQL>
SQL> show pdbs

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

DEVDBPDB is now clean; only PDB$SEED remains restricted, same as in the Windows to Linux direction.

Step 18: Open PDB$SEED Read/Write and Run update_javavm_db.sql Inside It

This time, connect directly to the PDB$SEED container rather than switching into a sibling PDB first, then close and reopen it in read-write mode to apply the fix. The "Warning: PDB altered with errors" on open is expected, that's the same underlying Java inconsistency this step resolves.


SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ ONLY  YES
         3 DEVDBPDB                       READ WRITE NO
SQL>
SQL> alter session set container=PDB$SEED;

Session altered.

SQL> alter pluggable database pdb$seed close immediate;

Pluggable database altered.

SQL>  alter pluggable database pdb$seed open read write;

Warning: PDB altered with errors.

SQL> select open_mode from v$database;

OPEN_MODE
--------------------
READ WRITE

SQL>
SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ WRITE YES
SQL>
SQL> @?/javavm/install/update_javavm_db.sql
SQL> SET FEEDBACK 1
SQL> SET NUMWIDTH 10
SQL> SET LINESIZE 80
SQL> SET TRIMSPOOL ON
SQL> SET TAB OFF
SQL> SET PAGESIZE 100
SQL>
SQL> alter session set "_ORACLE_SCRIPT"=true;

Session altered.

SQL>
SQL> -- If Java is installed, do CJS.
SQL>
SQL> -- If CJS can deal with the SROs inconsistent with the new JDK,
SQL> -- the drop_sros() call here can be removed.
SQL> call initjvmaux.drop_sros();

Call completed.

SQL>
SQL> create or replace java system;
  2  /

Java created.

SQL>
SQL> update dependency$
  2    set p_timestamp=(select stime from obj$ where obj#=p_obj#)
  3    where (select stime from obj$ where obj#=p_obj#)!=p_timestamp and
  4          (select type# from obj$ where obj#=p_obj#)=29  and
  5          (select owner# from obj$ where obj#=p_obj#)=0;

0 rows updated.

SQL>
SQL> commit;

Commit complete.

SQL>
SQL> alter session set "_ORACLE_SCRIPT"=false;

Session altered.

SQL>

Step 19: Run datapatch Verbose Once More


D:\app\oracle\product\19c\db_home1\OPatch>datapatch -verbose
SQL Patching tool version 19.27.0.0.0 Production on Fri Sep 19 17:01:27 2025
Copyright (c) 2012, 2025, Oracle.  All rights reserved.

Log file for this invocation: D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\sqlpatch_12208_2025_09_19_17_01_28\sqlpatch_invocation.log

Connecting to database...OK
Gathering database info...done

Note:  Datapatch will only apply or rollback SQL fixes for PDBs
       that are in an open state, no patches will be applied to closed PDBs.
       Please refer to Note: Datapatch: Database 12c Post Patch SQL Automation
       (Doc ID 1585822.1)

Bootstrapping registry and package to current versions...done
Determining current state...done

Current state of interim SQL patches:
  No interim patches found

Current state of release update SQL patches:
  Binary registry:
    19.27.0.0.0 Release_Update 250422102456: Installed
  PDB CDB$ROOT:
    Applied 19.27.0.0.0 Release_Update 250422102456 successfully on 19-SEP-25 04.28.02.056000 PM
  PDB DEVDBPDB:
    Applied 19.27.0.0.0 Release_Update 250422102456 successfully on 19-SEP-25 04.34.57.197000 PM
  PDB PDB$SEED:
    Applied 19.27.0.0.0 Release_Update 250422102456 with errors on 19-SEP-25 04.40.33.586000 PM

Adding patches to installation queue and performing prereq checks...done
Installation queue:
  For the following PDBs: CDB$ROOT DEVDBPDB
    No interim patches need to be rolled back
    No release update patches need to be installed
    No interim patches need to be applied
  For the following PDBs: PDB$SEED
    No interim patches need to be rolled back
    Patch 37532350 (Windows Database Bundle Patch : 19.27.0.0.250415 (37532350)):
      Apply from 19.25.0.0.0 Release_Update 241010184253 to 19.27.0.0.0 Release_Update 250422102456
    No interim patches need to be applied

Installing patches...
Patch installation complete.  Total patches installed: 1

Validating logfiles...done
Patch 37532350 apply (pdb PDB$SEED): SUCCESS
  logfile: D:\app\oracle\product\19c\db_home1\cfgtoollogs\sqlpatch\37532350\26102912/37532350_apply_DEVDB_PDBSEED_2025Sep19_17_06_02.log (no errors)
SQL Patching tool complete on Fri Sep 19 17:10:40 2025

Step 20: Bounce the Database


SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ WRITE YES
         3 DEVDBPDB                       READ WRITE NO
SQL>
SQL> shut immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup
ORACLE instance started.

Total System Global Area 1174402832 bytes
Fixed Size                  9312016 bytes
Variable Size             838860800 bytes
Database Buffers          318767104 bytes
Redo Buffers                7462912 bytes
Database mounted.
Database opened.
SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ ONLY  NO
         3 DEVDBPDB                       READ WRITE NO
SQL>

Step 21: Perform the Post-Check

Compare against the Step 1 baseline: database size at both the CDB and PDB level, complete patch history, invalid object count, registry component status, and the test table's row count. The patch registry now shows the full chain including this migration's apply attempts, which is expected and useful, it's a record of exactly what reconciliation happened.


SQL> def
DEFINE _DATE           = "19-SEP-25" (CHAR)
DEFINE _CONNECT_IDENTIFIER = "devdb" (CHAR)
DEFINE _USER           = "SYS" (CHAR)
DEFINE _PRIVILEGE      = "AS SYSDBA" (CHAR)
DEFINE _SQLPLUS_RELEASE = "1927000000" (CHAR)
DEFINE _EDITOR         = "Notepad" (CHAR)
DEFINE _O_VERSION      = "Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.27.0.0.0" (CHAR)
DEFINE _O_RELEASE      = "1927000000" (CHAR)
SQL>
SQL> show pdbs

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

SQL> SELECT name,db_unique_name,database_role,log_mode from v$database;

NAME      DB_UNIQUE_NAME                 DATABASE_ROLE    LOG_MODE
--------- ------------------------------ ---------------- ------------
DEVDB     devdb                          PRIMARY          ARCHIVELOG

SQL> SELECT
         (SELECT SUM(bytes)/1024/1024/1024 FROM dba_data_files) +
         (SELECT NVL(SUM(bytes),0)/1024/1024/1024 FROM dba_temp_files) +
         (SELECT SUM(bytes)/1024/1024/1024 FROM sys.v_$log) +
         (SELECT SUM(block_size*file_size_blks)/1024/1024/1024 FROM v$controlfile) "Size in GB"
     FROM dual;

Size in GB
----------
 3.8918457

SQL> COLUMN action_time FORMAT A20
SQL> COLUMN action FORMAT A10
SQL> COLUMN status FORMAT A10
SQL> COLUMN description FORMAT A60
SQL> SELECT patch_uid, patch_id, source_version, target_version,
     action, status, action_time, description
     FROM dba_registry_sqlpatch;

 PATCH_UID   PATCH_ID SOURCE_VERSION  TARGET_VERSION  ACTION     STATUS      ACTION_TIME          DESCRIPTION
---------- ---------- --------------- --------------- ---------- ----------  -------------------- ------------------------------------------------------------
  22862832   29517242 19.1.0.0.0      19.3.0.0.0      APPLY      SUCCESS     31-JUL-25 01.45.40.8 Database Release Update : 19.3.0.0.190416 (29517242)
                                                                             62490 PM
 
  25871884   36912597 19.3.0.0.0      19.25.0.0.0     APPLY      SUCCESS     02-SEP-25 12.35.34.6 Database Release Update : 19.25.0.0.241015 (36912597)
                                                                             01504 PM
 
  27123174   37642901 19.25.0.0.0     19.27.0.0.0     APPLY      SUCCESS     02-SEP-25 03.58.08.9 Database Release Update : 19.27.0.0.250415 (37642901)
                                                                             34050 PM
 
  27123174   37642901 19.27.0.0.0     19.25.0.0.0     ROLLBACK   SUCCESS     02-SEP-25 05.52.00.0 Database Release Update : 19.27.0.0.250415 (37642901)
                                                                             03677 PM
 
  26102912   37532350 19.25.0.0.0     19.27.0.0.0     APPLY      WITH ERRORS 19-SEP-25 02.02.35.1 Windows Database Bundle Patch : 19.27.0.0.250415 (37532350)
                                                                             22000 PM

  26102912   37532350 19.25.0.0.0     19.27.0.0.0     APPLY      WITH ERRORS 19-SEP-25 02.25.23.9 Windows Database Bundle Patch : 19.27.0.0.250415 (37532350)
                                                                             86000 PM

  26102912   37532350 19.25.0.0.0     19.27.0.0.0     APPLY      SUCCESS     19-SEP-25 04.28.02.0 Windows Database Bundle Patch : 19.27.0.0.250415 (37532350)
                                                                             56000 PM

7 rows selected.

SQL> COLUMN comp_id FORMAT A10
SQL> COLUMN version FORMAT A11
SQL> COLUMN status FORMAT A10
SQL> COLUMN comp_name FORMAT A37
SQL> SELECT comp_id, comp_name, version, status FROM dba_registry;

COMP_ID    COMP_NAME                             VERSION     STATUS
---------- ------------------------------------- ----------- ----------
CATALOG    Oracle Database Catalog Views         19.0.0.0.0  VALID
CATPROC    Oracle Database Packages and Types    19.0.0.0.0  VALID
JAVAVM     JServer JAVA Virtual Machine          19.0.0.0.0  VALID
XML        Oracle XDK                            19.0.0.0.0  VALID
CATJAVA    Oracle Database Java Packages         19.0.0.0.0  VALID
APS        OLAP Analytic Workspace               19.0.0.0.0  VALID
RAC        Oracle Real Application Clusters      19.0.0.0.0  OPTION OFF
XDB        Oracle XML Database                   19.0.0.0.0  VALID
OWM        Oracle Workspace Manager              19.0.0.0.0  VALID
CONTEXT    Oracle Text                           19.0.0.0.0  VALID
ORDIM      Oracle Multimedia                     19.0.0.0.0  VALID
SDO        Spatial                               19.0.0.0.0  VALID
XOQ        Oracle OLAP API                       19.0.0.0.0  VALID
OLS        Oracle Label Security                 19.0.0.0.0  VALID
DV         Oracle Database Vault                 19.0.0.0.0  VALID

15 rows selected.

SQL>  select count(*) from dba_objects where status='INVALID';

  COUNT(*)
----------
         0

SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ ONLY  NO
         3 DEVDBPDB                       READ WRITE NO
SQL>
SQL> alter session set container=DEVDBPDB;

Session altered.

SQL> SELECT
         (SELECT SUM(bytes)/1024/1024/1024 FROM dba_data_files) +
         (SELECT NVL(SUM(bytes),0)/1024/1024/1024 FROM dba_temp_files) +
         (SELECT SUM(bytes)/1024/1024/1024 FROM sys.v_$log) +
         (SELECT SUM(block_size*file_size_blks)/1024/1024/1024 FROM v$controlfile) "Size in GB"
     FROM dual;

Size in GB
----------
2.67211914

SQL> SELECT comp_id, comp_name, version, status FROM dba_registry;

COMP_ID    COMP_NAME                             VERSION     STATUS
---------- ------------------------------------- ----------- ----------
CATALOG    Oracle Database Catalog Views         19.0.0.0.0  VALID
CATPROC    Oracle Database Packages and Types    19.0.0.0.0  VALID
JAVAVM     JServer JAVA Virtual Machine          19.0.0.0.0  VALID
XML        Oracle XDK                            19.0.0.0.0  VALID
CATJAVA    Oracle Database Java Packages         19.0.0.0.0  VALID
APS        OLAP Analytic Workspace               19.0.0.0.0  VALID
RAC        Oracle Real Application Clusters      19.0.0.0.0  OPTION OFF
XDB        Oracle XML Database                   19.0.0.0.0  VALID
OWM        Oracle Workspace Manager              19.0.0.0.0  VALID
CONTEXT    Oracle Text                           19.0.0.0.0  VALID
ORDIM      Oracle Multimedia                     19.0.0.0.0  VALID
SDO        Spatial                               19.0.0.0.0  VALID
XOQ        Oracle OLAP API                       19.0.0.0.0  VALID
OLS        Oracle Label Security                 19.0.0.0.0  VALID
DV         Oracle Database Vault                 19.0.0.0.0  VALID

15 rows selected.

SQL>  select count(*) from dba_objects where status='INVALID';

  COUNT(*)
----------
         0

SQL> select count(*) from test.company;

  COUNT(*)
----------
         3

SQL>

This is how you can migrate a database from Linux to Windows using RMAN. As with the reverse direction, run this through complete testing on a non-production system before relying on it for a production database, and take the block-level error in Step 10 as a reminder to validate thoroughly rather than assume it's harmless.

Thank you for reading!

I hope this content has been helpful to you. Your feedback and suggestions are always welcome, feel free to leave a comment or reach out with any queries.

Abhishek Shrivastava

Oracle DBA with hands-on experience managing production Data Guard, RAC, GoldenGate, and APEX environments. I write practical, tested installation and troubleshooting guides based on real deployment work.

📧 Email: oraeasyy@gmail.com
🌐 Website: www.oraeasy.com

Follow Us

Comments

↑