Update PostGIS GEOS library on RDS

0

I recently upgraded the PostGIS extension on my Postgres RDS instance. The upgrade went well, but the GEOS library is still on an old version. This means that some of the newer features are not available (e.g. ST_ReducePrecision).

Output of SELECT postgis_full_version();

POSTGIS="3.1.4 ded6c34" [EXTENSION] PGSQL="120" GEOS="3.8.2-CAPI-1.13.4" PROJ="6.2.1" GDAL="GDAL 2.3.1, released 2018/06/22" LIBXML="2.9.9" LIBJSON="0.12.99" LIBPROTOBUF="1.3.0" WAGYU="0.5.0 (Internal)" TOPOLOGY RASTER

Error message when using one of the newer features:

ERROR: Precision reduction requires GEOS-3.9 or higher

Is there a way to update the GEOS library?

johandk
질문됨 2년 전561회 조회
1개 답변
0

Hi,

Are you sure you're running RDS Postgres and not Aurora Postgres? Based on the postgis_full_version I can't tell which engine or version you're using but RDS Postgres 13.5 has the following GEOS version available.

postgres=> select version(),postgis_full_version();
                                                 version                                                 |                                        postgis_full_version
---------------------------------------------------------------------------------------------------------+---------------------------------------------
 PostgreSQL 13.5 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11), 64-bit | POSTGIS="3.1.4 ded6c34" [EXTENSION] PGSQL="130" GEOS="3.9.1-CAPI-1.14.2" PROJ="Rel. 5.2.0, September 15th, 2018" LIBXML="2.9.1" LIBJSON="0.13.1" LIBPROTOBUF="1.3.2" WAGYU="0.5.0 (Internal)"
(1 row)

Aurora Postgres 13.4 has the following GEOS version.

postgres=> select aurora_version(), version(), postgis_full_version();
 aurora_version |                                             version                                             |                                                                          p
ostgis_full_version
----------------+-------------------------------------------------------------------------------------------------+-----------------------------------
 13.4.0         | PostgreSQL 13.4 on x86_64-pc-linux-gnu, compiled by x86_64-pc-linux-gnu-gcc (GCC) 7.4.0, 64-bit | POSTGIS="3.1.4 ded6c34" [EXTENSION] PGSQL="130" GEOS="3.9.1dev-CAPI-1.14.1
" PROJ="6.2.1" LIBXML="2.9.9" LIBJSON="0.12.99" LIBPROTOBUF="1.3.0" WAGYU="0.5.0 (Internal)"
(1 row)

I'd recommend testing your postgis query on a test copy of one of these versions and if appropriate you could perform an engine version upgrade to pickup the required GEOS/postgis version.

AWS
답변함 2년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