Bug#839182: postgresql-9.4-postgis-2.2 and postgresql-9.4-postgis-2.1 cannot be installed simultaneously

Greg Burek gregburek at heroku.com
Thu Sep 29 21:59:05 UTC 2016


Package: postgresql-9.4-postgis-2.2
Version: 2.2.2+dfsg-5.pgdg+1
Severity: normal

Hello,

I work for Heroku Postgres, a service provider for postgres. We make
available postgis to our customers, some of whom are using 2.0, 2.1 and 2.2
versions of postgis on major versions of postgres including 9.2, 9.3, 9.4
and 9.5.

A situation we have seen is where a user has a 9.4 database with postgis
2.1 that would like to run pg_upgrade to 9.5. The upgrade fails, as no
postgis 2.1 package or binaries exist for 9.5.

To allow this upgrade to succeed, we must install
postgresql-9.4-postgis-2.2 alongside postgresql-9.4-postgis-2.1, which
allows ALTER EXTENSION postgis UPDATE to work, which clears the way for
pg_upgrade to 9.5 to work as expected.

With the latest release of postgis 2.3, however, these packages are no
longer able to be installed:

> # apt-get install postgresql-9.4-postgis-2.2 postgresql-9.4-postgis-2.1
> Reading package lists... Done
> Building dependency tree
> Reading state information... Done
> Some packages could not be installed. This may mean that you have
> requested an impossible situation or if you are using the unstable
> distribution that some required packages have not yet been created
> or been moved out of Incoming.
> The following information may help to resolve the situation:
> The following packages have unmet dependencies:
>  postgresql-9.4-postgis-2.2 : Depends: postgresql-9.4-postgis-2.2-scripts
but it is not going to be installed
> E: Unable to correct problems, you have held broken packages.

This appears to be from postgresql-9.4-postgis-2.1 depending on
postgresql-9.4-postgis-scripts, which depends on
postgresql-9.4-postgis-2.3-scripts, which conflicts with
postgresql-9.4-postgis-2.2-scripts:

> # apt-cache depends postgresql-9.4-postgis-2.1
> postgresql-9.4-postgis-2.1
>   Depends: libc6
>   Depends: libgdal1h
>   Depends: libgeos-c1
>   Depends: liblwgeom-2.1.8
>   Depends: libproj0
>   Depends: libxml2
>   Depends: postgresql-9.4
>   Depends: postgresql-9.4-postgis-scripts
>   Suggests: postgis
>   Recommends: postgresql-contrib-9.4
>   Breaks: postgis
> # apt-cache depends postgresql-9.4-postgis-scripts
> postgresql-9.4-postgis-scripts
>   Depends: postgresql-9.4-postgis-2.3-scripts
> # apt-cache depends postgresql-9.4-postgis-2.3-scripts
> postgresql-9.4-postgis-2.3-scripts
>   Recommends: postgresql-9.4-postgis-2.3
>   Conflicts: postgresql-9.4-postgis-2.2-scripts
>   Breaks: postgresql-9.4-postgis-scripts
>   Replaces: postgresql-9.4-postgis-scripts

This is surprising, as we have been successfully installing and using
postgis 2.0, 2.1 and 2.2 packages with the latest postgis-scripts package
satisfying dependencies for all versions for some time.

Is each version of postgis-scripts incompatible with other versions of
postgis? Is postgis-2.3-scripts not backwards compatible with postgis-2.2?

I have found https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=837294 and
am not sure of the reasoning behind "We're using Conflicts instead of
Breaks/Replaces because the source packages is also used in PGDG where
multiple versions are provided." as it breaks the multiple version use case
that pgdg allows.

Thanks,
Greg

-- System Information:
Debian Release: stretch/sid
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux 4.4.15-moby (SMP w/2 CPU cores)
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/pkg-grass-devel/attachments/20160929/4428962f/attachment.html>


More information about the Pkg-grass-devel mailing list