Append function in Combine with Tableindex / Slim not working #4796
Comments
Author: errox Clean Formating: osm2pgsql -a -i -s belgium.osm.pbf -> Throws Warning that -s is not activated osm2pgsql -a -s -i belgium.osm.pbf -> Usage Error osm2pgsql -i -a -s belgium.osm.pbf -> SQL Syntax error (.... planet_osm_point USING BTREE (osm_id) TABLESPACE -a osm2pgsql -i -s -a belgium.osm.pbf -> Throws Warning that -s is not activated osm2pgsql -s -i -a belgium.osm.pbf -> SQL Syntax error (.... planet_osm_point USING BTREE (osm_id) TABLESPACE -a osm2pgsql -s -i -a belgium.osm.pbf -> Usage Error |
Author: jburgess777[at]googlemail.com I don't know where you get the idea that -i will get rid of the duplicate key warning. Whatever string follows the -i is interpreted as the table space to use for the indexes. This is why you see the parameter ordering influencing the result: whatever follows the -i is taken as the tablespace and not parsed as another command line switch. You can see this in your examples above where "-i -a" returns a message about creating an index in "tablespace -a". I suspect you are attempting to import data from two neighbouring areas. This causes problems because some data may be duplicated along the border between the two imports. The better way to do this is to either import a single larger area (e.g. all of europe) or import the data into different databases or with different table names (--prefix). |
Author: errox I imported Germany. I tried to import belgium -> to big. Luxembourg without -slim, only -a -> Not working (Duplicate Entry) Luxembourg -a -i -> worked (Small, RAM was enough) To import hole Europe was my first idea. This is an alternative. |
Author: errox I Imported the Files with the --prefix command (tablenames are now: belgium_ways, ..... and so on). But the renderjob doesnt get it. How can i say to the Renderjob: look in all tables and not just planet_xxxx See: http://forum.openstreetmap.org/viewtopic.php?pid=317787#p317787 |
Author: amm The rendering setup doesn't really support rendering from multiple tables like that (belgium_ways_ ...) Currently it is only propperly supported to import a single data file during the initial import. So you either need to find an extract that includes all the areas you wish to render (e.g. Europe.osm.pbf), or you can use osmosis [1] to merge various extract into a single osm file prior to import with osm2pgsql. [1] http://lists.openstreetmap.org/pipermail/osmosis-dev/2010-July/000641.html |
Author: pnorman The problems described seem to be user errors (weird usage of -i) and expecting osm2pgsql to do things it doesn't claim to do, and the ticket is 4 years old and unlikely to get any attention here. |
Reporter: errox
[Submitted to the original trac issue database at 7.59pm, Monday, 25th February 2013]
Hello.
There is a Big Bug if you want to use osm2pgsql to append files.
First error: Duplicate Key error. Ok -> use parameter -i.
But how can i combine it? If i want to use
-a (append)
-i (no index error)
-C Caching 1500 mb Ram max
-s Slim
if i just use -a -i -s (max 800 default) it does not work.
osm2pgsql -a -i -s belgium.osm.pbf -> Throws Warning that -s is not activated
osm2pgsql -a -s -i belgium.osm.pbf -> Usage Error
osm2pgsql -i -a -s belgium.osm.pbf -> SQL Syntax error (.... planet_osm_point USING BTREE (osm_id) TABLESPACE -a
osm2pgsql -i -s -a belgium.osm.pbf -> Throws Warning that -s is not activated
osm2pgsql -s -i -a belgium.osm.pbf -> SQL Syntax error (.... planet_osm_point USING BTREE (osm_id) TABLESPACE -a
osm2pgsql -s -i -a belgium.osm.pbf -> Usage Error
Normaly, the Order of the Commands is not neseserry, or am i wrong?
The text was updated successfully, but these errors were encountered: