Odoo, a versatile suite of business management software, offers various installation methods tailored to different user needs and deployment scenarios. Whether you\'re looking for a quick trial, a fully managed cloud solution, or a custom on-premise setup, understanding the available options is crucial for a successful implementation.

This document provides a comprehensive overview of the primary Odoo installation choices, detailing their characteristics, advantages, and ideal use cases.

Overview of Odoo Installation Options

  • Demo Instances: The simplest way to quickly experience Odoo without any installation. Ideal for initial exploration and trying out features.
  • SaaS (Software as a Service): A fully managed, cloud-based solution provided by Odoo S.A. It offers ease of use and maintenance, suitable for both testing and production environments, though with some flexibility limitations.
  • Packaged Installers: Streamlined installation packages for various operating systems, offering greater control over hosting and data storage compared to SaaS, but shifting maintenance responsibilities to the user. Suitable for testing, module development, and production use with proper setup.
  • Source Installation: Provides the highest level of flexibility and control, allowing direct access to the Odoo source code. This method is particularly beneficial for module developers and custom deployments, enabling multiple Odoo versions on a single system and simplified contributions.
  • Docker Image: An official Docker base image is available for those who prefer containerized development or deployment environments, offering consistent and isolated setups.

Demo Instances

For users seeking a rapid introduction to Odoo, temporary demo instances are readily available. These shared instances are designed for short-term exploration, typically lasting a few hours, allowing users to navigate the system and experiment with features without any commitment or local installation. All that\'s required is a web browser to access these instances.

Odoo SaaS (Software as a Service)

Odoo\'s official SaaS offering provides private Odoo instances, often starting with a free tier. This cloud-based solution is an excellent choice for discovering and testing Odoo, as well as performing non-code customizations without having to install it locally. Similar to demo instances, Odoo SaaS requires only a web browser for access, simplifying the initial setup and ongoing management.

Packaged Installers

Odoo provides convenient packaged installers for various operating systems, including Windows and Debian-based (e.g., Debian, Ubuntu) and RPM-based (e.g., Fedora, CentOS, RHEL) Linux distributions. These packages automate the setup of all necessary dependencies, simplifying the initial deployment process. While easy to get started with, maintaining these installations and keeping them up-to-date may require manual effort.

Official packages, complete with all relevant dependency requirements, can be downloaded from https://nightly.odoo.com.

Windows Installation

To install Odoo on a Windows system, follow these steps:

  1. Download the latest Odoo installer for Windows from https://nightly.odoo.com/8.0/nightly/exe/odoo_8.0.latest.exe.
  2. Execute the downloaded file to begin the installation process.

Warning: On Windows 8 and newer, you might encounter a "Windows protected your PC" warning. Click "More Info" and then "Run anyway" to proceed with the installation.

Accept the User Account Control (UAC) prompt. Follow the on-screen instructions through the various installation steps.

Odoo will automatically launch upon completion of the installation process.

Windows Configuration

The Odoo configuration file is located at %PROGRAMFILES%\\Odoo 8.0-id\\server\\openerp-server.conf. This file can be modified to configure settings such as connecting to a remote PostgreSQL database, adjusting file locations, or setting a database filter. After making changes to the configuration file, you must restart the Odoo service via Services ‣ odoo server for the changes to take effect.

Debian/Ubuntu (Deb-based Distributions) Installation

To install Odoo 8.0 on Debian-based distributions like Debian or Ubuntu, execute the following commands as a root user:

# wget -O - https://nightly.odoo.com/odoo.key | apt-key add -
# echo "deb http://nightly.odoo.com/8.0/nightly/deb/ ./" >> /etc/apt/sources.list
# apt-get update && apt-get install odoo

These commands will automatically install all required dependencies, set up Odoo as a daemon, and initiate its automatic startup.

Danger: For printing PDF reports, it is essential to manually install wkhtmltopdf. The version available in standard Debian repositories often lacks support for headers and footers, preventing automatic installation. The recommended version is 0.12.1, which can be found on the wkhtmltopdf download page in the archive section. For Debian Jessie users, where an official release might be unavailable, a compatible version can be obtained from http://nightly.odoo.com/extra/.

Debian/Ubuntu Configuration

The Odoo configuration file for Debian-based systems is located at /etc/odoo/openerp-server.conf. After any modifications to this file, Odoo must be restarted using the service command:

