frePPLeOpen source Production Planning
  • Home
  • Documentation
  • C++ API

Linux binary packages

Supported distributions
Installation and configuration
Debian installation script
Red Hat Enterprise Linux installation script

Supported distributions

Binary installation packages are available for the following Linux distributions:

  1. Fedora 16 and higher
    FrePPLe is included in the official repositories.
    fedora install

  2. Red Hat Enterprise Linux 6
    Starting from release 2.1 a 64-bit binary package can be downloaded.

  3. Ubuntu 12 LTS
    A 64-bit binary package is provided starting from release 2.1.

Other Linux distributions aren’t really a problem, but you’ll need to build the frePPLe package from the source code .deb or .rpm files, as described on the next page. The build process is completely standardized.

Installation and configuration

The binary package installs the solver engine executables as well as the user interface. The user interface is installed as a WSGI application deployed on the Apache web server with the mod_wsgi module.

Here are the steps to get a fully working environment.

  1. Install the database
    PostgreSQL is the preferred database for frePPLe.
    It’s recommended to use UTF-8 as the encoding of the database.
    For optimal performance the default memory allocation parameters will need to be increased from their defaults. The appropriate settings depend on the model size, the number of concurrent users and the available memory on the server. The most important parameter is “shared_buffers” (which normally requires changing the Linux kernel parameter shmmax as well).
    For the user that will run the user interface application (normally “www-data” on debian and “apache” on rhel) you need to create a file .pgpass in their home directory. This allows them to connect without entering a password.
    See the Django documentation at http://docs.djangoproject.com/en/dev/ref/databases/ for more details.
    This step can be skipped if you want to use SQLite as the database.

  2. Create the database and database user
    A database needs to be created for the default schema, and one for each of the what-if scenarios you want to configure.
    A single database user can be used as the owner of these schemas.
    This step can be skipped if you want to use SQLite as the database.

  3. Install the Python database drivers
    You’ll need to install the python-psycopg2 package for PostgreSQL.
    Oracle requires the cx_oracle package, while MySQL requires python-mysql.
    This step can be skipped if you want to use SQLite as the database.

  4. Install Django
    Since frePPle requires some patches to the standard Django package, you can’t install the binary package that comes with your Linux distribution.
    Instead, download the source from http://www.djangoproject.com and expand it in a local folder.
    Next, apply the patch found here and install the package.
    The shell commands for these steps are:

       wget https://www.djangoproject.com/download/1.6/tarball/
       tar xvfz Django-1.6.tar.gz
       cd Django-1.6
       patch -p0 < frepple_directory/contrib/django/django.patch
       python setup.py install
  5. Install OpenPyXL
    This python package allows us to read and write Excel spreadsheet files. It is best to install it from PyPi using pip.

       pip install openpyxl

    Most linux distributions don’t install pip by default, so you’ll need to install that first. See below for the commands for this on Ubuntu and RHEL.

  6. Install the frepple binary package
    On fedora:

       yum install frepple

    On Ubuntu: Download the binary deb file and use the following command.

       dpkg -i frepple_*.deb
       apt-get -f -y -q install

    On RHEL: Download the binary RPM file and use the following command.

      yum --nogpgcheck localinstall  *.rpm
  7. Configure frePPLe
    The previous step installed a number of configuration files, which you now need to review and edit:

    • /etc/frepple/djangosettings.py
      Edit the “DATABASES” with your database parameters.
    • Change “SECRET_KEY” to some arbitrary value – important for security reasons.

    • /usr/share/frepple/license.xml
      The installation provides a license file for the community edition.
    • If you are using the enterprise edition, replace this file with the license file you received from us.

    • /usr/share/frepple/init.xml
      Comment out the lines loading modules you are not using.
    • /etc/httpd/conf.d/z_frepple.conf
      For a standard deployment this file doesn’t need modification.
      It only needs review if you have specific requirements for the setup of the Apache web server.
  8. Create the database schema
    Your database schema is still empty till now. The command below will create all objects in the database schema and load an initial demo dataset.

       frepplectl syncdb
  9. Verify the installation
    If all went well you can now point your browser to http://localhost and use frePPLe.
    Three default logins are created: “admin”, “frepple” and “guest”. The password is identical to the user name.
    For security reasons it is recommended you remove this default accounts in actual production environments.
    Try the following as a mini-test of the installation:
    - Open the screen “input/demand” to see demand inputs.
    - Open the screen “admin/execute” and generate a plan.
    - Use the same “admin/execute” screen to copy the default data in a new scenario.
    - Open the screen “output/resource report” to see the planned load on the resources.
    If these steps all give the expected results, you’re up and running!

