Tuesday 8 October 2024

ORA-39405: Oracle Data Pump does not support importing from a source database with TSTZ version 41 into a target database with TSTZ version 32.

 
Import: Release 19.0.0.0.0 - Production on Wed Oct 9 09:11:46 2024
Version 19.21.0.0.0

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

Connected to: Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
ORA-39002: invalid operation
ORA-39405: Oracle Data Pump does not support importing from a source database with TSTZ version 41 into a target database with TSTZ version 32.



-bash-4.2$ sqlplus

SQL*Plus: Release 19.0.0.0.0 - Production on Wed Oct 9 09:17:49 2024
Version 19.21.0.0.0

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

Enter user-name: /as sysdba

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

SQL> select * from v$timezone_file;

FILENAME        VERSION     CON_ID
-------------------- ---------- ----------
timezlrg_32.dat          32      0

SQL>

SQL> SELECT PROPERTY_NAME, SUBSTR(property_value, 1, 30) value
FROM DATABASE_PROPERTIES
WHERE PROPERTY_NAME LIKE 'DST_%'
ORDER BY PROPERTY_NAME;  2    3    4  

PROPERTY_NAME
--------------------------------------------------------------------------------------------------------------------------------
VALUE
------------------------------------------------------------------------------------------------------------------------
DST_PRIMARY_TT_VERSION
32

DST_SECONDARY_TT_VERSION
0

DST_UPGRADE_STATE
NONE


SQL>


-bash-4.2$ ls -lrt
total 0
drwxr-xr-x 4 oracle oinstall 48 Oct  9 09:28 35099667
-bash-4.2$ cd 35099667/
-bash-4.2$ pwd
/u01/soft/patch/35099667
-bash-4.2$ /u01/app/oracle/product/19.0.0.0/dbhome_1/OPatch/opatch prereq CheckConflictAgainstOHWithDetail -ph ./
Oracle Interim Patch Installer version 12.2.0.1.43
Copyright (c) 2024, Oracle Corporation.  All rights reserved.

PREREQ session

Oracle Home       : /u01/app/oracle/product/19.0.0.0/dbhome_1
Central Inventory : /u01/app/oraInventory
   from           : /u01/app/oracle/product/19.0.0.0/dbhome_1/oraInst.loc
OPatch version    : 12.2.0.1.43
OUI version       : 12.2.0.7.0
Log file location : /u01/app/oracle/product/19.0.0.0/dbhome_1/cfgtoollogs/opatch/opatch2024-10-09_09-30-29AM_1.log

Invoking prereq "checkconflictagainstohwithdetail"

Prereq "checkConflictAgainstOHWithDetail" passed.

OPatch succeeded.
-bash-4.2$

-bash-4.2$ /u01/app/oracle/product/19.0.0.0/dbhome_1/OPatch/opatch apply
Oracle Interim Patch Installer version 12.2.0.1.43
Copyright (c) 2024, Oracle Corporation.  All rights reserved.


Oracle Home       : /u01/app/oracle/product/19.0.0.0/dbhome_1
Central Inventory : /u01/app/oraInventory
   from           : /u01/app/oracle/product/19.0.0.0/dbhome_1/oraInst.loc
OPatch version    : 12.2.0.1.43
OUI version       : 12.2.0.7.0
Log file location : /u01/app/oracle/product/19.0.0.0/dbhome_1/cfgtoollogs/opatch/opatch2024-10-09_09-34-45AM_1.log

Verifying environment and performing prerequisite checks...

Conflicts/Supersets for each patch are:

Patch : 35099667

    Bug SubSet of 35643107
    Subset bugs are:
    35099667

OPatch found that the following patch(es) are not required.
They are either subset of the patches in Oracle Home (or) subset of the patches in the given list:
 [ 35099667 ]

Log file location: /u01/app/oracle/product/19.0.0.0/dbhome_1/cfgtoollogs/opatch/opatch2024-10-09_09-34-45AM_1.log

OPatch succeeded.
-bash-4.2$


The normal process to upgrade timezone fixes this
@?/rdbms/admin/utltz_countstats.sql
@?/rdbms/admin/utltz_upg_check.sql
@?/rdbms/admin/utltz_upg_apply.sql

SQL> select * from v$timezone_file;

FILENAME        VERSION     CON_ID
-------------------- ---------- ----------
timezlrg_42.dat          42      0

1 row selected.

SQL> show pdbs

    CON_ID CON_NAME              OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
     2 PDB$SEED              READ ONLY  NO
     3 PDB                  MOUNTED
     4 STLBAS              MOUNTED
SQL> alter pluggable database STLBAS open;

Pluggable database altered.

SQL>


SQL> show pdbs

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

Session altered.

SQL> select * from v$timezone_file;

FILENAME        VERSION     CON_ID
-------------------- ---------- ----------
timezlrg_32.dat          32      0


The normal process to upgrade timezone fixes this
@?/rdbms/admin/utltz_countstats.sql
@?/rdbms/admin/utltz_upg_check.sql
@?/rdbms/admin/utltz_upg_apply.sql

SQL> @?/rdbms/admin/utltz_countstats.sql

Session altered.

.
Amount of TSTZ data using num_rows stats info in DBA_TABLES.
.
.
.

SQL> @?/rdbms/admin/utltz_upg_check.sql

Session altered.

INFO: Starting with RDBMS DST update preparation.
.
.
.
.


SQL> @?/rdbms/admin/utltz_upg_apply.sql

Session altered.

INFO: If an ERROR occurs, the script will EXIT SQL*Plus.
INFO: The database RDBMS DST version will be updated to DSTv42 .
INFO: This database
.
.
.

Session altered.

SQL> show pdbs

    CON_ID CON_NAME              OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
     4 STLBAS              READ WRITE NO
SQL> select * from v$timezone_file;

FILENAME        VERSION     CON_ID
-------------------- ---------- ----------
timezlrg_42.dat          42      0

1 row selected.

SQL>

No comments:

Post a Comment