• Document URL not provided or invalid

  • We tried to make OpenKM as intuitive as possible, but an advice is always welcome.
We tried to make OpenKM as intuitive as possible, but an advice is always welcome.
Forum rules: Please, before asking something see the documentation wiki or use the search feature of the forum. And remember we don't have a crystal ball or mental readers, so if you post about an issue tell us which OpenKM are you using and also the browser and operating system version. For more info read How to Report Bugs Effectively.
 #11688  by rmm
 
I was really having a hard time when uploading and downloading a file in openkm.
I am using 5.1.5 on Centos 5.5 and when i try to preview the document it says "Document URL not provided or invalid"
Users are using Windows XP and when they try to upload a document especially powerpoint and download a document, it couldnt be opened and previewed.
I had a direct conversion of files and it worked smoothly. ImageMagick, SWFTools and OpenOffice are working fine. I need some help. Thanks
 #11690  by rmm
 
this is the error I am getting:
Code: Select all
13:24:12,275 WARN  [ExecutionUtils] Abnormal program termination: 1
13:24:12,276 WARN  [ExecutionUtils] STDERR: Error: Couldn't open file '/opt/OpenKM/cache/pdf/5bad861e-8cd6-43a0-8ee9-bf46c7a673b3.pdf'

13:24:12,276 ERROR [ConverterServlet] /opt/OpenKM/cache/swf/5bad861e-8cd6-43a0-8ee9-bf46c7a673b3.swf (No such file or directory)
java.io.FileNotFoundException: /opt/OpenKM/cache/swf/5bad861e-8cd6-43a0-8ee9-bf46c7a673b3.swf (No such file or directory)
at java.io.FileInputStream.open(Native Method)
        at java.io.FileInputStream.<init>(FileInputStream.java:137)
        at com.openkm.servlet.frontend.ConverterServlet.service(ConverterServlet.java:168)
        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(Thread.java:636)
13:24:12,278 ERROR [[ConverterServlet]] Servlet.service() for servlet ConverterServlet threw exception
com.openkm.frontend.client.OKMException: /opt/OpenKM/cache/swf/5bad861e-8cd6-43a0-8ee9-bf46c7a673b3.swf (No such file or directory)
        at com.openkm.servlet.frontend.ConverterServlet.service(ConverterServlet.java:194)
        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(Thread.java:636)
What could be the solution to this problem?
I have migrated from Openkm 5.1.5 to 5.1.7 and installed the latest version of OpenOffice version 3.3.
I have a sample ppt presentation uploaded.

Please read my first post .
Thank you for your help!
Attachments
sample ppt presentation
sample ppt presentation
openkm.jpg (185.15 KiB) Viewed 7812 times
 #11698  by jllort
 
