Hi, I have problem with getting server date (linux server). When I use linux 'date' command I get properly date value (real date). If I modify some file on server, modify date is also properly (real date). But if i use java code System.out.println(new Date()) on server I get date with 1 hour difference i.e. linux 'date' command result = Wed Sep 16 08:48:25 CEST, System.out.println(new Date()) result = Wed Sep 16 07:48:25 GMT+1 Is this linux configuration problem or wrong getting date using java. Thanks
date --rfc-2822; date +%s
Wed, 16 Sep 2009 09:59:36 +0200 1253087976
System.out.println(new SimpleDateFormat("EEE', 'dd' 'MMM' 'yyyy' 'HH:mm:ss' 'Z").format(new Date()));
System.out.println(new Date().getTime() / 1000);
16 wrz 2009 09:00:33 +0100 1253088033