$ sudo service odoo restart
Restarting odoo: ok

RHEL/CentOS (RPM-based Distributions) Installation

Warning: For RHEL-based distributions (RHEL, CentOS, Scientific Linux), it is necessary to add EPEL (Extra Packages for Enterprise Linux) to your system\'s repositories to ensure all of Odoo\'s dependencies are available. For CentOS, use the command: $ sudo yum install -y epel-release. Refer to the EPEL documentation for instructions on other RHEL-based distributions.

After ensuring EPEL is configured, proceed with the following commands:

$ sudo yum install -y postgresql-server
$ sudo postgresql-setup initdb
$ sudo systemctl enable postgresql
$ sudo systemctl start postgresql
$ sudo yum-config-manager --add-repo\=https://nightly.odoo.com/8.0/nightly/rpm/odoo.repo
$ sudo yum install -y odoo
$ sudo systemctl enable odoo
$ sudo systemctl start odoo

Danger: Similar to Debian, printing PDF reports requires the manual installation of wkhtmltopdf. The versions found in Fedora/CentOS repositories typically lack header and footer support, making automatic installation unsuitable. It is recommended to download a compatible version directly from the wkhtmltopdf download page.

RHEL/CentOS Configuration

On RPM-based systems, the Odoo configuration file is located at /etc/odoo/openerp-server.conf. Any changes made to this file necessitate restarting the Odoo service using SystemD:

$ sudo systemctl restart odoo

Source Installation

Choosing to install Odoo directly from its source code, rather than using a packaged installer, offers unparalleled flexibility and control. This method is particularly advantageous for module developers, as it provides easy access to the Odoo source for inspection, modification, or building custom documentation.

Source installation also allows for more explicit and flexible control over starting and stopping Odoo services, bypassing the default service configurations of packaged installations. It enables overriding settings via command-line parameters without constant configuration file edits. Furthermore, this approach facilitates a highly customizable system setup, making it easier to maintain and run multiple Odoo versions concurrently on the same machine.

Obtaining the Source Code

There are two primary methods for acquiring the Odoo source code:

  • Downloading a Zip Archive: The Odoo source code can be downloaded as a zip file from https://nightly.odoo.com/8.0/nightly/src/odoo_8.0.latest.zip. After downloading, simply uncompress the file to access its contents.
  • Using Git: Utilizing Git provides significant advantages, including simpler updates, effortless switching between different Odoo versions (including the latest development branches), and streamlined maintenance of custom patches and contributions. While a Git clone is larger due to containing the project\'s entire history, its benefits often outweigh this drawback for developers. The official Git repository is https://github.com/odoo/odoo.git. To download it, ensure you have a Git client installed (often available via your Linux distribution\'s package manager) and execute the following command:
    $ git clone https://github.com/odoo/odoo.git

Installing Dependencies

A source installation of Odoo necessitates the manual installation of its dependencies:

Python 2.7

  • On Linux and OS X: Python 2.7 is typically pre-installed.
  • On Windows: Download and install the official Python 2.7.9 installer.

    Warning: During installation, remember to select "add python.exe to Path" and reboot your system afterwards to ensure the PATH environment variable is updated correctly.

    Note: If Python is already installed, verify it is version 2.7.9. Earlier versions may be less convenient, and Python 3.x versions are not compatible with Odoo 8.0.

PostgreSQL

PostgreSQL is required for Odoo\'s database. After installation, you must create a PostgreSQL user, as Odoo cannot connect as the default \'postgres\' user.

  • On Linux: Install PostgreSQL using your distribution\'s package manager. Then, create a PostgreSQL user with the same name as your current system login:
    $ sudo su - postgres -c "createuser -s $USER"

    Using the same login name allows Odoo to connect via UNIX sockets without a password.

  • On OS X: Postgres.app offers the simplest way to get started. Afterwards, create a PostgreSQL user following the same procedure as on Linux.
  • On Windows: Install PostgreSQL for Windows. Then:
    • Add PostgreSQL’s bin directory (e.g., C:\\Program Files\\PostgreSQL\\9.4\\bin) to your system\'s PATH environment variable.
    • Create a PostgreSQL user with a password using the pgAdmin GUI: Open pgAdminIII, double-click the server to establish a connection, then select Edit ‣ New Object ‣ New Login Role. Enter a username (e.g., odoo) in the Role Name field, navigate to the Definition tab, and set a password (e.g., odoo). Click OK to finalize. This username and password must then be provided to Odoo using either the -w and -r command-line options or within the configuration file.

