ADempiere Install Linux&PostgreSQL

From ADempiere ERP Wiki

(Redirected from ADempiere Install)
Jump to: navigation, search

Warning: The available IzPack installer package is outdated, please go to the Getting Started page for other alternative.

Installation instructions:

Contents

Linux & PostgreSQL

This document describes the process of installing a fresh ADempiere using the installer install-linux.jar. The package contains the sources of a PostgresSQL-8.* server which will be compiled and installed in the process. For Ubuntu users, see also Ubuntu Install Howto.

Pre-requisites

  • GNU make 3.76.1 or later.
  • gcc compiler
  • The tar utility
  • The readline library
  • The readline-devel library
  • The zlib compression library
  • The zlib-devel compression library
  • JAVA_HOME variables declared for postgres user
 export JAVA_HOME=/app/java/jdk1.5.0_08/
 export PATH=$JAVA_HOME/bin:$PATH
  • PostgreSQL not installed, not running
 ie : wget http://ufpr.dl.sourceforge.net/sourceforge/adempiere/install-linux.jar

The latest version of ADempiere can be found here http://sourceforge.net/project/showfiles.php?group_id=176962 and if you encounter difficulties with this wiki page you may find a newer version that corrects these issues. In that case you may end up with a file named something like ADempiere311-PG-linux.jar which you could substitute for install-linux.jar, or rename.

Process Installation

  • Open a linux terminal
  • Execute: xhost +
  • Create a postgres user as root, log on as postgres and execute the installer
 $ su
 # useradd -d /home/postgres -m postgres
 # chown -R postgres /home/postgres/
 # passwd postgres
 $ su - postgres
 $ java -jar /path-to/install-linux.jar
  • Follow the steps:


  • Choose your language


Image:install.jpg


  • Read the press release



  • Read the license and Accept it, if you are agree



  • Here are the components to Install



  • Select the Directory to Install it, the Default directory is /home/postgresql/Adempiere



  • Start the install process, please wait until this process finish it could take some time.


Please notice the section below "Common Issues" that identfies some of the typical problems you may encounter when installing Adempiere.


  • Accept the license of Adempiere



Finish the installation


Image:install10.jpg

  • Exit of Install program


  • Execute utils/RUN_Server2.sh &
 postgres@vpj-cd:~/Adempiere/Adempiere2/utils> ./RUN_Server2.sh &
 /home/postgres/Adempiere/Adempiere2/jboss/bin/run.conf: line 52: syntax error: unexpected end of file
 =========================================================================
 JBoss Bootstrap Environment
 JBOSS_HOME: /home/postgres/Adempiere/Adempiere2/jboss
 JAVA: /app/java/jdk1.5.0_08/bin/java
 JAVA_OPTS: -server -Xms64M -Xmx512M -DCOMPIERE_HOME=/home/postgres/Adempiere/Adempiere2  -Djava.awt.headless=true -Dprogram.name=run.sh
 CLASSPATH: /home/postgres/Adempiere/Adempiere2/jboss/bin/run.jar:/app/java/jdk1.5.0_08/lib/tools.jar
 =========================================================================
 13:59:49,953 INFO  [Server] Starting JBoss (MX MicroKernel)...


  • Finally execute ./RUN_Compiere2.sh
 postgres@vpj-cd:~/Adempiere/Adempiere2> sh RUN_Compiere2.sh
  • Ready now you can enjoy of the open source world

Adempiere splash

Image:install12.jpg

  • Login Screen ( SuperUser default password: System )

Image:install13.jpg


  • Role Screen

Image:install14.jpg

  • Main Adempiere Screen


Common Issues

Configuring PostgreSQL...ERROR!

If you receive the following screen during installation,

Image:Postgresserror2.png

This is usually a postgresql requirement that is not present in your system. You may try doing the following

    $cat /home/postgres/cat /home/postgres/Adempiere/install.log
    checking for library containing getopt_long... none required
    checking for main in -lunix... no
    checking for library containing crypt... -lcrypt
    checking for library containing fdatasync... none required
    checking for shmget in -lcygipc... no
    checking for readline... no
    configure: error: readline library not found
    If you have readline already installed, see config.log for details on the
    failure.  It is possible the compiler isn't looking in the proper directory.
    Use --without-readline to disable readline support.
    ERROR!

