Showing results for 
Search instead for 
Do you mean 

Java 1.5 and timezone

Highlighted
Honored Contributor Honored Contributor

Java 1.5 and timezone

Hello,

I installed Java 1.5 on my box and wrote a simple program that displayes the current time and date. The problem is that the time displayed is actually the time I see when I invoke "date -u" and not "date". Same program compiled and run with Java 1.4 (same server) shows the right time (like "date").

I think it has something to do with timezone settings, that for some reason are different for 1.5 and 1.4

Any ideas about it?


Thanx.
I don't give a damn for a man that can only spell a word one way. (M. Twain)
1 REPLY
Honored Contributor Honored Contributor

Re: Java 1.5 and timezone

Well, just for protocol I found the problem.
TZ that is set in the system, must appear in /opt/java1.5/jre/lib/tzmappings file in order java will recognize it.

Hope it will help to someone in the future.
I don't give a damn for a man that can only spell a word one way. (M. Twain)