I have installed nominatim for Maldives and now I want to install for Sri Lanka in the same db. According to lonvia i found it is fast that i merge below both files and then do the import.

I have sri-lanka-latest.osm.pbf and maldives-latest.osm.pbf two pbf files and i tried to merge these two with osmconvert command. I have read Osmconvert in the wiki and osm help questions but could not find the answer.

Then i converted these two files to .o5m files separately using osmconvert and then merged those both files. Is that what I should do?

Thanks in Advance.

asked 25 Mar '16, 09:54

Tharaka%20Rajith's gravatar image

Tharaka Rajith
26235
accept rate: 0%

edited 28 Mar '16, 08:08


Merging two PBF files can be done in one run, using concatenated processes:

osmconvert region1.pbf --out-o5m | osmconvert - region2.pbf -o=all.pbf

Further examples and explanations can be found at OSM Wiki page:

https://wiki.openstreetmap.org/wiki/Osmconvert#Parallel_Processing

permanent link

answered 26 Mar '16, 07:57

Marqqs's gravatar image

Marqqs
418510
accept rate: 22%

Even better, thanks. I added a link from the Nominatim documentation to this thread.

(27 Mar '16, 19:08) mtmail
2

this is the answer i was looking for, works like a charm, thanks

(28 Mar '16, 07:12) Tharaka Rajith

This should work:

  1. osmconvert country1.osm.pbf -o=country1.o5m
  2. osmconvert country2.osm.pbf -o=country2.o5m
  3. osmconvert country1.o5m country2.o5m -o=together.o5m
  4. osmconvert together.o5m -o=together.osm.pbf

and then import together.osm.pbf with Nominatim.

permanent link

answered 25 Mar '16, 15:27

mtmail's gravatar image

mtmail
1.5k428
accept rate: 25%

Or you can use osmium-tool:

osmium merge country1.osm.pbf country2.osm.pbf -o together.osm.pbf.

permanent link

answered 25 May '17, 07:11

Jochen%20Topf's gravatar image

Jochen Topf
3.7k53754
accept rate: 31%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×469
×32
×30
×22
×1

question asked: 25 Mar '16, 09:54

question was seen: 5,515 times

last updated: 25 May '17, 07:11

powered by OSQA