osm2pgsql-dev / osm2pgsql

OpenStreetMap data to PostgreSQL converter
https://osm2pgsql.org
GNU General Public License v2.0
1.51k stars 474 forks source link

Unable to open data.osm.pbf #258

Closed Allen3 closed 9 years ago

Allen3 commented 9 years ago

When I try to load the data into gis and run osm2pgsql --create --database gis data.osm.pbf I got the following prompted information:


osm2pgsql SVN version 0.87.2-dev (64bit id space)

Using built-in tag processing pipeline
Using projection SRS 900913 (Spherical Mercator)
Setting up table: planet_osm_point
Setting up table: planet_osm_line
Setting up table: planet_osm_polygon
Setting up table: planet_osm_roads
Allocating memory for dense node cache
Allocating dense node cache in one big chunk
Allocating memory for sparse node cache
Sharing dense sparse
Node-cache: cache=800MB, maxblocks=102400*8192, allocation method=3
Mid: Ram, scale=100

Reading in file: data.osm.pbf
Unable to open data.osm.pbf
Error occurred, cleaning up

So what should I do?

Allen3 commented 9 years ago

As this error occured, I couldn't get the tables referred above.

pnorman commented 9 years ago

Does data.osm.pbf check out with md5sum?

Can you try with tests/liechtenstein-2013-08-03.osm.pbf If that doesn't work, try with tests/liechtenstein-2013-08-03.osm.bz2. If the bzip2 works but the PBF doesn't, are you sure you built it with pbf support?

pnorman commented 9 years ago

User has not replied and this cannot be resolved without more information.