xok Posted March 25, 2011 Share Posted March 25, 2011 Hi all,(Sorry if this is considered cross-post but I posted before in the wrong forum...).I am having an issue that is driving me nuts.. see error bellow.Anyone who gives me the right solution to solve this, I will pay 50 USD /tools/fckeditor/editor/images/smiley/msn/teeth_smile.gif And a keg of free beer! /tools/fckeditor/editor/images/smiley/msn/teeth_smile.gif System Specification:LAMP (CentOS 5.5, Apache, PHP 5.3, MySQL)PHP-JavaBridgeApache Tomcat 6Java (Several flavours... tired of trying lots of things) Executing the report:Fatal error: Uncaught [[o:Exception]:"java.lang.Exception: Invoke failed: [[c:JasperCompileManager]]->compileReport((o:String)[o:String]). Cause: net.sf.jasperreports.engine.JRException: java.io.FileNotFoundException: /FULL_PATH/rpt_file.jrxml (Permission denied) VM: 1.6.0_17@http://java.sun.com/" at: #-12 net.sf.jasperreports.engine.xml.JRXmlLoader.load(JRXmlLoader.java:174) #-11 net.sf.jasperreports.engine.xml.JRXmlLoader.load(JRXmlLoader.java:154) #-10 net.sf.jasperreports.engine.JasperCompileManager.compileReport(JasperCompileManager.java:146) #-9 sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) #-8 sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) #-7 sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) #-6 java.lang.reflect.Method.invoke(Method.java:616) #-5 php.java.bridge.JavaBridge.Invoke(JavaBridge.java:1044) #-4 php.java.bridge.Request.handleRequest(Request.java:417) # in /FULL_PATH/Java.inc.php on line 195 I have chmod and chown to apache ; tomcat ; root as 0777 and all of them returns the same.Renaming the file returns file not found (obvious..), so the file is found but I cant solve the permission thing.. Rgds, Post Edited by robccsilva at 03/25/2011 18:45Post Edited by robccsilva at 03/25/2011 18:47 Link to comment Share on other sites More sharing options...
xok Posted March 25, 2011 Author Share Posted March 25, 2011 WooooooooHHHHHHHHoooooooooooo!!! Almost solved! Free keg is mine! /tools/fckeditor/editor/images/smiley/msn/teeth_smile.gif Starting the JavaBridge manually works properly with the following command:service tomcat6 stop/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/bin/java -Djava.ext.dirs="/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/jre/lib/ext:/usr/java/packages/lib/ext:/usr/share/java/tomcat6" -jar /var/lib/tomcat6/webapps/JavaBridge/WEB-INF/lib/JavaBridge.jar HTTP_LOCAL:8080 3 /JavaBridge.log With the command above I was able to export the report's PDF including the Arial font ( http://corefonts.sourceforge.net/ and tutorial and other page that I cannot find the link .. )[root@localhost ~]$ yum install cabextract rpm-buildWhen finished run the following as root[root@localhost build]$ wget http://corefonts.sourceforge.net/msttcorefonts-2.0-1.spec[root@localhost build]$ rpmbuild -ba msttcorefonts-2.0-1.spec[root@localhost build]$ rpm -ivh /usr/src/redhat/RPMS/noarch/msttcorefonts-2.0-1.noarch.rpm[root@localhost build]$ /sbin/service xfs reload So... why does TOMCAT says permission denied !? Link to comment Share on other sites More sharing options...
xok Posted April 5, 2011 Author Share Posted April 5, 2011 Need an expert opinion in here..I have edited the file nano /etc/rc.d/init.d/tomcat6 , removed the reference to the user TOMCAT and it started to generate reports properly.Doing this in this form is it insecure?Do you think it does any security issue?Java is overcomplicated to me... ---------------------------- before editing ------------------------- if [ "$SECURITY_MANAGER" = "true" ]; then $SU - $TOMCAT_USER -c "${TOMCAT_SCRIPT} start-security" \ >> $TOMCAT_LOG 2>&1 else $SU - $TOMCAT_USER -c "${TOMCAT_SCRIPT} start" >> $TOMCAT_LOG 2>&1 fi---------------------------- after editing ------------------------- if [ "$SECURITY_MANAGER" = "true" ]; then $SU -c "${TOMCAT_SCRIPT} start-security" \ >> $TOMCAT_LOG 2>&1 else $SU -c "${TOMCAT_SCRIPT} start" >> $TOMCAT_LOG 2>&1 fi------------------------------------------------------------------------- Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now