1OSMIUM-MERGE(1)                                                OSMIUM-MERGE(1)
2
3
4

NAME

6       osmium-merge - merge several sorted OSM files into one
7

SYNOPSIS

9       osmium merge [OPTIONS] OSM-FILE...
10

DESCRIPTION

12       Merges  the content of all OSM files given on the command line into one
13       large OSM file.  Objects in all files must be sorted by type,  ID,  and
14       version.   The  results  will  also be sorted in the same way.  Objects
15       that appear in multiple input files will only be in the output once.
16
17       If there is only a single input file, its contents will  be  copied  to
18       the output.
19
20       If  there are different versions of the same object in the input files,
21       all versions will appear in the output.  So this command will work fine
22       with  history  files  as input creating a new history file.  Do not use
23       this command to merge non-history files with data from different points
24       in time.  It will not work correctly.
25
26       If  you  have objects with the same type, id, and version but different
27       other data, the result of this command is  undefined.   This  situation
28       can never happen in correct OSM files, but sometimes buggy programs can
29       generate data like this.  Osmium doesn’t make any promises on what  the
30       result of the command is if the input data is not correct.
31
32       This  commands  reads its input file(s) only once and writes its output
33       file in one go so it can be streamed, ie.  it can read from  STDIN  and
34       write to STDOUT.
35

COMMON OPTIONS

37       -h, --help
38              Show usage help.
39
40       -v, --verbose
41              Set  verbose  mode.   The  program will output information about
42              what it is doing to STDERR.
43
44       --progress
45              Show progress bar.  Usually a progress bar is only displayed  if
46              STDOUT  and  STDERR  are detected to be TTY.  With this option a
47              progress bar is always shown.  Note that  a  progress  bar  will
48              never be shown when reading from STDIN or a pipe.
49
50       --no-progress
51              Do  not  show progress bar.  Usually a progress bar is displayed
52              if STDOUT and STDERR are detected to be a TTY.  With this option
53              the  progress  bar is suppressed.  Note that a progress bar will
54              never be shown when reading from STDIN or a pipe.
55

INPUT OPTIONS

57       -F, --input-format=FORMAT
58              The format of the input file(s).  Can be used to set  the  input
59              format  if it can’t be autodetected from the file name(s).  This
60              will set the format for all input files, there is no way to  set
61              the  format  for  some  input  files only.  See osmium-file-for‐
62              mats(5) or the libosmium manual for details.
63

OUTPUT OPTIONS

65       -f, --output-format=FORMAT
66              The format of the output file.  Can be used to  set  the  output
67              file  format  if  it  can’t be autodetected from the output file
68              name.  See osmium-file-formats(5) or the  libosmium  manual  for
69              details.
70
71       --fsync
72              Call  fsync after writing the output file to force flushing buf‐
73              fers to disk.
74
75       --generator=NAME
76              The name and version of the program generating the output  file.
77              It  will  be added to the header of the output file.  Default is
78osmium/” and the version of osmium.
79
80       -o, --output=FILE
81              Name of the output file.  Default is `-' (STDOUT).
82
83       -O, --overwrite
84              Allow an existing output file to be overwritten.   Normally  os‐
85              mium will refuse to write over an existing file.
86
87       --output-header=OPTION=VALUE
88              Add  output header option.  This command line option can be used
89              multiple times for different OPTIONs.  See the libosmium  manual
90              for  a  list of available header options.  For some commands you
91              can use the special format “OPTION!” (ie.  an  exclamation  mark
92              after  the OPTION and no value set) to set the value to the same
93              as in the input file.
94

DIAGNOSTICS

96       osmium merge exits with exit code
97
98       0      if everything went alright,
99
100       1      if there was an error processing the data, or
101
102       2      if there was a problem with the command line arguments.
103

MEMORY USAGE

105       osmium merge doesn’t keep a lot of data in memory, but if you are merg‐
106       ing many files, the buffers might take a noticeable amount of memory.
107

EXAMPLES

109       Merge several extracts into one:
110
111              osmium merge washington.pbf oregon.pbf california.pbf -o westcoast.pbf
112

SEE ALSO

114osmium(1), osmium-file-formats(5), osmium-merge-changes(1)
115
116       • Osmium website (https://osmcode.org/osmium-tool/)
117
119       Copyright (C) 2013-2021 Jochen Topf <jochen@topf.org>.
120
121       License  GPLv3+:  GNU  GPL  version  3  or  later  <https://gnu.org/li
122       censes/gpl.html>.  This is free software: you are free  to  change  and
123       redistribute it.  There is NO WARRANTY, to the extent permitted by law.
124

CONTACT

126       If  you  have  any  questions  or  want  to  report a bug, please go to
127       https://osmcode.org/contact.html
128

AUTHORS

130       Jochen Topf <jochen@topf.org>.
131
132
133
134                                    1.13.1                     OSMIUM-MERGE(1)
Impressum