ORA-01882 Timezone region not found

I got ” ORA-01882 Timezone region not found ”  error in Oracle database.

 

ORA-01882 Timezone region not found

 

Details of error are as follows.

ORA-01882 timezone region not found 
---------------------------------------------------------------------------
Cause: The specified region name was not found. 
Action: Contact Oracle Support Services.

 

 

 

timezone region not found

This ORA-01882 error is related with the specified region name was not found.

The ORA-01882 is due to a change of functionality in JDBC 11.2 in conjunction with a default timezone name/region on the client that is not supported by the database.

The change of functionality in JDBC 11.2 is to use timezone name/region directly if it is a known Oracle one rather than convert to a GMT offset. This is documented in:
Unpublished Bug 8435999 – PROVIDE SWITCH TO REVERT TO OLD SESSION TIMEZONE USAGE
and in
Documentation Bug 9413359 – ORACLE.JDBC.TIMEZONEASREGION AND 11.2 CHANGE OF FUNCTIONALITY NOT DOCUMENTED .

According to unpublished Bug 8435999, the reason for the change is to avoid several daylight savings time (DST) related bugs. The individual bugs are not identified.

The default timezone name/region on the client, although intended to be “GMT”, was “Africa/Lome”. This does not exist until Oracle Time Zone File version 5. The database has only Time Zone version 4 (the default for a 10.2.0.4 database).

The default timezone name/region on the client was determined by running a java application that used
System.out.println(“Default TimeZone is: ” + TimeZone.getDefault());

On the machine where the ORA-01882 occurred, this displayed:
Default TimeZone is : sun.util.calendar.ZoneInfo[id=”Africa/Lome”,offset=0,dstSavings=0,useDaylight=false,transitions=0,lastRule=null]”
On the machines where the ORA-01882 did not occur, this displayed:
Default TimeZone is : sun.util.calendar.ZoneInfo[id=”GMT”,offset=0,dstSavings=0,useDaylight=false,transitions=0,lastRule=null]

The database timezone version of 4 was determined by:
select version from v$timezone_file;

The addition of “Africa/Lome” in version 5 of the database timezone files is documented in:
Note 412160.1 – Updated DST transitions and new Time Zones in Oracle Time Zone File patches”.

Although it is not known why the default timezone on the one machine was “Africa/Lome” when it should have been “GMT” like on the other machines, differences in some binary timezone files were observed. On the machines where the default timezone was “GMT” and where the ORA-01882 did not occur, /etc/localtime and /usr/share/zoneinfo/GMT were identical but /usr/share/zoneinfo/Africa/Lome was different. However, on the machine where the ORA-01882 occurred, all three files were identical.

 

The solution is to use a timezone supported by the database. This can be done by setting the TZ environment variable. When TZ is set, its value will be used rather than the operating system default timezone.

The workaround is to set the connection property oracle.jdbc.timezoneAsRegion to “false”. This reverts to the old style of session timezone behavior.
Example:

java -Doracle.jdbc.timezoneAsRegion=”false” <program>

 

 

Do you want to learn Oracle Database for Beginners, then read the following articles.

Oracle Tutorial | Oracle Database Tutorials for Beginners ( Junior Oracle DBA )

 

About Mehmet Salih Deveci

I am Founder of SysDBASoft IT and IT Tutorial and Certified Expert about Oracle & SQL Server database, Goldengate, Exadata Machine, Oracle Database Appliance administrator with 10+years experience.I have OCA, OCP, OCE RAC Expert Certificates I have worked 100+ Banking, Insurance, Finance, Telco and etc. clients as a Consultant, Insource or Outsource.I have done 200+ Operations in this clients such as Exadata Installation & PoC & Migration & Upgrade, Oracle & SQL Server Database Upgrade, Oracle RAC Installation, SQL Server AlwaysOn Installation, Database Migration, Disaster Recovery, Backup Restore, Performance Tuning, Periodic Healthchecks.I have done 2000+ Table replication with Goldengate or SQL Server Replication tool for DWH Databases in many clients.If you need Oracle DBA, SQL Server DBA, APPS DBA,  Exadata, Goldengate, EBS Consultancy and Training you can send my email adress [email protected].-                                                                                                                                                                                                                                                 -Oracle DBA, SQL Server DBA, APPS DBA,  Exadata, Goldengate, EBS ve linux Danışmanlık ve Eğitim için  [email protected] a mail atabilirsiniz.

Leave a Reply

Your email address will not be published. Required fields are marked *