Table Of Contents

Previous topic

Welcome to SIMO’s documentation!

Next topic


This Page


Different versions can be downloaded from

Executable version

If you downloaded the executable distribution and decompressed the downloaded file, you’ve all set up. You can jump directly to Using SIMO section.

IMPORTANT: If you are using the executable distribution on Windows, you MUST install the Visual C++ 2008 Redistributable package or you will get cryptic errors on missing dlls or incorrect Side-by-side configuration.

Source version

The source distribution needs two more step besides decompression before it’s usable.

You need to have Python programming language installed. You can get it from SIMO is not ready for Python 3, so download the latest Python 2.6.x version. Installing Python is usually necessary only on Windows, on Linux and OS X you should already have a working Python installation.

Besides Python, you’ll need a Python package called setuptools. You can test whether you have setuptools installed by writing easy_install on the command line. If the output is something like “error: No urls, filenames, or requirements specified (see –help)” you’re good to go, but if easy_install is not recognized as a command, download and run:


After you’ve got working versions of Python and setuptools, the next steps depend on whether you’re using a Unix variant or Windows.

Linux and OS X users

On the command line in the directory into which you decompressed the downloaded SIMO source distribution, issue this command:


Then go and grab a cup of coffee, the building process will take a good while. When it finishes you should have a working SIMO installation and you are ready for the Using SIMO section.

If you run into trouble in the python stage, have a look at the Known issues with SIMO installation section.

Building a 32 & 64 bit Python on OS X 10.6 Snow Leopard

Buildout will build a Python for you within the buildout environment, but in addition to that you might want to build a general Python version that is more up to date than the system Python that Apple provides. These instructions are based on this blog post<>.

Making sure you have 32- and 64-bit enabled readline. First download the latest readline release and then:

export CFLAGS="-arch i386 -arch x86_64"
export LDFLAGS="-Wall -arch i386 -arch x86_64"
sudo make install

Download latest Python source release and:

./configure --enable-framework --with-universal-archs=intel \

Now you should have a working Python installation in /Library/Frameworks/Python.framework

Windows users

Python 2.6+ (IF compiling fortran libraries):

  1. Download and install the compatible C compiler: MinGW (make sure it’s on PATH for simplicity)

  2. In the mingw installation folder, copy liblibmingw32.a -> <python installation>libsmingw32.lib and liblibmingwex.a -> <python installation>libsmingwex.lib

  3. In <python installation>libs run the following:

    lib -remove:mbrtowc.o mingwex.lib
    lib -remove:wcrtomb.o mingwex.lib

