Openbravo set-up in Ubuntu Feisty Fawn

Openbravo Logo

OpenBravo is a kind of software that can be classified as ERP (Enterprise Resource Planning). This means that it can be used to undertake, among other tasks, finance management, production management, warehouse management, billing, orders, etc. It allows the company management in almost every functional area.

Some examples of existing ERP software products are SAP, PeopleSoft, Oracle Applications and many more. The difference between Openbravo and the other software products is mainly that Openbravo is Open Source and Free Software. This means that Openbravo can be used freely for corporate or personal use. So, while other ERP software products had high license costs, Openbravo can be the low cost solution for many companies, specially for little and medium enterprise (SME).

Another advantage is that Openbravo is completely build for web environments, once installed in the server it is only needed a browser, like Firefox or Internet Explorer, in the client machines so final users could access the application.

In this article we explain the necessary steps to set-up Openbravo in a PC or Server with Ubuntu Feisty Fawn operating system, but with a few changes it could be installed in an older Ubuntu version or even other GNU/Linux distributions.

Requirements
We assumed that you have a PC or Server with Ubuntu Feisty Fawn operating system installed and upgraded with the latest patches. It is also necessary to have an Internet connection in order to download Openbravo software and some additional packages from the Ubuntu repository.

Note:
All the steps described in the following sections must be executed with super user rights "root", so the command sudo must be placed at the beginning of each command.

In case you Ubuntu installation is not upgraded with the latest patches, you can do it with the following commands typed in the linux console:

sudo apt-get update
sudo apt-get upgrade

Setup Java SDK
Given that Openbravo is build using Java programming language, the Java SDK 1.5 or higher is needed. We choose Java SDK 6, the latest release at the moment.

To install type the following commands:

sudo aptitude install sun-java6-jdk sun-java6-plugin

after accepting the license agreements, the software is ready to be used. An additional step must be done in to configure Java 6 SDK as the default runtime for Java applications.

sudo update-java-alternatives -s java-6-sun

set-up Tomcat
Next step consists in setting up the application server were Openbravo must be deployed. This is Tomcat, version 5.0 or higher is needed. We choose version 5.5. Ant 1.6 ot higher is also needed to compile and deploy the software automatically into Tomcat.

To install these software type the following commands:

sudo aptitude install tomcat5.5 tomcat5.5-admin ant

Tomcat configuration must be changed in order to work properly in Ubuntu. First we force Tomcat to use Java SDK 6 installed previously.

Edit the configuration file

sudo vi /etc/default/tomcat5.5

uncomment the following line

#JAVA_HOME=/usr/lib/jvm/java-1.5.0-sun

and modify it to

JAVA_HOME=/usr/lib/jvm/java-6-sun

pointing to Java SDK 6.

The file "catalina.out" must be changed to the correct owner and permissions. Change to Tomcat folder, erase the existing file, create a new empty version, change the owner to "tomcat55" and set the correct file permissions.

cd /var/log/tomcat5.5/
sudo rm catalina.out
sudo touch catalina.out
sudo chown tomcat55:nogroup catalina.out
sudo chmod uo-wrx catalina.out

Tomcat environment variables must be set for every user in the Operating System. You can do this with the following commands:

sudo echo "CATALINA_HOME=/usr/share/tomcat5.5" >> /etc/environment
sudo echo "CATALINA_BASE=/var/lib/tomcat5.5" >> /etc/environment
sudo echo "CATALINA_OPTS=-server -Xms384M -Xmx512M" >> /etc/environment
sudo echo 'ANT_HOME=/usr/share/ant' >> /etc/environment

Finally, regarding Tomcat, due to a security policy in Debian based distributions (like Ubuntu), it is necessary to create this policy or deactivate it. If you omit this step, the context for Openbravo could not be loaded in Tomcat server.

In our example we deactivate this option

sudo vi /etc/init.d/tomcat5.5

find the option

TOMCAT_SECURITY=YES

and change to NO

TOMCAT_SECURITY=NO

This options will be valid the next time you start Tomcat

sudo /etc/init.d/tomcat5.5 restart

Setup PostgreSQL
Openbravo, like other ERP products, store the information in data bases. This date bases, or better said, Data Base Management Systems, can be Oracle or PostgreSQL. We choose PostgreSQL because it is OpenSource and Free Software. It is also possible to use a free version of Oracle, but with lots of limitations.

To install PostgreSQL type

sudo aptitude install postgresql-8.1

Once installed it is recommended to modify the password for the PostgreSQL administration user. We do this with the following commands:

/usr/lib/postgresql/8.1/bin/psql -U postgres

inside the SQL client, execute the DDL command