Python Dependencies

Install the Python dependencies listed in the requirements.txt file.

  • On Linux: Python dependencies can be installed via the system\'s package manager or using pip. For libraries that include native code (e.g., Pillow, lxml, greenlet, gevent, psycopg2, ldap), you may first need to install development tools and their native dependencies. These are typically found in -dev or -devel packages for Python, Postgres, libxml2, libxslt, libevent, libsasl2, and libldap2. Once these are in place, install the Python dependencies:
    $ pip install -r requirements.txt
  • On OS X: Install the Command Line Tools (xcode-select --install), then use a package manager like Homebrew or MacPorts to install non-Python dependencies. After that, pip can be used to install Python dependencies as on Linux:
    $ pip install -r requirements.txt
  • On Windows: Some dependencies require manual installation, and the requirements.txt file needs slight modification.
    • Install psycopg using the installer available at http://www.stickpeople.com/projects/python/win-psycopg/.
    • Edit the requirements.txt file:
      • Remove psycopg2, as it\'s already installed.
      • Remove the optional python-ldap, gevent, and psutil, as they require compilation.
      • Add pypiwin32, which is necessary for Windows environments.
    • Then, use pip to install the remaining dependencies from a cmd.exe prompt (replace \\YourOdooPath with your actual Odoo download path):
      C:\\> cd \\YourOdooPath
      C:\\YourOdooPath> C:\\Python27\\Scripts\\pip.exe install -r requirements.txt

Less CSS via Node.js

  • On Linux: Install nodejs and npm using your distribution’s package manager.

    Warning: On Debian Wheezy and Ubuntu 13.10 and earlier, nodejs must be installed manually:

    $ wget -qO- https://deb.nodesource.com/setup | bash -
    $ apt-get install -y nodejs

    In newer Debian (Jessie and later) and Ubuntu (14.04 and later) versions, you might need to create a symlink because npm packages often call node, but Debian names the binary nodejs:

    $ apt-get install -y npm
    $ sudo ln -s /usr/bin/nodejs /usr/bin/node

    Once npm is installed, use it to install less and less-plugin-clean-css globally:

    $ sudo npm install -g less less-plugin-clean-css
  • On OS X: Install nodejs via your preferred package manager (Homebrew, MacPorts), then install less and less-plugin-clean-css:
    $ sudo npm install -g less less-plugin-clean-css
  • On Windows: Install Node.js, then reboot your system (to update the PATH environment variable). Finally, install less and less-plugin-clean-css:
    C:\\> npm install -g less less-plugin-clean-css

Running Odoo

Once all necessary dependencies have been successfully set up, Odoo can be launched by executing the odoo.py script.

Configuration settings can be provided either through command-line arguments or by modifying a configuration file.

Key configurations that are frequently needed include:

  • PostgreSQL Host, Port, User, and Password: Odoo’s default connection behavior adheres to psycopg2’s defaults, which typically involve connecting over a UNIX socket on port 5432 using the current system user without a password. While this setup usually works seamlessly on Linux and OS X, it is incompatible with Windows, as Windows does not support UNIX sockets. Therefore, specific database credentials are often required on Windows.
  • Custom Addons Path: To load your custom modules, you will need to specify an addons path beyond the default locations.

A common way to execute Odoo on Windows would be:

C:\\YourOdooPath> python odoo.py -w odoo -r odoo --addons-path=addons,../mymodules --db-filter=mydb$

Here, odoo (the first instance) and odoo (the second instance) represent the PostgreSQL login and password, respectively. ../mymodules is a directory containing additional custom addons, and mydb specifies the default database to be served on localhost:8069.

On Unix-like systems, a typical execution command for Odoo is:

$ ./odoo.py --addons-path=addons,../mymodules --db-filter=mydb$

In this Unix example, ../mymodules refers to a directory containing supplementary addons, and mydb designates the default database to be served on localhost:8069.

Docker Image

For developers and system administrators who leverage Docker for their development or deployment workflows, an official Odoo Docker base image is available. This image provides a convenient and consistent environment for running Odoo, abstracting away many of the underlying system dependencies. Refer to the Docker image\'s official documentation for detailed usage instructions and further information on its configuration and capabilities.

Was this answer helpful? 0 Users Found This Useful (0 Votes)