NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum

I want to upload planet-latest.osm on a PostgreSQL database via osm2pgsql but even if I've got no error for the creation of the table, the process stops acting near the 2Go and the error is (sorry it's french):

Reading in file: osm/planet-latest.osm Processing: Node(1873580k) Way(0k) Relation(0k)COPY_END for COPY planet_osm_nodes FROM STDIN; failed: ERREUR: la valeur d'une clé dupliquée rompt la contrainte unique « planet_osm_nodes_pkey » CONTEXT: COPY planet_osm_nodes, ligne 1758128898 : « 2147483647 688301347 -16699132 \N »

Error occurred, cleaning up

asked 08 Jul '13, 08:40

so4ne's gravatar image

so4ne
16114
accept rate: 0%


You have a version of osm2pgsql that only supports 32bit IDs (if you type "osm2pgsql" it will say something about "32bit ID space" in the first line of output, or even worse, nothing about ID space at all. You have to re-compile osm2pgsql or download a version compiled for 64bit IDs.

permanent link

answered 08 Jul '13, 10:18

Frederik%20Ramm's gravatar image

Frederik Ramm ♦
82.5k927201273
accept rate: 23%

Thank you for your reply, do you know how to switch to 64bit on a Debian 6.0 Squeeze? I have the 0.69 version of osm2pgsql

(08 Jul '13, 12:03) so4ne
2

The osm2pgsql package of Debian 6.0 ("Squeeze") doesn't support 64bit IDs. This is because Squeeze is rather old (from early 2011). The current stable version of Debian (7.0 aka "Wheezy") supports 64bit IDs. But if you cannot upgrade to Wheezy you can still get a recent version from GitHub, see the osm2pgsql wiki page for more information.

(08 Jul '13, 12:21) scai ♦

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×710
×263
×165

question asked: 08 Jul '13, 08:40

question was seen: 6,192 times

last updated: 08 Jul '13, 12:30

NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum