My Oracle Support Banner

Java Program Not Picking Up The Correct Timezone (Doc ID 1368908.1)

Last updated on SEPTEMBER 01, 2018

Applies to:

Oracle JRockit - Version R28.1.0 and later
Linux x86
Linux x86-64
***Checked for relevance on 15-MAY-2013***
***Checked for relevance on 17-NOV-2014***


On : R28.1.0 version, JVM and JDK

When attempting to get the data and time with a Java program, the date and time does not seem to take care of the timezone.
The following error occurs.


>jrockit-jdk1.5.0_30/bin/java UTCTest
Date and time from command line Wed Sep 28 12:25:34 EDT 2011

Date and time from Java 28-Sep-2011 16:25:34

Timezone properties from java.util.TimeZone...
Locale = en_US US en
System property user.timezone = GMT
System property = US
System property java.home = [...]/jrockit-jdk1.5.0_30/jre
Default TimeZone = Greenwich Mean Time
Default TimeZone ID = GMT
TimeZone offset from GMT = 0 hrs
Raw TimeZone offset from GMT = 0 hrs

The issue can be reproduced at will with the following steps:
1. To compile the Java program "" on Linux with the latest JRockit 1.5.0
2. To run the Java program: java UTCTest


To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!

My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.