One of the simplest tasks is to cut out a bounding box from a planet (or other) file to get data for a specific region. Let's use Iceland as our example, as we did with XAPI in the previous chapter. To extract the data of Iceland from a planet file, use the following command:
bzcat planet-100428.osm.bz2 | osmosis --read-xml file=/dev/stdin -- bounding-box left="-25.09" right="-12.55" top="67.42" bottom="62.94" -- write-xml file="iceland.osm.bz2"
The command uses three tasks to process the data. They are as follows:
--bounding-boxtask. As with other OpenStreetMap tools, the coordinates ...