Debian installation script

This section shows the completely automated installation script for installing and configuring frePPLe with a PostgreSQL database on a Debian server.

We use this script for our unit tests. You can use it as a guideline for your own disaster recovery scripts.

  # Bring the server up to date with the latest and greatest
  sudo apt-get -y -q update
  sudo apt-get -y -q upgrade

  # Install PostgreSQL
  sudo apt-get -y install postgresql-9.1 python-psycopg2
  sudo su - postgres 
  psql template1 -c "create user frepple with password 'frepple'"
  psql template1 -c "create database frepple"
  psql template1 -c "grant all privileges on database frepple to frepple"
  psql template1 -c "create database scenario1"
  psql template1 -c "grant all privileges on database scenario1 to frepple"
  psql template1 -c "create database scenario2"
  psql template1 -c "grant all privileges on database scenario2 to frepple"
  psql template1 -c "create database scenario3"
  psql template1 -c "grant all privileges on database scenario3 to frepple"
  sed -i 's/peer$/md5/g' /etc/postgresql/9.1/main/pg_hba.conf
  service postgresql restart
  exit

  # Install Django
  wget -q -O Django-$DJANGORELEASE.tar.gz https://www.djangoproject.com/download/$DJANGORELEASE/tarball/
  tar xfz Django-$DJANGORELEASE.tar.gz
  cd ~/Django-$DJANGORELEASE
  patch -p0 < frepple_directory/contrib/django/django.patch
  sudo python setup.py install

  # Install openpyxl
  sudo apt-get -y install python-pip
  sudo pip install openpyxl

  # Install frePPLe binary .deb package
  # This also installs the necessary dependencies
  cd ~
  sudo dpkg -i frepple_*.deb
  sudo apt-get -f -y -q install

  # Configure frepple
  sudo sed -i "s/django.db.backends.sqlite3',$/django.db.backends.postgresql_psycopg2',/g" /etc/frepple/djangosettings.py

  # Configure apache web server
  sudo a2enmod expires
  sudo a2enmod wsgi
  sudo a2enmod ssl
  sudo a2ensite default-ssl
  sudo a2ensite frepple
  sudo service apache2 restart

  # Create frepple database schema
  frepplectl syncdb --noinput

  # Make postgresql accessible for apache user without password
  sudo sh -c 'echo "localhost:5432:frepple:frepple:frepple" > ~www-data/.pgpass'
  sudo sh -c 'echo "localhost:5432:scenario1:frepple:frepple" >> ~www-data/.pgpass'
  sudo sh -c 'echo "localhost:5432:scenario2:frepple:frepple" >> ~www-data/.pgpass'
  sudo sh -c 'echo "localhost:5432:scenario3:frepple:frepple" >> ~www-data/.pgpass'
  sudo chown www-data:www-data ~www-data/.pgpass
  sudo chmod 0600 ~www-data/.pgpass

Red Hat Enterprise Linux installation script

This section shows the completely automated installation script for installing and configuring frePPLe with a PostgreSQL database on a RHEL 6 server.

