codego123
codego123

Reputation: 301

Conversion of .osm file extension to .osm.pbf

I am trying to use osm2pgsql which requires me have a .pbf file extension. Is it possible to convert .osm file to .osm.pbf file?

Thanks in advance :)

Upvotes: 4

Views: 10398

Answers (1)

scai
scai

Reputation: 21529

osm2pgsql can read .osm files directly. .osm.pbf is just a compressed .osm file (see PBF Format in the OSM wiki).

If you still need to convert between those files for whatever reason then take a look at osmium-tool (the fastest and more modern), osmosis or osmconvert.

Upvotes: 9

Related Questions