[OSM-dev] osm2pgsql: append-mode (error message)

Stefan Mohr gis at nordie.de
Wed Dec 31 14:45:58 UTC 2014


Hi everyone,

 

I am relatively new to using OSM data and osm2pgsql and have been doing some
testing during the last few weeks. I am using the following command lines
and I am pretty not sure, if I am doing it in the right way:

 

osm2pgsql --verbose --create --slim --cache 4096 --prefix planet_osm
--database osmtest --username gis --host localhost --hstore
--extra-attributes --style /gis/maps/planet/style/default.style
--number-processes 4 --bbox 7.85,51.50,11.32,55.06
schleswig-holstein-latest.osm.pbf

 

osm2pgsql --verbose --append --slim --cache 4096 --prefix planet_osm
--database osmtest --username gis --host localhost --hstore
--extra-attributes --style /gis/maps/planet/style/default.style
--number-processes 4 --bbox 7.85,51.50,11.32,55.06 hamburg-latest.osm.pbf

 

osm2pgsql --verbose --append --slim --cache 4096 --prefix planet_osm
--database osmtest --username gis --host localhost --hstore
--extra-attributes --style /gis/maps/planet/style/default.style
--number-processes 4 --bbox 7.85,51.50,11.32,55.06
niedersachsen-latest.osm.pbf

 

The result should be a "merging" of 3 osm data files, the first line is
doing a good job , but during the second line there is an error:

 

Reading in file: hamburg-latest.osm.pbf

Processing: Node(2156k 113.5k/s) Way(405k 27.00k/s) Relation(0
0.00/s)COPY_END for COPY planet_osm_ways FROM STDIN;

failed: ERROR:  duplicate key value violates unique constraint
"planet_osm_ways_pkey"

DETAIL:  Key (id)=(3075476) already exists.

CONTEXT:  COPY planet_osm_ways, line 193

 

I would be glad if anyone could tell me, what I have missed and what I am
doing wring here? Thanks a lot,

Stefan

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/dev/attachments/20141231/42a47aab/attachment.html>


More information about the dev mailing list