Prepare the tomcat server and java environment
Install the correct java jdk
sudo apt-get install openjdk-6-jdk
If there are more java environments on the server choose the correct default (openjdk-6-jdk)
sudo update-alternatives --config java
Install the java application server Tomcat
sudo apt-get install tomcat7 tomcat7-docs tomcat7-examples tomcat7-admin
Add an admin user to the webbased admin of tomcat to deploy your war file
sudo vi /etc/tomcat7/tomcat-users.xml
Add the underlying xml between the <tomcat-users> </tomcat-users> of the file you opened
<role rolename="admin-gui"/>
<role rolename="manager-gui"/>
<role rolename="manager-script"/>
<role rolename="manager-jmx"/>
<role rolename="manager-status"/>
<user username="admin" password="password" roles="admin-gui,manager-gui,manager-script,manager-jmx,manager-status"/>
Restart tomcat to activate the user and roles
sudo /etc/init.d/tomcat7 restart
Check if the Tomcat server is running and if you’re able to get in the manager app
http://servername-ip:8080
Build and deploy Pentaho-reports to tomcat application server
Install Ant and Ivy
sudo apt-get install ant ivy wget unzip
Download and extract Pentaho Reports
mkdir /opt/pentaho_report
cd /opt/pentaho_report
If you have a OpenERP 6.1 Server you need to use the following:
wget https://github.com/WillowIT/Pentaho-reports-for-OpenERP/archive/version61.zip
unzip version61.zip
There is also a good functioning OpenERP 7.0 version:
wget https://github.com/WillowIT/Pentaho-reports-for-OpenERP/archive/version70.zip
unzip version70.zip
Build Java Server for Pentaho Reports (I do the build for version 7, you could do the same for version 61 and even run both versions on 1 server)
cd Pentaho-reports-for-OpenERP-version70
cd java_server
ant -lib /usr/share/java war
If the build is succesfull then a war file “pentaho-reports-for-openerp.war” will be found in the /opt/openerp/pentaho_report/Pentaho-reports-for-OpenERP-version70/java_server/build/jar folder.
You need to deploy this “pentaho-reports-for-openerp.war” on Tomcat.
You can do this in two ways: (I added the route of autodeployement for easy install)
- By going to the Tomcat Manager (http://servernameorip:8080/manager)
Follow the Tomcat instructions for deploying/installing war files. You could use the deploy a war file to upload the war file and create an instance. If you create the war file on a different machine then where you deploy the war file. Check that you use the same java environment. - By copying the war file to the webapps folder of your tomcat installation for autodeployment:
cp /opt/pentaho_report/Pentaho-reports-for-OpenERP-version70/java_server/build/jar/pentaho-reports-for-openerp.war /var/lib/tomcat7/webapps
Finally the Pentaho Reports Java Application should be available at http://servernameorip:8080/pentaho-reports-for-openerp
[…] Below is how to get from another blog,http://www.schenkels.nl/2013/04/creating-a-pentaho-reporting-server-ubuntu-12-04-openerp/ […]
Im getting this Error
BUILD FAILED
/opt/pentaho_report/Pentaho-reports-for-OpenERP-version70/java_server/build-res/subfloor.xml:1160: Compile failed; see the compiler error output for details.
Total time: 1 second
Nice Post
I am using odoo 8 now how can i integrate pentaho on Odoo 8
i try to install the pentaho_report module but in Settings -> Technical -> Actions -> Reports not possible to add prpt file any one know how to rectify this?
thank you for this support ,
BUILD FAILED
/root/Pentaho-reports-for-OpenERP-version70/java_server/build-res/subfloor.xml:1160: Compile failed; see the compiler error output for details.
Hello I have a new issue with Openerp and Pentaho.
The connection is fine if I use the database with demo data. But if I use a database with auth_crypt I cannot acces the reports. It says username or/and password wrong.
I guess the password from the pentaho settings in Openerp is also encrypted. Can someone verify this, or has somenone an idea how to solve this.
The auth_crypt can also not be uninstalled, because afterwards I could not access the database anymore 🙁
Thx Oliver
You can update the password with the psql tools
login to the server and type:
sudo su postgres
psql databasename
UPDATE res_users SET password=’password’ WHERE ID=1;
\q
exit
If you want to use Pentaho Reporting with auth_crypt you need to tweak the pentao openerp module. I’ve done this and can help you if you like.
André
Thanks for answer. I just tried with the admin and passwort recovery to test if this was the reason, and it is the reason.
I am testing this currently to check if it fits for my client, but will come back to you
I was looking forward to get a way to start with Pentaho reporting in OpenErp. Thank you man!
Hi, when i write ant -lib /usr/share/java war, i got the following error:
BUILD FAILED /opt/pentaho_report/Pentaho-reports-for-OpenERP-version70/java_server/build-res/subfloor.xml:1160: Compile failed; see the compiler error output for details.
thanks for advanced.
Did you do the compile with sudo? Or just as a normal user?
HI we have tried with sudo but the problem still persisting
thinks
hi @ANDRÉ SCHENKELS I am also facing same issue
Hi Andre,
I have a strange thing. Created the war file with ant.
I can run “ant launch” for the pentaho-reports-for-openerp.war and it works on port 8090 from OpenErP.
I try to deploy the war file on the standard tomcat 6 with pentaho-be-ce – it generates the sub dir “pentaho-reports…for openerp”, but the report in OpenERP generates an error:
ProtocolError:
Pentaho itself is running and I can login. It is just the connection which is not working and driving me nuts.
Thanks for help in advance
Oliver
After hours of searching I finally found the error
The generated war file had “-7.5.1” at the end.
So the correct settings in OE for the pentaho link is:
http://localhost:8080/pentaho-reports-for-openerp-7.5.1/
Thank you for the input. I should revise this post because of new versions. Maybee that’s why you got this problem.
Hi André,
I also have the following error message:
HTTP Status 405 – HTTP method GET is not supported by this URL
What can I do?
This is normal when you enter the url of the Pentaho Reporting server.
Hi André, Could you please explain more about HTTP Status 405?
Thanks for such valueable information. I got the following error during the installation:
BUILD FAILED
/opt/pentaho_report/Pentaho-reports-for-OpenERP-version70/java_server/build.xml:27: impossible to ivy retrieve: java.lang.RuntimeException: problem during retrieve of com.willowit#pentaho-reports-for-openerp: java.io.FileNotFoundException: /opt/pentaho_report/Pentaho-reports-for-OpenERP-version70/java_server/build/lib/build/bsf.jar (No such file or directory)
I’ve to check the latest code base op the Pentaho Reports for OpenERP module. Maybee it’s a problem with the code. You could try an older version to see if it works.
It’s been a long time since the last time I was here, thanks for the reply, where can I find this older version? Would the procedure be the same?
Hello Andre
The install went fine tomcat 7 is up and running but when I type in the url http://localhost:8080/pentaho-reports-for-openerp, I get the following error message
HTTP Status 405-HTTP method GET is not supported by this URL
you know what…..i spent a day struggling with tomcat admin login. tried so many things. you were the first to suggest tomcat restart..
sudo /etc/init.d/tomcat7 restart
i tried restarting apache many times believing wrongly that apache restart would force tomcat restart (and not knowing how to restart tomcat)…thank you…thank you
Yes java already installed on system. When I try to exeucte your command not it start to give error me of : We cannot execute /usr/lib/jvm/java-7-openjdk/bin/java
Thanks for nice blog
I followed all your but not build succefully
It show me
BUILD FAILED
/opt/pentaho_report/Pentaho-reports-for-OpenERP-version70/java_server/build.xml:32: Compile failed; see the compiler error output for details.
Is the server a brand new Ubuntu 12.04LTS server or are you installing it on a existing installation.
You could try: ant -lib /usr/share/java launch
Wich launches the java server for testing perposes.
(http://serverip:8080) will be the pentaho server address you can use in OpenERP module.
Was Java already installed on the system?