[ gpsdrive ] Mapnik Import Issues
Charles Curley
charlescurley at charlescurley.com
Wed Oct 28 18:22:06 AKDT 2009
I'm trying to install the OSM data into postgres using the writeup in
Documentation/README.Mapnik_and_OpenStreetMaps. For repeatability, I
wrote a short script with a bounding box.
--------------------------------------------------
#! /bin/bash
minlon=-112
minlat=40
maxlon=-103
maxlat=46
osm2pgsql --bbox ${minlon},${minlat},${maxlon},${maxlat} -m -d gis $1
--------------------------------------------------
I got a lot of errors which lead to this email:
http://lists.openstreetmap.org/pipermail/dev/2009-July/016133.html The
version of osm2pgsql in the Ubuntu repo is obsolete. Recompiling by
hand solved that problem. For those running Ubuntu, install
libbz2-dev. Then:
svn co http://svn.openstreetmap.org/applications/utils/export/osm2pgsql/
cd osm2pgsql/
make
Then, as root:
cd /usr/local/bin/
cp /home/ccurley/osm2pgsql/osm2pgsql
mkdir /usr/share/osm2pgsql/
cd /usr/share/osm2pgsql/
cp /home/ccurley/osm2pgsql/default.style .
(Or use my mkcd,
http://www.charlescurley.com/blog/articles/mkcd_mkdir_foo____cd_foo/index.html
:-)
That should do it; at least my results were a lot better.
Now, however, I get:
--------------------------------------------------
osm2pgsql SVN version 0.68-18358
Using projection SRS 900913 (Spherical Mercator)
Setting up table: planet_osm_point
NOTICE: table "planet_osm_point" does not exist, skipping
NOTICE: table "planet_osm_point_tmp" does not exist, skipping
Setting up table: planet_osm_line
NOTICE: table "planet_osm_line" does not exist, skipping
NOTICE: table "planet_osm_line_tmp" does not exist, skipping
Setting up table: planet_osm_polygon
NOTICE: table "planet_osm_polygon" does not exist, skipping
NOTICE: table "planet_osm_polygon_tmp" does not exist, skipping
Setting up table: planet_osm_roads
NOTICE: table "planet_osm_roads" does not exist, skipping
NOTICE: table "planet_osm_roads_tmp" does not exist, skipping
Mid: pgsql, scale=100, cache=800MB, maxblocks=102401*8192
Setting up table: planet_osm_nodes
*** WARNING: intarray contrib module not installed
*** The resulting database will not be usable for applying diffs.
NOTICE: table "planet_osm_nodes" does not exist, skipping
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index "planet_osm_nodes_pkey" for table "planet_osm_nodes"
Setting up table: planet_osm_ways
NOTICE: table "planet_osm_ways" does not exist, skipping
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index "planet_osm_ways_pkey" for table "planet_osm_ways"
Setting up table: planet_osm_rels
NOTICE: table "planet_osm_rels" does not exist, skipping
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index "planet_osm_rels_pkey" for table "planet_osm_rels"
Reading in file: planet-091021.osm.bz2
--------------------------------------------------
At that point, I hit CTL-c. Apparently I'm missing the schema. where
do I get that? Googling on an error message did not return any useful
results.
--
Charles Curley /"\ ASCII Ribbon Campaign
Looking for fine software \ / Respect for open standards
and/or writing? X No HTML/RTF in email
http://www.charlescurley.com / \ No M$ Word docs in email
Key fingerprint = CE5C 6645 A45A 64E4 94C0 809C FFF6 4C48 4ECD DFDB
More information about the GPSdrive
mailing list