Changes between Version 3 and Version 4 of UsersWikiPostGIS24Debian9src
- Timestamp:
- 08/19/17 10:00:39 (7 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
UsersWikiPostGIS24Debian9src
v3 v4 3 3 == Prerequisites == 4 4 Several components are needed, which can either be built from source or installed from pre-built packages, as shown below. For a quick start, there are official Docker images for Postgres here [https://hub.docker.com/_/postgres/] 5 For some features to be enabled (like parallel query support for spatial joins), Postgres 10 is required, but most features work with 9.6 6 7 With a Docker v10 image, postgres is already installed, but the server-dev package is required: 8 {{{ 9 sudo apt-get install postgresql-server-dev-10 10 }}} 5 11 6 12 Without the Docker image, start by first installing the Postgres package: … … 9 15 }}} 10 16 11 Then for either approach, install the prerequisite packages using:17 Then for either approach, install the prerequisite packages for PostGIS using: 12 18 {{{ 13 19 sudo apt-get install build-essential libxml2-dev libgdal-dev libproj-dev libjson0-dev xsltproc docbook-xsl docbook-mathml … … 15 21 16 22 === Build GEOS 3.7.x === 17 PostGIS 2.4 is best used with GEOS >= 3.7 for several new features, however Debian wheezy only has GEOS 3.5.1 available in packages, so if you want the version that enablesall features, GEOS needs to be built from source. If you don't need the new features(e.g ST_FrechetDistance), you can instead install the available version of GEOS {{{sudo apt-get libgeos-dev}}}.23 PostGIS 2.4 is best used with GEOS >= 3.7 for several new features, however Debian stretch only has GEOS 3.5.1 available in system packages, so if you want to enable all features, GEOS needs to be built from source. If you don't need the new features(e.g ST_FrechetDistance), you can instead install the available version of GEOS {{{sudo apt-get libgeos-dev}}}. 18 24 19 25 There are multiple ways to build GEOS from source, but this is the simplest (Note: currently version 3.7 is only available in the nightly build. When 3.7 is released, switch to that): … … 47 53 == Spatially enabling a database == 48 54 49 Connect to your database using pgAdmin IIIor psql, and use the commands to add the PostgreSQL extensions. To add PostGIS with raster support:55 Connect to your database using pgAdmin or psql, and use the commands to add the PostgreSQL extensions. To add PostGIS with raster support: 50 56 {{{ 51 57 CREATE EXTENSION postgis;