Install OpenERP 6.1 on Debian Squeeze

You can always install the latest .deb files from OpenERP, but in this tutorial we will explain how to install OpenERP 6.1 manually from the latest build.

Prepare your Debian server

Create openerp user that will be used for running the OpenERP application


adduser --system --quiet --home=/opt/openerp --gecos 'OpenERP' --group openerp

Install PostgreSQL database server and add openerp as a postgres superuser

apt-get install postgresql
su - postgres -c "createuser -s openerp" 2> /dev/null || true

Install all the required dependencies for OpenERP

apt-get install python-dateutil python-feedparser python-gdata python-ldap \
    python-libxslt1 python-lxml python-mako python-openid python-psycopg2 \
    python-pybabel python-pychart python-pydot python-pyparsing python-reportlab \
    python-simplejson python-tz python-vatnumber python-vobject python-webdav \
    python-werkzeug python-xlwt python-yaml python-zsi

Install OpenERP 6.1 and configure the application

Get the latest OpenERP 6.1 install files and put them in /opt/openerp

cd /opt/openerp
tar zxvf openerp-6.1-latest.tar.gz
mkdir server
mv openerp-6.1-*/* server/

Now we are going to create full config file for OpenERP

chown openerp:openerp ./ -R
su - openerp -s /bin/bash -c "/opt/openerp/server/openerp-server -s -c /opt/openerp/openerp-server.conf"
mv /opt/openerp/openerp-server.conf /etc/openerp-server.conf
chown openerp:openerp /etc/openerp-server.conf
chmod 0640 /etc/openerp-server.conf

Creating log file

touch /var/log/openerp-server.log
chown openerp:openerp /var/log/openerp-server.log
chmod 0640 /var/log/openerp-server.log

Creating local storage directory

mkdir -p /var/lib/openerp/filestore
chown openerp:openerp -R /var/lib/openerp

Get our custom init script and place it in /etc/init.d/ and set it to start on boot

cd /etc/init/d
wget -O openerp-server
chmod +x openerp-server
update-rc.d openerp-server defaults

Change the default admin password and logfile in /etc/openerp-server.conf

vi /etc/openerp-server.conf
admin_passwd = <your-password>
logfile = /var/log/openerp-server.log

Start the OpenERP daemon

/etc/init.d/openerp-server start

Now open your browser to and start using OpenERP

OpenERP Front Page

You can also secure your application by creating reverse proxy using nginx shown in our earlier post.

OpenERP Documentation