[postgis-devel] ERROR: operator class "brin_geography_inclusion_ops" does not exist for access method "brin"

Regina Obe lr at pcorp.us
Sat Oct 9 07:45:43 PDT 2021


You know by chance if these ever went thru pg_upgrade.
I know we had deficiencies with brin in the past when pg upgrading (and also
just general pre-version upgrade) from a pre-PostgreSQL 9.5 to a 9.5 or
higher.
The reason is before we weren't checking the PostgreSQL version change
during upgrade, so the script would only apply new features of a PostGIS
version and not consider that prior features like BRIN were not available
until X newer PostgreSQL version.  I thought we dealt with all these brin
issues in the past, but perhaps not.  Maybe we only dealt with future 9.4 ->
newer and not already broken installs adding in the brin stuff.

> -----Original Message-----
> From: postgis-devel [mailto:postgis-devel-bounces at lists.osgeo.org] On
Behalf
> Of Justin Pryzby
> Sent: Friday, October 8, 2021 8:46 PM
> To: postgis-devel at lists.osgeo.org
> Subject: [postgis-devel] ERROR: operator class
> "brin_geography_inclusion_ops" does not exist for access method "brin"
> 
> On a postgres 14 instance, with:
> postgis32_14-3.2.0-alpha1_1.rhel7.x86_64
> 
> I have a new nagios check that extensions upgrades have been applied when
> available.
> 
> It's warning, and actually postgis was still "unpackaged" after handsful
of
> pg_upgrades each year.  So I did this:
> 
>         ts=# SELECT postgis_extensions_upgrade();
>         NOTICE:  Packaging extension postgis
>         ERROR:  operator class "brin_geography_inclusion_ops" does not
exist
> for access method "brin"
>         CONTEXT:  SQL statement "ALTER EXTENSION postgis ADD OPERATOR
> CLASS brin_geography_inclusion_ops USING brin"
>         PL/pgSQL function inline_code_block line 3 at SQL statement
>         SQL statement "CREATE EXTENSION postgis SCHEMA public VERSION
> unpackaged;ALTER EXTENSION postgis UPDATE TO "3.2.0alpha1""
>         PL/pgSQL function postgis_extensions_upgrade() line 68 at EXECUTE
> 
> I got around it for now by doing a partial "CREATE OPERATOR CLASS
> brin_geography_inclusion_ops".  I guess the server may have run various
> postgis betas over the years and maybe missed something in the meantime.
> 
> If need be, it's not too hard for us to drop postgis and re-add it.
However I
> also found 2 of our instances running v13 which have the same issue, so
> maybe there's a deficiency that should be addressed.
> 
> --
> Justin (an early adopter)
> _______________________________________________
> postgis-devel mailing list
> postgis-devel at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/postgis-devel



More information about the postgis-devel mailing list