OSM2PGSQL(1)
π OSM2PGSQL-GEN β like, the manual page bestie
okay so this is the man page for osm2pgsql-gen, which lives under the big OSM2PGSQL(1) umbrella. Section 1, obviously. Sit down, grab a snack, we're doing generalization π¦
β¨ NAME β¨
osm2pgsql-gen β generalize OpenStreetMap data β EXPERIMENTAL! like, for real for real π§ͺ
πΈ SYNOPSIS πΈ
osm2pgsql-gen [OPTIONS]...
π DESCRIPTION π
THIS PROGRAM IS EXPERIMENTAL AND MIGHT CHANGE WITHOUT NOTICE! bestie I am not kidding, it can switch up on you any time π
osm2pgsql-gen reads data that osm2pgsql already imported, pulls it out of the database, does a whole bunch of generalization steps that a Lua config file tells it to do, and then writes the data back into the database. It works with osm2pgsql and runs after it, and yeah β it reads the exact same config file. twin behavior fr π«Ά
Heads up though: this man page can only cover, like, some of the basics plus the command line options. For the full tea, go read the Generalization chapter in the osm2pgsql Manual. this page is the appetizer, not the meal β¨
π OPTIONS π
This program follows the usual GNU command line syntax, so long options start with two dashes (--). And mandatory arguments to long options are mandatory for short options too β no cutting corners, no cap π
π₯ MAIN OPTIONS π₯
-a,--appendβ run in append mode. The default is to run in create mode, so if you want append you gotta ask for it.-S,--style=FILEβ the Lua config file. Same as forosm2pgsql. Usually you don't even need it, because it gets read from theosm2pgsql_propertiestable. convenient much? π-j,-jobs=NUMβ how many parallel threads get used for certain operations. Setting it to the number of CPU cores you've got is a reasonable starting point. Minimum value and default is 1, maximum value is 256. she does have a ceiling, bestie.
π HELP/VERSION OPTIONS π
-h,--helpβ print help.-V,--versionβ print osm2pgsql version.
π¦ LOGGING OPTIONS π¦
--log-level=LEVELβ set the log level (debug,info(default),warn, orerror).--log-sqlβ enable logging of SQL commands for debugging. for when you need to see everything π
π DATABASE OPTIONS π
-d,--database=NAMEβ the name of the PostgreSQL database to connect to. If this parameter contains an=sign, or starts with a valid URI prefix (postgresql://orpostgres://), it is treated as a conninfo string. See the PostgreSQL manual for details.-U,--username=NAMEβ PostgreSQL user name.-W,--passwordβ force password prompt. your secrets stay yours π-H,--host=HOSTNAMEβ database server hostname or unix domain socket location.-P,--port=PORTβ database server port.--schema=SCHEMAβ the default for various schema settings throughoutosm2pgsql-gen(default:public). The schema must exist in the database and be writable by the database user. It must be the same as the one used withosm2pgsqlβ matching sets, periodt.--middle-schema=SCHEMAβ the database schema where theosm2pgsql_propertiestable is to be found. Default is set with--schema. Set it to the same value as on theosm2pgsqlcommand line.
π SEE ALSO π
- the osm2pgsql website
- the osm2pgsql manual
postgres(1)osm2pgsql(1)
and that's the whole vibe, bestie π«Ά this was version 2.3.1 of the OSM2PGSQL(1) page β go generalize something iconic β¨π
π¦ where this page comes from
- nixpkgs unstable: osm2pgsql 2.3.1
- ubuntu stonking: osm2pgsql 2.3.1+ds-1 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms