Closed TheD3us closed 5 years ago
Hi @TheD3us ,
This is a memory problem. As alsace.osm is not a large file I think you can have problems with your system configuration. Are you using a Virtual machine?
Thanks,
Yes i am because i need to do some tests before deploy my application. Do i need to use a real computer ?
I've tried with several system. I've tried on Windows, Ubuntu , OSgeolive, I know that osm2pgsql works but i need tu use osm2pgrouting. In the end I want to try pgr_NodeNetwork() because it don't work when i use osm2pgsql. I learned GIS and all pgrouting, postgis and other technologies since 5 month and i'm alone on it. I begin to became crazy, i'm tired of all this utilities who don't work.
All i wanted was to take a map and make some route. But with all tutorial who exist there is nothing who working correctly
I know that with osm2pgsql we have the --slim option, why don't we have it with osm2pgrouting ?
It doesn't matter if you use a virtual or a physical machine but you need to have enought memory to process the dataset. Could you see how much memory has assigned your virtual machine? There isn't "slim" option in osm2pgrouting.
It's too bad for the slim option. Yes i can see, i have assigned 8GB i can up to 10 but it's all.
Uhmmm I'm reviewing alsace.osm file (2.1 GB) and I think you can not enought memory with 8 GB. If you are using Linux you can add swap memory in your system; it's not as fast as RAM memory but you will haven't problems to process your file (See this issue: https://github.com/pgRouting/osm2pgrouting/issues/222). Another option is split your osm file and build topology incrementally.
How can i split the osm and bild topology incrementally ? there is a software who do this ?
First, you need to get osm files from Overpass API using your own BBOX. From command line:
$ BBOX="1.97180,41.26684,2.26478,41.55818"
$ wget --progress=dot:mega -O "yourexampledata.osm" "http://www.overpass-api.de/api/xapi?*[bbox=${BBOX}][@meta]"
Second, you can use osm2pgrouting doing incremental adition of data without using --clean
. See here: https://github.com/pgRouting/osm2pgrouting#how-to-use
Do you know what is the difference between osm2pgsql and osm2pgrouting ?
osm2pgsql: imports osm data to PostGIS. osm2pgrouting: imports osm data to PostGIS building pgRouting topology.
But if i do a osm2pgsql import + pgr_createTopology() , this is the same than osm2pgrouting ?
The final result could be the same. The advantages for osm2pgrouting is processing speed but with a very high memory cost.
Ok thank you very much for all .
Hello,
Me too, i have the issue of std::bad_alloc :
I have tried the osmconvert to clear Metadata and i've tried to enlarge memory (i have 8Go)
Anyone to help me fix it ?