.pbf data files into CockroachDB using osm2pgsql.
In the example below we will import the OSM data for Australia that is available from GeoFabrik GmbH.
Before you begin
To follow along with the example below, you will need the following prerequisites:- CockroachDB and
osm2pgsql
Step 1. Download the OpenStreetMap data
First, download the OSM data:Step 2. Prepare the database
Step 3. Import the OpenStreetMap data
Run theosm2pgsql command shown below to convert the OSM data and import it into the australia database. The arguments to osm2pgsql shown below assume a and may need to be changed depending on your system. You may also need to tweak the cache setting (-C) depending on your system’s hardware.

