-
-
Notifications
You must be signed in to change notification settings - Fork 474
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Administrative boundaries not imported at all #30
Comments
The .bz2 file on the Geofabrik server does contain the relation you are looking for:
It seems your download is faulty. Don't be confused by the negative IDs, they are created by osm2pgsql automatically from positive relation IDs in the downloaded file. Also, you should use the .osm.pbf and not the .osm.bz2 - same data, smaller file, faster loading. |
Thanks for your help but i do not understand completely what you mean. So you grep the file and then you get a matching line. So doesn't this mean that the relation is included? I did the greping again, look:
Thanks for the tip with pbf format. But can you also extract it on the fly for osmosis, then filter and then compress it again. All through pipes (like: bzcat myfile | osmosis filter stuff | bzip > myfilteredfile). I dont have much hdd space, so i need to process stuff in ram. |
Ah, sorry. I misunderstood - I thought that you were missing the relation in the XML file! But now I see the relation was there in your XML but not imported. |
It works with hstore enabled (-j) but not without. I'll need to investigate what happened there, but I am traveling, so won't get to it until next week. |
When i try to import data from the following file:
http://download.geofabrik.de/europe/germany/bayern/oberbayern-latest.osm.bz2
(not very large 144MB, so you could try)
i don't get the (for me very import) administrative boundaries in the polygons table (perhaps there are one or two meaningless ones).
Example: There is no "Stadtbezirk 04 Schwabing-West" polygon.
But even the Boundary of the capital München is missing. All the administrative boundaries are missing. I did not check for other polygons or other database files yet, but i try to make a concrete example here, that you could trace it down.
I still had an old database, and there is everything well imported. I checked the ids of the missing polygons and there was something interesting. all these polygons had negative ids in my old database. In the xml file there were only positive ids (i guess you know this well, but this is all new for me). The ids of the xml file were the same like in the database but just positive ones.
I checked the xml file and i seem to miss this one (next to all the others):
The file can be found on:
http://download.geofabrik.de/europe/germany/bayern.html
I use the following command:
./osm2pgsql/osm2pgsql --cache 5000 --number-processes 7 -S osm2pgsql/default.style --latlong -H localhost -U michael -P 9201 -d osm oberbayern-latest.osm.bz2
My version of osm2pgsql:
./osm2pgsql/osm2pgsql --version
osm2pgsql SVN version 0.83.0 (64bit id space)
I tried with native ubuntu 12.04 libraries, but now i got the latest ones as you can see at the end of my post (ldd command).
I tried with postgis 1.5 and 2.0.
I use postgres 8.4.
I configured osm2pgsql with 32 bit space and 64 bit space. No difference. Before I switchted to this version of osm2pgsql i could import everything, but had other problems (with appending spain to germany database). I don't know this old version any more now.
here are the used libraries
please help, i am really stuck here.
Thanks, Michael
The text was updated successfully, but these errors were encountered: