Page 1 of 1

After changing max.file.size I cannot upload any files

PostPosted:Sat Apr 07, 2012 1:12 pm
by cvradis
I have this weird problem that it is driving me crazy.
For a few months now I have installed OpenKM 5.1.9 (build 7447) with Community Extension 5.1 on a Windows 2003 Standard Edition (64bit) and everything worked perfectly. I created the taxonomy, uploaded files etc. At some point I wanted to upload some large files (always less than 2GB) so I tried to change the max.file.size parameter to 0 so as to disable file size check. Then, I started getting errors, like the one below. I changed the max.file.size to 100000000, then to -1, then to max integer value (2^31-1) always getting errors similar to the one below:
error_msg.PNG
error_msg.PNG (108.82 KiB) Viewed 3718 times
On the server, the errors issued where like this (with different max file sizes each time, depending on the setting of the parameter):
Code: Select all
15:37:13,225 ERROR [DirectDocumentModule] Uploaded file size: 5,8 KB (5975), Max
 file size: -335544320 B (-335544320) 15:37:13,225 WARN  [FileUploadServlet] 5975  com.openkm.core.FileSizeExceededException: 5975 
        at com.openkm.module.direct.DirectDocumentModule.create(DirectDocumentModule.java:122)
        at com.openkm.module.direct.DirectDocumentModule.create(DirectDocumentModule.java:98)
        at com.openkm.api.OKMDocument.create(OKMDocument.java:71)
        at com.openkm.servlet.frontend.FileUploadServlet.doPost(FileUploadServlet.java:225)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
        at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:182)
        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:524)
        at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
        at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262)
        at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
        at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
        at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)
        at java.lang.Thread.run(Unknown Source)
Please note that whenever I changed the max file size, I stopped Openkm, then I emptied the cache folder at HOME\server\default\work, then restarted OpenKM.

My current settings are as below:
settings.png
settings.png (187.88 KiB) Viewed 3718 times
The problem at this moment is that I cannot upload any files now, no matter how large or small they are! Any help will be greatly appreciated. Thanks in advance.

Re: After changing max.file.size I cannot upload any files

PostPosted:Sat Apr 07, 2012 10:43 pm
by cvradis
OK after some attempts, I've set the max.file.size to 99999999 and things are back to normal.
However I cannot understand why OpenKM refuses to upload any files when the parameter is set to "0".

Re: After changing max.file.size I cannot upload any files

PostPosted:Sun Apr 08, 2012 6:05 pm
by jllort
0 indicates file with 0 bytes size, that's the reason, 1 indicates 1MB max file size.

Re: After changing max.file.size I cannot upload any files

PostPosted:Wed Apr 11, 2012 6:47 am
by pavila
Setting max.file.size to 0 should disable file upload size check. Try to reproduce this problem in a recent night build from http://integration.openkm.com/5.1.x/.