[gdal-dev] Slow convertion from OSM to PG with -skipfailures

Martin Feuchtwanger feumar at shaw.ca
Tue May 28 10:49:40 PDT 2013


I was having a similar complaint (which i kept to myself at the time) 
when using *ogr2ogr*.  In my case, converting GDB file to PG database.

First i used some flags, -a_srs -lco -nln, but these turned out to be a 
massive waste of time (several orders of magnitude). So instead i kept 
to the defaults and made desired changes manually after the fact, in the DB.

Maybe there should be some stern warnings in the documentation when 
"luxury" options are computationally expensive? Then users would be less 
likely to judge ogr2ogr as a poor performer.

Martin Feuchtwanger  feumar at shaw.ca  604-254-0361
Vancouver, BC  V5N 1J6
http://members.shaw.ca/geomatics.developer

On 27/05/2013 7:47 AM, Jukka Rahkonen wrote:
> I have measured a huge speed difference by running the same conversion from
> OSM data file into PostGIS either with or without using the -skipfailures
> parameter.
>
> Without -skipfailures conversion takes about two minutes but if I add the
> parameter it takes at least two hours. The command I used is this
>
> ogr2ogr -f PostgreSQL PG:"dbname='gis' host='server' port='4326' user='user'
> password='passwd'" finland.osm.pbf -gt 20000 -progress
> --config OSM_COMPRESS_NODES YES  -lco DIM=2 -lco geometry_name=geoloc
> -lco fid=fid -skipfailures  --config PG_USE_COPY YES
>
> I wonder if it really needs to be so slow. My guess is that -skipfailures
> somehow invalidates my -gt 20000 parameter.
>
> -Jukka Rahkonen-

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20130528/3ce52cd3/attachment-0001.html>


More information about the gdal-dev mailing list