I upgraded GDAL
on my ubuntu 18.04 server to GDAL 3.0.4
and downgraded Postgres from 12 to 11
After finishing GDAL upgrade (gdal installtion done according to follow link Install GDAL Packages on Ubuntu ):
ogrinfo --version
Collecting GDAL==3.0.4
Status other GDAL packages after installation :
- LibGDAL
dpkg -l | grep libgdal
libgdal-dev 3.0.4+dfsg-1~bionic0 amd64 libgdal26 3.0.4+dfsg-1~bionic0 amd64
ldconfig -p | grep gdal
libgdal.so.26 (libc6,x86-64) => /usr/lib/libgdal.so.26 libgdal.so (libc6,x86-64) => /usr/lib/libgdal.so
- GdalDATA
dpkg -l | grep gdal-data
gdal-data 3.0.4+dfsg-1~bionic0 all
Now, when I try to install PostGIS
sudo apt install postgis postgresql-11-postgis-3
on my fresh installed PostgresSQL 11.8
I getting following error:
The following packages have unmet dependencies: postgis : Depends: libgdal20 (>= 2.0.1) but it is not going to be installed Recommends: postgresql-12-postgis-3 but it is not going to be installed
Then I tried:
sudo apt install libgdal20
libgdal20 : Depends: gdal-data (>= 2.4.2+dfsg-1~bionic0) but it is not going to be installed E: Unable to correct problems, you have held broken packages.
UPDATE Steps I downgraded PostrgeSQL: Completely remove PostrgeSQL
sudo apt-get --purge autoremove postgresql*
sudo apt purge postgresql-client-common
dpkg -l | grep postgres
--> remove the rest of packages:sudo apt-get --purge remove
<pkg_name>
Please help me to fix the error , I'm stuck here