PostgreSQL postgis: Difference between revisions
Appearance
No edit summary |
No edit summary |
||
Line 1: | Line 1: | ||
Example for Ubuntu and osmdb | Example for Ubuntu and osmdb | ||
apt install postgis | apt install postgis | ||
sudo -u postgres createuser osmuser | |||
sudo -u postgres createdb --encoding=UTF8 --owner=osmuser osm | |||
sudo -u postgres psql osm --command='CREATE EXTENSION postgis;' | |||
CREATE EXTENSION postgis; | psql -d osm | ||
SELECT PostGIS_Version(); //verify install | SELECT PostGIS_Version(); //verify install | ||
quit; | quit; | ||
apt install osm2pgsql //https://osm2pgsql.org/doc/install/linux.html | apt install osm2pgsql //https://osm2pgsql.org/doc/install/linux.html |
Revision as of 2025-08-12T14:22:30
Example for Ubuntu and osmdb
apt install postgis sudo -u postgres createuser osmuser sudo -u postgres createdb --encoding=UTF8 --owner=osmuser osm sudo -u postgres psql osm --command='CREATE EXTENSION postgis;' psql -d osm SELECT PostGIS_Version(); //verify install quit; apt install osm2pgsql //https://osm2pgsql.org/doc/install/linux.html