Python 2.5:

  1. Download and install Python 2.5 (if you didn’t already)

  2. Download and install the compatible C compiler: MinGW (make sure it’s on PATH for simplicity)

  3. Install setuptools, which also includes easy_install, using the exe-installer found here

  4. Download sqlite3 amalgamation source

  5. Download and install something that can unpack tar and gzip files, (e.g. 7-zip

  6. Unpack sqlite3 to a location of your choosing, navigate to that location in command prompt and run with the mingw gcc:

    gcc -shared -s -o sqlite3.dll *.o
  7. Copy sqlite3.dll to C:WINDOWSSYSTEM32 (or to a folder in the path if you don’t have access to system32). If you plan on using pyinstaller, you also need to copy sqlite3.dll to <pythonpath>DLLs

  8. Download pysqlite source

  9. Unpack pysqlite to a location of your choosing, find the setup.cfg in the folder and alter it to match the following (where <sqlite_path> is where you just compiled sqlite3):


Now run (in the folder where you extracted the source):

python build --force -c mingw32 install --force


  1. Download and run the PostgreSQL one click installer when asked if you would like to install additional packages, choose yes and install PostGIS (this can also be done afterwards with the included StackBuilder, but it’s easier to do here) and let it make the template/example when it asks.
  2. Download and install the latest version of psyocopg2
  3. Download and install lxml latest exe-installer for your system/python
  4. Download and install numpy exe-installer for your system/python.
  5. Make sure you have the easy_install script in your system path (or go to the folder where it is) and execute the following in the command prompt
easy_install -Z cython (on 2.6 run in the  Visual Studio 2008 command prompt)
easy_install -Z ZODB3
easy_install -Z pygooglechart
easy_install -Z python-dateutil
easy_install -Z pyparsing

If easy_installing cython fails, you can get ready made Windows binaries

If easy_installing pyparsing, dry specifying the pyparsing package explicitly

  1. If you want to run tests, you’ll also need
easy_install nose
easy_install minimock
easy_install interlude
  1. If you want to run code profiling (only for developers)
easy_install guppy
  1. If any of the above easy_installs failed, see if there’s an exe-installer available for your system and use that instead (or you can do it anyway, it shouldn’t make any difference).
  2. Download libiconv, geos, proj and libspatialite from the spatialite install site
  3. Unzip the zips from the previous step and copy all dll-files from the bin folders into C:WINDOWSSYSTEM32 and/or to <SIMO_FOLDER>srcsimodbdatadb
  4. Now you are ready to build a working SIMO installation. On the command prompt, while in the directory where you unzipped the source distribution, run

Enabling parallel execution

If you wish to run simo in parallel, you will also need to do the following:

  1. Download redis, unzip and copy the files to a location of your choosing (for example C:redis, adding it to the path is convenient for usage)
  2. run easy_install -Z Celery
  3. run easy_install -Z redis

SVN Checkout

There’s a third option for installing SIMO if you want to track the latest and greatest developments. You can do a subversion checkout for the SIMO codebase and you can track the development day in day out. The checkout address is:

After the checkout you essentially have the source distribution (plus a few bits and pieces), so follow the instructions above.

For Unix, change /etc/sysctl.conf (PLEASE backup this file first!) Linux: kernel.shmmax=value Mac OS: kern.sysv.shmmax=value FreeBSD: kern.ipc.shmmax=value

Note, if getconf is on your system, you can run the following to get good inital values for shmmax and shmall:

#!/bin/bash # simple shmsetup script page_size=`getconf PAGE_SIZE` phys_pages=`getconf _PHYS_PAGES` shmall=`expr $phys_pages / 2` shmmax=`expr $shmall * $page_size` echo kernel.shmmax = $shmmax echo kernel.shmall = $shmall

sysctl.conf (on a 4 core 16GB RAM system)

kernel.shmall = 2057198 kernel.shmmax = 8426285056 # note, this value must be equal or greater than postgresql shared_buffers setting, though roughly half of your RAM is a good example. kernel.sem = 250 32000 100 128 # may need to increase these further if a large number of processes are on the same system # Potentially helpful, but untested settings # vm.swappiness=0 # try to avoid swapping; may hurt performance if you run out of memory # vm.overcommit_memory=2 # don’t let processes allocate more memory than they need.

Also, consider setting ‘noatime’ to the database volume mount options to disable constantly updating file access times.

reboot (or sudo sysctl -p should also work)

Use pgtune (, which on a 4 core 16GB RAM system resulted in the following (IMPORTANT! note the non pgtune wizard entries):

#—————————————————————————— # CUSTOMIZED OPTIONS #——————————————————————————

# SSD options (only if you have a seperate ssd) data_directory = ‘/ssd/postgresql_data’ # use data in another directory seq_page_cost = 0.05 random_page_cost = 0.1

#custom_variable_classes = ‘’ # list of custom variable class names default_statistics_target = 50 # pgtune wizard 2011-10-12 maintenance_work_mem = 960MB # pgtune wizard 2011-10-12 constraint_exclusion = on # pgtune wizard 2011-10-12 checkpoint_completion_target = 0.9 # pgtune wizard 2011-10-12 effective_cache_size = 11GB # pgtune wizard 2011-10-12 work_mem = 96MB # pgtune wizard 2011-10-12 work_mem = 128MB # book recommendation for speed wal_buffers = 8MB # pgtune wizard 2011-10-12 wal_buffers = 16MB # book recommendation for any server (but especially on heavy insert work) checkpoint_segments = 16 # pgtune wizard 2011-10-12 shared_buffers = 3840MB # pgtune wizard 2011-10-12 max_connections = 80 # pgtune wizard 2011-10-12 # BULK LOAD OPTIONS, DISABLE AFTER DONE!!! checkpoint_segments = 128 # or even 256? checkpoint_timeout = 1800 # in seconds; 30 min work_mem = 256MB # improves order by, distinct etc # synchronous_commit = off # this can be done clientside, so no need to do it here. Iit will mean however that the data may be malformed on catastrophe # fsync = off # may be unnecessary and could destroy the existing database if something goes wrong!!!