This will indicate which postgres requirement you are missing.

You will need to resolve the postgres dependency before you try to proceed once again. Please consult your distribution to install the required package.

You must delete the Adempiere directory and start the installation process once again.

    $rm -rf /home/postgres/Adempiere

If you don't delete the Adempiere directory and run the installer once again you will receive the following message:

Image:Postgresqlinstallerror1.png

java: command not found

If you receive the following message from the console:

    $ java /usr/share/install-linux.jar
    -bash: java: command not found

You should check your java environment variables.

    $echo $JAVA_HOME
    $echo $PATH

Web Port 80 Error

If you receive the following message from the installer:


Image:Adempiereerror1.png

It means that postgres user is not allowed to use those ports, so they need to be changed. WebPort 8088 and SSL 4443 are recommended.

Database Port 5432 Error

When you get this message:

Image:Databaseporterror.png

And if you have two network cards, you should try to modify your etc/hosts and include both cards for your host name. Another option is that you fill on database server the server ip address rather than the host name.

If you get "Error Database Port (DB Server Port = 5432)", change the 'Database Server' from <your-computer-name> to localhost. The alternative is to use a fixed IP address on your server or desktop and put this address in the Database Server, or if you have a laptop then you need to install a loopback adapter

Database name, type and passwords

  • Note: Adempiere's database name is adempiere, sysdba password is adempiere and database type postgresql



JDBC Connection Error

  • If you get this error, you need to execute the next steps:



 Open a linux xterminal
 su postgres
 cd /home/postgres/Adempiere/postgresql/8.1.4/pgdata
 edit pg_hba.conf 
 # CAUTION: Configuring the system for local "trust" authentication allows
 # any local user to connect as any PostgreSQL user, including the database
 # superuser. If you do not trust all your local users, use another
 # authentication method.
 # TYPE  DATABASE    USER        CIDR-ADDRESS          METHOD
 # "local" is for Unix domain socket connections only
 local   all         all                               trust
 # IPv4 local connections:
 host    all         all         127.0.0.1/32          trust
 # IPv6 local connections:
 host    all         all         ::1/128               trust
 host all all {Set your IP}/32 trust
 /home/postgres/Adempiere/postgresql/8.1.4 # . ./PGSQL.env
 /home/postgres/Adempiere/postgresql/8.1.4 # cd bin
 /home/postgres/Adempiere/Adempiere/postgresql/8.1.4/bin> ./pg_ctl restart
  waiting for postmaster to shut down.... done
  postmaster stopped
  postmaster starting
  postgres@vpj-cd:~/Adempiere/postgresql/8.1.4/bin> LOG:  database system was shut down at 2006-10-17 13:37:52 CDT
  LOG:  checkpoint record is at 0/40CCF90
  LOG:  redo record is at 0/40CCF90; undo record is at 0/0; shutdown TRUE
  LOG:  next transaction ID: 5847; next OID: 102779
  LOG:  next MultiXactId: 1; next MultiXactOffset: 0
  LOG:  database system is ready
  LOG:  transaction ID wrap limit is 2147484146, limited by database "postgres"

This problem appears when you have multiple network interfaces, the script always finds eth0 but if this doesn't have an ip address, the file pg_hba.conf will be incorrect. This is why you need to modify your ip address of the active network interface.

  • Now the setup should work without problems

JNP Port 1099 Error

  • Another possible error is "Server Setup Error Error JNP Port (Not correct: JNP Port = 1099) OK"

If you recieve an JNP Port = 1099 error it might be caused by another process already attached to that TCP port. You can discover the other process by doing the following:

   # netstat -lapevn | grep 1099
   tcp        0      0 0.0.0.0:1099                0.0.0.0:*                   LISTEN      500        6288363    11389/java

or

   [root@RedEye postgres]# fuser -n tcp 1099
   1099/tcp:            11389

And 11389 is the Process ID that has TCP port 1099 in use. Then use

   [root@RedEye postgres]# ps aux | grep 11389

to see the process and you can take steps to stop it.

(Something more might be explained here or referenced here to describe the impact of two processes wanting to use TCP port 1099.)

Links

Personal tools