Skip to content

Latest commit

 

History

History
35 lines (24 loc) · 1.84 KB

INSTALL.md

File metadata and controls

35 lines (24 loc) · 1.84 KB

Setting up a database

  1. Set up a regular pgsnapshot/PostGIS OSM database, see the following documents:
  1. Run the sql/owl_schema.sql script in that database.

Initial data load

  1. Use the --write-pgsql Osmosis task to load inital data.

Installing OWL Osmosis plugin

OWL plugin for Osmosis is needed for the --write-owldb-change task which populates OWL tables with data. To install the plugin just drop the file from osmosis-plugin directory to the lib directory in your Osmosis installation (e.g. /usr/share/osmosis).

Populating the database with changes

In order to start populating OWL tables, you need to process OsmChange files against your database. The easiest way to do this is to set up the Osmosis interval replication.

First, initialize replication directory.

Then, setup (e.g. in crontab) the replication pipeline:

osmosis --read-replication-interval workingDirectory=<dir> --tee-change  --write-owldb-change authFile=<authFile> --write-pgsql-change authFile=<authFile>

This commands does couple of things:

  • Downloads OsmChange file for a specific replication interval (minute/hour/day) - according to the configuration in configuration.txt.
  • First, the change stream goes to the OWL Osmosis plugin - it populates change tables.
  • Then the stream goes to the regular --write-pgsql-change task that makes modifications in the data tables.