[postgis-tickets] [PostGIS] #4717: upgrading to 3.0.1 from 2.4.4 following docu does not work: "Updating extension postgis from 3.0.1 to 2.4.4" ?!

PostGIS trac at osgeo.org
Wed Jul 8 02:02:29 PDT 2020


#4717: upgrading to 3.0.1 from 2.4.4 following docu does not work: "Updating
extension postgis from 3.0.1 to 2.4.4" ?!
---------------------+---------------------------
 Reporter:  tpo      |      Owner:  pramsey
     Type:  defect   |     Status:  new
 Priority:  medium   |  Milestone:  PostGIS 3.0.2
Component:  postgis  |    Version:  3.0.x
 Keywords:           |
---------------------+---------------------------
 According to
 http://postgis.net/docs/manual-3.0/postgis_installation.html#soft_upgrade_extensions

 One should upgrade like this:

 {{{
 ALTER EXTENSION postgis UPDATE TO "3.0.2dev";
 ALTER EXTENSION postgis_topology UPDATE TO "3.0.2dev";
 }}}

 I am upgrading to 3.0.1 because there do not seem to exist higher version
 of postgis than postgresql-11-postgis-3 3.0.1+dfsg-2.pgdg100+1 for Debian
 buster at https://apt.postgresql.org.

 If I do the above then I get:

 {{{
 psql > ALTER EXTENSION postgis UPDATE TO "3.0.1"; ALTER EXTENSION
 postgis_topology UPDATE TO "3.0.1";
 WARNING:  unpackaging raster
 WARNING:  PostGIS Raster functionality has been unpackaged
 HINT:  type `SELECT postgis_extensions_upgrade(); to finish the upgrade.
 After upgrading, if you want to drop raster, run: DROP EXTENSION
 postgis_raster;
 }}}

 Let's see where we're at:

 {{{
 psql > \dx
                                         List of installed extensions
        Name       | Version |   Schema   |
 Description
 ------------------+---------+------------+---------------------------------------------------------------------
  hstore           | 1.4     | public     | data type for storing sets of
 (key, value) pairs
  plpgsql          | 1.0     | pg_catalog | PL/pgSQL procedural language
  postgis          | 3.0.1   | public     | PostGIS geometry, geography,
 and raster spatial types and functions
  postgis_topology | 3.0.1   | topology   | PostGIS topology spatial types
 and functions
 (4 rows)
 }}}

 So let us now update, as indicated by the "hint" above:

 {{{
 psql> SELECT postgis_extensions_upgrade();
 NOTICE:  Updating extension postgis from 3.0.1 to 2.4.4
 ERROR:  extension "postgis" has no update path from version "3.0.1" to
 version "2.4.4"
 CONTEXT:  SQL statement "ALTER EXTENSION postgis UPDATE TO "2.4.4";"
 PL/pgSQL function postgis_extensions_upgrade() line 68 at EXECUTE
 }}}

 So I'd say there's something broken there.

-- 
Ticket URL: <https://trac.osgeo.org/postgis/ticket/4717>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.


More information about the postgis-tickets mailing list