Page 1 of 1

OpenKM 6.2 Wrong Document Time

PostPosted:Thu Oct 25, 2012 9:38 am
by juliaugong
Hi everyone,

I have just installed OpenKM 6.2 on CentOS 6.3, but I found the document time is 12hours early than the OS time. Such as my OS time is Thu Oct 25 17:35:25 HKT 2012, and the OpenKM time is 2012-10-25 5:35:25.

but when I use OpenKM 5.1.11 on the same server, the time correct.

anyone can help me.

thanks very much!

Re: OpenKM 6.2 Wrong Document Time

PostPosted:Thu Oct 25, 2012 10:26 pm
by okmuser
Is your log entries have the same time difference too?

If so, then the timezone setting is incorrect in tomcat.

Re: OpenKM 6.2 Wrong Document Time

PostPosted:Fri Oct 26, 2012 2:07 am
by juliaugong
I have checked several logs,
catalina.log(correct)
Code: Select all
2012-10-25 15:17:31,037 [pool-2-thread-1] INFO  com.openkm.extractor.RegisteredExtractors - Registering org.apache.jackrabbit.extractor.RTFTextExtractor for 'application/rtf'
2012-10-25 15:17:31,037 [pool-2-thread-1] INFO  com.openkm.extractor.RegisteredExtractors - Registering org.apache.jackrabbit.extractor.RTFTextExtractor for 'text/rtf'
2012-10-25 15:17:31,038 [pool-2-thread-1] INFO  com.openkm.extractor.RegisteredExtractors - Registering org.apache.jackrabbit.extractor.HTMLTextExtractor for 'text/html'
2012-10-25 15:17:31,039 [pool-2-thread-1] INFO  com.openkm.extractor.RegisteredExtractors - Registering org.apache.jackrabbit.extractor.XMLTextExtractor for 'text/xml'
2012-10-25 15:17:31,039 [pool-2-thread-1] INFO  com.openkm.extractor.RegisteredExtractors - Registering org.apache.jackrabbit.extractor.XMLTextExtractor for 'application/xml'
catalina.2012-10-25.log(correct):
Code: Select all
Oct 25, 2012 3:17:14 PM com.openkm.util.LoggerWatchdog doOnChange
INFO: *** Log4j configuration file changed ***
Oct 25, 2012 3:26:56 PM com.openkm.util.LoggerWatchdog doOnChange
INFO: *** Log4j configuration file changed ***
Oct 25, 2012 4:28:30 PM com.openkm.util.LoggerWatchdog doOnChange
INFO: *** Log4j configuration file changed ***
Oct 25, 2012 4:36:56 PM com.openkm.util.LoggerWatchdog doOnChange
INFO: *** Log4j configuration file changed ***
Oct 25, 2012 5:04:27 PM com.openkm.util.LoggerWatchdog doOnChange
INFO: *** Log4j configuration file changed ***
Oct 25, 2012 5:12:58 PM com.openkm.util.LoggerWatchdog doOnChange
INFO: *** Log4j configuration file changed ***
Oct 25, 2012 5:21:37 PM com.openkm.util.LoggerWatchdog doOnChange
INFO: *** Log4j configuration file changed ***
okmdb.log(correct)
Code: Select all
/*C9*/SET SCHEMA PUBLIC
DISCONNECT
/*C10*/SET SCHEMA PUBLIC
INSERT INTO OKM_ACTIVITY VALUES(1714,'MISC_OPENKM_START','2012-10-25 17:21:53.136000',NULL,NULL,NULL,'system')
COMMIT
how can I set correct timezone in my tomcat?

thanks very much!

Re: OpenKM 6.2 Wrong Document Time

PostPosted:Fri Oct 26, 2012 6:15 am
by okmuser
In
Code: Select all
$TOMCAT_HOME/bin/catalina.sh 
insert/amend
Code: Select all
CATALINA_OPTS=-Duser.timezone=Asia/Hong_Kong

Re: OpenKM 6.2 Wrong Document Time

PostPosted:Sat Oct 27, 2012 5:50 pm
by jllort
better change variables at setenv.sh, I take note about this issue and I've add some section at wiki here http://wiki.openkm.com/index.php/Change_Tomcat_timezone

Re: OpenKM 6.2 Wrong Document Time

PostPosted:Sun Oct 28, 2012 4:27 am
by juliaugong
Thanks, it's all right!