We use this script for our unit tests. You can use it as a guideline for your own disaster recovery scripts.

  # Update and upgrade
  sudo -S -n yum -y update

  # Install the PostgreSQL database
  sudo yum install postgresql postgresql-server python-psycopg2
  sudo service postgresql initdb
  sudo service postgresql start
  sudo su - postgres 
  psql -dpostgres -c "create user frepple with password 'frepple'"
  psql -dpostgres -c "create database frepple"
  psql -dpostgres -c "grant all privileges on database frepple to frepple"
  psql -dpostgres -c "create database scenario1"
  psql -dpostgres -c "grant all privileges on database scenario1 to frepple"
  psql -dpostgres -c "create database scenario2"
  psql -dpostgres -c "grant all privileges on database scenario2 to frepple"
  psql -dpostgres -c "create database scenario3"
  psql -dpostgres -c "grant all privileges on database scenario3 to frepple"
  sed -i 's/peer$/md5/g' /var/lib/pgsql/data/pg_hba.conf

  # Install django
  wget -q -O Django-$DJANGORELEASE.tar.gz https://www.djangoproject.com/download/$DJANGORELEASE/tarball/
  tar xfz Django-$DJANGORELEASE.tar.gz
  cd ~/Django-$DJANGORELEASE
  patch -p0 < ~/frepple-$RELEASE/contrib/django/django.patch
  sudo -S -n python setup.py install

  # Install openpyxl
  # The sequence is a bit weird: we first enable the EPEL repository, then install pip, and 
  # finish by installing openpyxl itself.
  sudo -S -n rpm -Uvh http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm
  sudo -S -n yum -y install yum-plugin-protectbase.noarch
  sudo -S -n yum -y install python-pip
  sudo pip install openpyxl

  # Build frepple RPM
  yum --nogpgcheck localinstall  *.rpm

  # Make PostgreSQL accessible for apache user
  sudo sh –c ‘echo “localhost:5432:frepple:frepple:frepple” > ~apache/.pgpass’
  sudo sh –c ‘echo “localhost:5432:scenario1:frepple:frepple” >> ~apache/.pgpass’
  sudo sh –c ‘echo “localhost:5432:scenario2:frepple:frepple” >> ~apache/.pgpass’
  sudo sh –c ‘echo “localhost:5432:scenario3:frepple:frepple” >> ~apache/.pgpass’
  sudo chown apache:apache ~apache/.pgpass
  sudo chmod 0600 ~apache/.pgpass
    • Getting started
      • 1 – Introduction
      • 2 – Installation
      • 3 – Entering data
      • 4 – Modelling concepts
      • 5 – Your first model
      • 6 – Your first plan
    • Modeling guide
      • Simplified domain model
      • Detailed domain model
      • Environment variables
      • Python interpreter
      • Global parameters
      • Buffer
      • Calendar
      • Customer
      • Demand
      • Flow
      • Item
      • Load
      • Location
      • Operation
      • Suboperation
      • Operationplan
      • Problem
      • Resource
      • SetupMatrix
      • Skill
      • Resource skill
      • Solver
    • User guide
      • Supported browsers
      • Getting around
        • Logging in
        • Logging out
        • Changing password
        • Navigation
          • Menu bar
          • Jump search
          • Context menus
        • Filtering data
        • Sorting data
        • Selecting time buckets
        • Exporting data
        • Importing data
        • Customizing a screen
        • User preferences
        • User permissions and roles
        • Comments
        • History – Audit trail
      • Data maintenance screens
      • Supply Path / Where Used
      • Plan analysis screens
        • Problem report
        • Constraint report
        • Inventory report
        • Inventory detail report
        • Resource report
        • Resource Gantt report
        • Resource detail report
        • Operation report
        • Operation detail report
        • Demand report
        • Demand detail report
        • Demand Gantt report
        • Forecast report
        • Performance indicator report
      • Execution screen
      • Batch commands
        • frepplectl
        • frepple
        • freppleservice.exe (Windows only)
    • Installation guide
      • Windows installer
      • Compiling on Windows
      • Linux binary packages
      • Compiling on Linux
      • Compiling from the source code repository
      • Running the VMWare virtual machine
      • Other platforms
      • Configuring multiple models in the user interface
      • Configuring as a Python extension module
    • Extension modules
      • Forecast module
      • Order quoting module
      • REST web service module
      • OpenERP connector module
      • Linear programming solver module
    • Technical guide
      • Architecture
      • Source code repository
      • User interface
        • Creating an extension app
        • Translating the user interface
        • Adding or customizing a report
        • Style guide
      • Solver engine
        • Code structure
        • Class diagram
        • Planning algorithm
          • Top level loop
          • Demand solver
          • Buffer solver
          • Flow solver
          • Load solver
          • Operation solver
          • Resource solver
        • Cluster and level algorithm
        • Extension modules
        • Style guide
        • Portability
      • Security
      • Unit tests
        • buffer_procure_1
        • calendar
        • callback
        • cluster
        • constraints_combined_1
        • constraints_combined_2
        • constraints_leadtime_1
        • constraints_material_1
        • constraints_material_2
        • constraints_material_3
        • constraints_material_4
        • constraints_resource_1
        • constraints_resource_2
        • constraints_resource_3
        • constraints_resource_4
        • constraints_resource_5
        • datetime
        • deletion
        • demand_policy
        • flow_alternate_1
        • flow_alternate_2
        • flow_effective
        • forecast_1
        • forecast_2
        • forecast_3
        • forecast_4
        • forecast_5
        • forecast_6
        • jobshop
        • load_alternate
        • load_effective
        • lpsolver_1
        • multithreading
        • name
        • operation_alternate
        • operation_available
        • operation_effective
        • operation_pre_post
        • operation_routing
        • pegging
        • problems
        • python_1
        • python_2
        • python_3
        • safety_stock
        • sample_module
        • scalability_1
        • scalability_2
        • scalability_3
        • setup_1
        • setup_2
        • skill
        • xml
        • xml_remote
    • FAQ
    • License
      • GNU Affero General Public License
      • GNU Free Documentation License
    • Third party add-ons
  • Copyright © 2010-2013 frePPLe bvba