Before doing anything ensure soffice service is running ( when you've got some conversion problem ), and ensure too when stop jboss is stoped ( if jboss is not stopped correctly soffice could be yet started and new jboss instance really is not using soffice because is not yet started on openk start up ).

After it:
In order detect the problem, copy one of the files that has problems in your server and execute the conversion utilities you need, for example take ppt.

1- Use openoffice to convert from ppt to pdf
2- Use pdf2swf to convert from pdf to swf the command must be pdf2swf -T 9 input.pdf -o output.swf
 #11704  by JanB
 
Hi

I have the nearly the same error but all previews are working except for the JPG
I have found an install document for centos 5.5 which was a great help for me to set me back on track (except JPG)
Code: Select all
Install OpenKM on centos 5 
 
download the latest openkm from: http://sourceforge.net/projects/openkm/files/5.0/
unpack the content

install tesseract ocr:
sudo yum install libjpeg-devel libpng-devel libtiff-devel zlib-devel gcc gcc-c++ make -y
wget http://www.leptonica.com/source/leptonlib-1.67.tar.gz
tar -zxvf leptonlib-1.67.tar.gz
./configure && make && sudo make install
wget http://tesseract-ocr.googlecode.com/files/tesseract-3.00.tar.gz
tar -zxvf tesseract-3.00.tar.gz
./configure && make && sudo make install
cd /usr/local/share/tessdata
sudo wget http://tesseract-ocr.googlecode.com/files/eng.traineddata.gz
sudo gunzip eng.traineddata.gz
cd -

install openoffice.org:
yum install openoffice.org2-l10n-es openoffice.org-java openoffice.org-java-common openoffice.org

install swftools
wget http://www.swftools.org/swftools-0.9.1.tar.gz
tar -zxvf swftools-0.9.1.tar.gz
sudo yum install gcc* automake zlib-devel libjpeg-devel giflib-devel freetype-devel -y
cd swftools-0.9.1
./configure && make && sudo make install
cd ..
<pre>

install ImageMagick
sudo yum install ImageMagick
which convert #will tell you where it is.

Or install and control the process by yourselve:
yum remove ImageMagick
yum install tcl-devel libpng-devel libjpeg-devel ghostscript-devel bzip2-devel freetype-devel libtiff-devel
wget url to ImageMagick download  
tar -zxvf ImageMagick-6.4.8-3.tar.gz
./configure --prefix=/usr/local --with-bzlib=yes --with-fontconfig=yes --	with-freetype=yes --with-gslib=yes --with-gvc=yes --with-jpeg=yes --	with-jp2=yes --with-png=yes --with-tiff=yes
make clean
make
make install 

install ClamAV
sudo yum install amavisd-new spamassassin clamav clamd unzip bzip2 unrar perl-DBD-mysql
sudo sa-update
sudo chkconfig --levels 235 amavisd on
sudo chkconfig --levels 235 clamd on
sudo /usr/bin/freshclam
sudo /etc/init.d/amavisd start
sudo /etc/init.d/clamd start
sudo mkdir /var/run/amavisd /var/spool/amavisd /var/spool/amavisd/tmp /var/spool/amavisd/db
sudo chown amavis /var/run/amavisd /var/spool/amavisd /var/spool/amavisd/tmp /var/spool/amavisd/db
sudo ln -s /var/run/clamav/clamd.sock /var/spool/amavisd/clamd.sock

the OpenKM.cfg should look like this now:
system.ocr=/usr/local/bin/tesseract
system.openoffice.path=/usr/lib/openoffice
system.img2pdf=/usr/bin/convert
system.pdf2swf=/usr/local/bin/pdf2swf
#since openkm 5.1 we use :
System.imagemagick.convert=/usr/bin/convert
System.swftools.pdf2swf=/usr/local/bin/pdf2swf
system.antivir=/usr/bin/clamscan
hibernate.dialect=org.hibernate.dialect.HSQLDialect
hibernate.hbm2ddl=create
application.url=http://host:8080/OpenKM/com.openkm.frontend.Main/index.jsp
be sure to change the hibernate.hbm2ddl value to “none” without quotes later

run OpenKM
bin/run -b 0.0.0.0 &
________________________________________
references
http://paramountideas.com/tesseract-ocr-30-and-leptonica-installation-centos-55-and-opensuse-113

http://www.betaquest.com/2010/08/how-to-install-swftools-0-9-1-on-centos-5-5/

http://wiki.openkm.com/index.php/WebDAV_accesshttp://www.howtoforge.com/perfect-server-centos-5.5-x86_64-ispconfig-3-p6http://tomcat.apache.org/tomcat-5.5-doc/ssl-howto.html
http://blog.srvme.de/2011/04/16/install-openkm-on-centos-5/

I have made some addings to be in line with OpenKM 5.1
Maybe it helps for you, it surely did for me
If there are any mistakes in above mentioned instruction list, please let me know so i can change it
At the end this doesn't solve your problem completely but i hope we are getting closer to the solution
 #11718  by jllort
 
If JPG conversion is not done, the problem sure is on imagemagick, in your case try executing convert a JPG to PDF and then to SWF ( using pdf2swf ). Ensure path to convert is right.
 #11750  by pavila
 
AS stated by Josep, first a JPG to PDF conversion is done using ImageMagic's convert utility. After that, the resulting PDF is converted to SWF using SWFTools' pdf2swf utility. RedHat based distros like CentOS seems to have problems with the ImageMagic package, so is better to get it from ImageMagic site or compile yourself.
 #11777  by JanB
 
Hi

to solve this issue i have done the following :

Compiled the imagemagick distribution (as also recommended by pavilla)
Look for the errors in the compile log
if there are "NO" answers on the extension you want you have to search for the right libraries

When you have installed imagemagick check if the command [convert filename.jpg filename.pdf] is creating a readable PDF file
IF so than you have succesfully installed imagemagick and you are nearly finished

after you have installed imagemagick be sure to clear the openkm/cache/pdf directory
If there is any error on a file it will not be recoverred automatically , but that's my own practical experience

If you follow these guidelines , conversion should be work like a charm
Although it did in my case on centos 5.6
 #11780  by rmm
 
Thank you for the help -pavila,jllort and JanB
Is centos really having a hard time in ImageMagick package?

I have compiled ImageMagick myself. Cleared the cache folder
all of the things are working, convert, pdf2swf utility.
Document to pdf are working .doc-pdf, .txt files, .jpg, .psd,.xls, .ppt and .pptx.

but I just want to point out that there are some ppt and pdf that cannot be viewed,

it only displays white background
displays the error just like in my second post.
and if you will download the file, it produces 0 bytes and cannot be opened.

Sometimes when I have to preserve the textformatting of some ppt files
--Save As--> Tools button--> Save Options --> Embed fonts in the file.
It gives a preview.

I cannot post the files that I am currently working coz of company policy. But if I am given authority to send it, I will. so that you can test.
 #11798  by jllort
 
Try to install msttcorefonts package (not sure if has the same name in CentOS).
 #11911  by rmm
 
is it possible to use text extractors like Apache POI - Text Extraction in openkm?
I think I was also having a problem in extracting text in my files.
 #11983  by pavila
 
OpenKM uses POI to extract document contents. Which problem do you have or what documents are not indexed?
 #12312  by preminik
 
Hi rmm,

This was the same issue I had with my OpenKM 5.1.7 with mysql Datastore setting.
OpenKM displays as the upload of large file (more than 16MB) is successful but actually the database has [BLOB 0], i think it means the file hasn't been uploaded correctly.

I found out that I can't upload more than 16MB file into MySQL Datastore, so changed to file storage.

Are you using MySQL Datastore?

regards,
preminik
 #12339  by rmm
 
yes i am using mysql database..the last time i've check...there are really some large files that can't be previewed.
However to resolve the problem....

1. I must check the files that I've been uploading...might have a problem in the file itself..might be corrupted or there are some fonts that cant be viewed i think.
2. i've been checking the mysql settings: max_allowed_packet, connection_timeout, etc. There are instances that when you upload a very large file...the connection time was disconnected before it is uploaded..
the files are therefore broken. must also check the allowable packets that it is accepting..might have a problem also in there.
3. might have a problem in the configuration and installation of ImageMagick and pdf2swf.

hope this helps.
 #12397  by pavila
 
The best performance and better tested is the FileDataStore implementation. DatabaseDataStore also works pretty well, but has been tested mainly with Oracle. Maybe the problem is related to MySQL server configuration.

Regarding to conversion and preview problems, I also recommend to try the last night build from http://integration.openkm.com/5.1.x/.

About Us

OpenKM is part of the management software. A management software is a program that facilitates the accomplishment of administrative tasks. OpenKM is a document management system that allows you to manage business content and workflow in a more efficient way. Document managers guarantee data protection by establishing information security for business content.