ALTER USER postgres PASSWORD 'postgres';

Setup Openbravo
We are in the final steps of this large set-up process. First we have to download Openbravo software. It is placed in the URL:

http://sourceforge.net/project/showfiles.php?group_id=162271

Download version 2.22 the last stable version at the moment, "OpenbravoERP-2.22-UniversalInstaller_linux.bin".

It is a binary file with a set-up wizard, so we need to change the execution rights first

sudo chmod u+x Desktop/OpenbravoERP-2.22-UniversalInstaller_linux.bin

change to the folder where the file is located and execute it

cd Desktop
sudo ./OpenbravoERP-2.22-UniversalInstaller_linux.bin

If everything works fine you will see the welcome screen of the installation wizard

Openbravo setup wizard

Click "Next"

Openbravo setup wizard

Accept license agreement and click "Next"

Openbravo setup wizard

Accept default target folder and click "Next"

Openbravo setup wizard

Choose "Full" and click "Next"

Openbravo setup wizard

Choose "Full" and click "Next"

Openbravo setup wizard

Choose "PostgreSQL" and click "Next".

Openbravo setup wizard

browse to the folder where Java SDK is located and click "Next"

Openbravo setup wizard

browse to the folder where Ant is located and click "Next"

Openbravo setup wizard

Browse where "Tomcat" is located and click "Next"

Openbravo setup wizard

It is possible that a warning message appears when you click Next, saying that Tomcat version is not correct. Accept the warning and continue to the next step.

Openbravo setup wizard

Set the configuration options for Tomcat

Openbravo setup wizard

Set the path where PostgreSQL binaries are located

Openbravo setup wizard

Set the configuration options for PostgreSQL and the name of the data base where objects will be created

Openbravo setup wizard

Type the PostgreSQL administrator password.Remember that we've changed it previously.

Openbravo setup wizard

Set the user and password that will be the owner of the data base objects for Openbravo

Openbravo setup wizard

The creation of data base objects and java code compilation starts. This process can last for more than an hour, depending on the machine performance. Be patien. Anyway, you can monitor this proces opening the gnome system monitor and check CPU and memory usage. Yo can also list compilation log contents:

tail -f /opt/OpenbravoERP-2.22/install_logs_all/src.log

When the process finishes it is necessary to restart Tomcat so the file "openbravo.war" was deployed.

/etc/init.d/tomcat5.5 restart

Now users can access Openbravo in the URL http://localhost:8180/openbravo, whith the user "openbravo" and password "openbravo".

Proceso de instalación de Openbravo

installing open bravo 2.40

Dear Sir/Madam,

First of all my apologies not speaking Spanish.

Your instructions are great; perfect so to say.

Only I install postgres 8.2, just because 8.1 is not anymore in synaptic, using sudo of course.

In the past I had some config. problems with configuring postgesql. I did not notice that in your instructions.Maybe it is not relevant.
Especially hba, by the way for me this is all chinese so to say. If u interested I have the hba and main config file regarding postgresql 8.2 carefully stored and maybe u like to receive them. Also I am wondering that apache should aperantly not installed??

I am ignorant in these kinds of stuff. To be honest I just copy and paste the commands. I read of course the comments but more than 50% it is for me uknown..................

NOW I WRITE CAPITAL LETTERS!!. THE INSTRUCTIONS issued by OPEN BRAVO on their website (even special for Ubuntu) WERE JUST BAD IN THIS RESPECT.

AND TO MY PERSPECTIVE THE TOMCAT WITH WEBAPPS WITH JAVA WAS THAT ALL WAS NOT GOING ACCORDING TO OPNENBRAVO INSTRUCTIONS BECAUSE IN YOUR INSTRUCTION YOU DO GIVE EXTRA ATTENTION TO THIS....CONSEQUENCE EXTRA COMMAND CODES,....BY THE WAY I DONT HAVE THE CLUE OF THIS...JUST COPY PASTE.

Would you like contacting me you can of course: f.van.der.star@gmail.com. DO NOT HESITATE.

AGAIN SO MANY THANKS; MUCHOS GRACIAS

greetings
Frans van der Star
Pajos Bajos (Netherlands)
and
for some months Malaysia

I do hope for some reply
bye

Many thanks for your comments

Hy Frans, thanks for contributing to my blog. I'm sorry but most of the comments in this article are spanish. I recommend you to use Google translator to translate the spanish version, this way you will be able to understand the comments.

Regarding the configuration files, if you want to send them to david@moixo.com, i will attach them to the articles.

Hope to hear from you.

Terminal Install

how do i install the openbravo erp through terminal?

Thank You

Thank you very much.

Post new comment