Follow

Trick to allow importing an entire country to pgRouting/PostGIS/PostgreSQL [1]: first chop up the source into smaller pieces using splitter [2], otherwise the osm2pgrouting tool will keep crashing:

$ java -jar splitter.jar --output-dir=splits/ country.osm
$ ONCE=--clean; for f in splits/*.pbf; do osmconvert $f --out-osm -o=part.osm; osm2pgrouting -f part.osm $ONCE ...; ONCE=; done

[1] pgrouting.org/
[2] wiki.openstreetmap.org/wiki/Mk

Sign in to participate in the conversation
Mastodon

The social network of the future: No ads, no corporate surveillance, ethical design, and decentralization! Own your data with Mastodon!