I have 20GB RAM and I have allocated 22GB swap to cater for the planet.osm data. My shell command on the Ubuntu14.04 like this osm2pgsql -dosmgis -s -S"./default.style" -C16384 -Uwww-data -W -Hlocalhost -v ~/planet-140625.osm.bz2 the import time is too long with the speed (nodes=88k/s ways=0.15k/s,rels=11.2/s) and the nodes,ways and rels have been read in for about 1 week but when the process move to "Committing transaction for planet_osm_point" it show "There is no transaction in progress" after I check the "dmesg" it shows "Out of memory kill osm2pgsql" so what I can do to deal with this proble? someone can give me some advices? with many thanks!!! asked 07 Dec '14, 04:46 studiousdavid SomeoneElse ♦ |
I just ran an import and on first try ran in to similar problems (and I have a lot of imports under my belt), but that is normal, OSM data continues to grow at a rapid pace and the tools are evolving too. First you should be setting -C to 25000, then you will need to allocate more swap. On my machine with 32GB RAB it peaked at 24GB, I would aim for a total of 40-50GB swap to be on the safe side. Note: if you are using a current osm2pgsql you shoud likely not use multiple processes if you are using the persistent node cache. answered 09 Dec '14, 00:22 SimonPoole ♦ Thank you for sharing your expriences!
(09 Dec '14, 00:39)
studiousdavid
|
Hi studiousdavid, welcome, you might or please read this https://help.openstreetmap.org/questions/12318/why-is-my-import-of-planet-latestosm-killed and other import related questions. Just by adding import or osm2pgsql into the blank line above. answered 07 Dec '14, 11:42 Hendrikklaas Thank you Hendrikklaas! I have read some of the FQA but I'm still a little bit confused
(09 Dec '14, 00:38)
studiousdavid
|
Hi why do you ask the same related question after one hour again ? Duplicated questions tend to be closed without answering !
@Hendrikklaas It's a different question