[OSM-dev] osm2pgsql on Freemap: Mapnik rendering not working
jburgess777 at googlemail.com
Sat Oct 20 13:28:17 BST 2007
On Sat, 2007-10-20 at 12:33 +0100, Nick Whitelegg wrote:
> Hello everyone,
> (cc to Artem and Jon B. as I thought you might be able to help out here...)
You got my address wrong.
> Managed to successfully import the 03/10/07 planet.osm (the last 0.4 planet)
> directly into the PostGIS database I have on the Freemap server using
> osm2pgsql (the last 0.4 version, checked out on 06/10/07). I ran osm2pgsql on
> the Freemap server; it completed without any error messages.
> However my Mapnik-based rendering software no longer renders the data
> successfully. It shows the SRTM contour data but no OSM data (I don't get 500
> errors etc) I'm using the same mapnik I did previously (one from March;
> haven't updated it as I ran into problems compiling later versions). I'm
> guessing the structure of the database has changed compared to that defined
> in March, but it seems to be more or less the same. The last planet I
> successfully imported into Freemap was the 15/08/07 planet; that was using
> the version of osm2pgsql which simply wrote out SQL and stored all the nodes
> and segments in huge arrays (think it dated from March, again)
> Can anyone give me any pointers what might be wrong? Didn't get any error
> messages written out when I run my (CGI) rendering software on the
> My Mapnik configuration file is at
According to that file you want your data in latlong format which is not
<Layer name="amenity" status="on" srs="+proj=latlong +ellps=GRS80+no_defs">
Did you run osm2pgsql with the '--latlong' option?
The osm.xml for the main site has used mercator co-ordinates for the
postgis data for the past few months.
150MB is a big to download to verify the data co-ordinates. Can you try
something like the following it should tell you whether you have latlong
co-ordinates or not:
gis=> select name,astext(way) from planet_osm_point where name='London';
name | astext
London | POINT(-14236.7498650935 6678032.76431355)
London | POINT(13770176.7059706 1462100.03299675)
The above shows the co-ordinates in my DB are Mercator which would
notwork with your osmmerc.xml file.
If you want to work with mercator co-ords then change all the postgis
layers in your osmmerc.xml to specifiy:
srs="+proj=merc +datum=WGS84 +k=1.0 +units=m +over +no_defs"
This should avoid you needing to re-import the data.
More information about the dev