[postgis-users] importing planet_110928.osm, fail after 5 days

Martin Spott Martin.Spott at mgras.net
Sun Oct 9 03:05:11 PDT 2011

Torsten Mohr wrote:

> i just set up PostGis and imported OSM data.  it took 5 days and failed at
> the end, out of memory.
> Does "out of memory" mean RAM or can it also mean disk space?

If you're using "osm2pgsql", it usually runs out of RAM.  Check the
"-s" option ....  ah, I see, you already did.

> postgres at schleim:/tmp/osm2pgsql/osm2pgsql> bzcat 
> /local/ftp/osm3/planet-110928.osm.bz2 | osm2pgsql -d gis -S default.style -m -
> s -C 4000 -

Default builds of "osm2pgsql" are capable of reading compressed dumps. 
I've never checked if it makes any difference, but you might try to
omit the 'bzcat' and to feed the dump directly into "osm2pgsql"
(replacing the STDIN "-").  Given that your machine is equipped with
only 8 GByte of RAM, using 4 GByte cache is quite a lot.  You might
consider starting with no cache mem at all.

 Unix _IS_ user friendly - it's just selective about who its friends are !

More information about the postgis-users mailing list