Re: [postgis-users] pg_dump on upgraded server
On Thu, Apr 04, 2019 at 08:33:47AM +0200, Paolo Cavallini wrote: > solved by forcing install of official deb postgresql-9.4-postgis-2.1 > from there on, things work. so, why does apt remove the needed package? > it seems appropriate to me keeping it until postgresql 9.4 is purged. > am I missing something? I also think Debian packaging of PostGIS would need some improvement, if you can get the maintainers to discuss this on postgis-devel I'd love to fully understand the issue and maybe we can even avoid doing things like dropping minor version number from DLL to work around what seems to me a packaging issue... --strk; ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
Hi all On 03/04/19 20:15, Paolo Cavallini wrote: > Hi again > > On 03/04/19 19:44, Sandro Santilli wrote: > >> This is unexpected, if 2.3.1 was _really_ installed. >> Can it be you manually installed 2.1.4 again on top >> of 2.3.1 ? What version you update to depends on >> the contents of postgis.control file. > > to do so I think the only way is to recompile it, right? > >>> ALTER EXTENSION postgis >>> UPDATE TO "2.3.1" >>> with >>> ERRORE: l'estensione "postgis" non ha un percorso di aggiornamento >>> dalla versione "2.1.4" alla versione "2.3.1" >> >> It could be 2.1.4 was released _after_ 2.3.1 (check the NEWS file). >> In this case you could try a more recent 2.3.x version of PostGIS. > > 2.1.4 reached EOL long ago, I don't think this is the case. > thanks. solved by forcing install of official deb postgresql-9.4-postgis-2.1 from there on, things work. so, why does apt remove the needed package? it seems appropriate to me keeping it until postgresql 9.4 is purged. am I missing something? thanks a lot for the help. -- Paolo Cavallini - www.faunalia.eu QGIS.ORG Chair: http://planet.qgis.org/planet/user/28/tag/qgis%20board/ ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
Hi again On 03/04/19 19:44, Sandro Santilli wrote: > This is unexpected, if 2.3.1 was _really_ installed. > Can it be you manually installed 2.1.4 again on top > of 2.3.1 ? What version you update to depends on > the contents of postgis.control file. to do so I think the only way is to recompile it, right? >> ALTER EXTENSION postgis >> UPDATE TO "2.3.1" >> with >> ERRORE: l'estensione "postgis" non ha un percorso di aggiornamento >> dalla versione "2.1.4" alla versione "2.3.1" > > It could be 2.1.4 was released _after_ 2.3.1 (check the NEWS file). > In this case you could try a more recent 2.3.x version of PostGIS. 2.1.4 reached EOL long ago, I don't think this is the case. thanks. -- Paolo Cavallini - www.faunalia.eu QGIS.ORG Chair: http://planet.qgis.org/planet/user/28/tag/qgis%20board/ ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
Hi all >> On 03/04/19 19:04, Sandro Santilli wrote: >>> Can you show the ALTER EXTENSION command you're issuing and the >>> error you're getting ? Also please show the output of >>> >>> SELECT postgis_full_version(); select postgis_full_version(); ERRORE: caricamento della libreria "/usr/lib/postgresql/9.4/lib/postgis-2.1.so" fallito: liblwgeom-2.1.4.so: impossibile aprire il file oggetto condiviso: File o directory non esistente thanks -- Paolo Cavallini - www.faunalia.eu QGIS.ORG Chair: http://planet.qgis.org/planet/user/28/tag/qgis%20board/ ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
Hi Paul, On 03/04/19 19:42, Paul Ramsey wrote: > It can perhaps be fixed by copying postgis—2.3.0--2.3.1.sql (or, really, any > of the extension upgrade scripts) to postgis—2.1.4–2.3.1.sql cp /usr/share/postgresql/9.6/extension/postgis--2.1.4--2.3.1.sql /usr/share/postgresql/9.4/extension/ alter extension postgis update to '2.3.1'; ERRORE: errore di sintassi a o presso "PARALLEL" -- Paolo Cavallini - www.faunalia.eu QGIS.ORG Chair: http://planet.qgis.org/planet/user/28/tag/qgis%20board/ ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
On Wed, Apr 03, 2019 at 07:34:33PM +0200, Paolo Cavallini wrote: > > > On 03/04/19 19:04, Sandro Santilli wrote: > > Can you show the ALTER EXTENSION command you're issuing and the > > error you're getting ? Also please show the output of > > > > SELECT postgis_full_version(); > > I tried both > ALTER EXTENSION postgis UPDATE; > with something like > the 2.1.4 version is already installed This is unexpected, if 2.3.1 was _really_ installed. Can it be you manually installed 2.1.4 again on top of 2.3.1 ? What version you update to depends on the contents of postgis.control file. > ALTER EXTENSION postgis > UPDATE TO "2.3.1" > with > ERRORE: l'estensione "postgis" non ha un percorso di aggiornamento > dalla versione "2.1.4" alla versione "2.3.1" It could be 2.1.4 was released _after_ 2.3.1 (check the NEWS file). In this case you could try a more recent 2.3.x version of PostGIS. --strk; ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
Well, this speaks to not having micro version numbers in the extension versioning, for sure. Also, potentially for having a global source version, an idea that we’d have to add to the PgSQL extension system, so a script like postgis—ANY—2.3.sql could take a best-effort run at upgrading any prior installed version. It can perhaps be fixed by copying postgis—2.3.0--2.3.1.sql (or, really, any of the extension upgrade scripts) to postgis—2.1.4–2.3.1.sql P. > On Apr 3, 2019, at 10:34 AM, Paolo Cavallini wrote: > > > > On 03/04/19 19:04, Sandro Santilli wrote: >> Can you show the ALTER EXTENSION command you're issuing and the >> error you're getting ? Also please show the output of >> >> SELECT postgis_full_version(); > > I tried both > ALTER EXTENSION postgis UPDATE; > with something like > the 2.1.4 version is already installed > and > ALTER EXTENSION postgis > UPDATE TO "2.3.1" > with > ERRORE: l'estensione "postgis" non ha un percorso di aggiornamento > dalla versione "2.1.4" alla versione "2.3.1" > > unfortunately the VPN just went down, and I don't have currently access > to the machine. > Thanks a lot. > -- > Paolo Cavallini - www.faunalia.eu > QGIS.ORG Chair: > http://planet.qgis.org/planet/user/28/tag/qgis%20board/ > ___ > postgis-users mailing list > postgis-users@lists.osgeo.org > https://lists.osgeo.org/mailman/listinfo/postgis-users ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
On 03/04/19 19:04, Sandro Santilli wrote: > Can you show the ALTER EXTENSION command you're issuing and the > error you're getting ? Also please show the output of > > SELECT postgis_full_version(); I tried both ALTER EXTENSION postgis UPDATE; with something like the 2.1.4 version is already installed and ALTER EXTENSION postgis UPDATE TO "2.3.1" with ERRORE: l'estensione "postgis" non ha un percorso di aggiornamento dalla versione "2.1.4" alla versione "2.3.1" unfortunately the VPN just went down, and I don't have currently access to the machine. Thanks a lot. -- Paolo Cavallini - www.faunalia.eu QGIS.ORG Chair: http://planet.qgis.org/planet/user/28/tag/qgis%20board/ ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
On Wed, Apr 03, 2019 at 06:52:40PM +0200, Paolo Cavallini wrote: > On 03/04/19 18:32, Sandro Santilli wrote: > > > In theory, any such function would be replaced by running > > a soft upgrade of PostGIS in that database. > > how do I do a soft upgrade, given that alter extension says the function > is already installed in the database? Can you show the ALTER EXTENSION command you're issuing and the error you're getting ? Also please show the output of SELECT postgis_full_version(); --strk; ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
Hi again On 03/04/19 18:32, Sandro Santilli wrote: > So, I guess what happens is that pg_dump wants to use the > "canonical output" functions for the geometry types of some > database (or why would pg_dump require that library?). > > Can you confirm the above ? Are you POSITIVE the database > you're dumping does NOT use PostGIS types at all ? the database is using it, but I'm dumping only a schema without PostGIS functions, I hoped this was enough. > There must be, in that database, some record in pg_proc > where probin like '%postgis%', can you check that ? yes, I confirm > In theory, any such function would be replaced by running > a soft upgrade of PostGIS in that database. how do I do a soft upgrade, given that alter extension says the function is already installed in the database? Thanks a lot. -- Paolo Cavallini - www.faunalia.eu QGIS.ORG Chair: http://planet.qgis.org/planet/user/28/tag/qgis%20board/ ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
Hi On 03/04/19 18:32, Sandro Santilli wrote: > Very interesting case, as it shows a problem with the idea > that dropping minor version from the SO would fix this kind > of problem. > > So, I guess what happens is that pg_dump wants to use the > "canonical output" functions for the geometry types of some > database (or why would pg_dump require that library?). > > Can you confirm the above ? Are you POSITIVE the database > you're dumping does NOT use PostGIS types at all ? > There must be, in that database, some record in pg_proc > where probin like '%postgis%', can you check that ? > > In theory, any such function would be replaced by running > a soft upgrade of PostGIS in that database. unfortunately alter extension does not upgrade, and the error in upgradecluster is still the same. starting to feel lost. thanks for any help. -- Paolo Cavallini - www.faunalia.eu QGIS.ORG Chair: http://planet.qgis.org/planet/user/28/tag/qgis%20board/ ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
On Wed, Apr 03, 2019 at 06:20:22PM +0200, Paolo Cavallini wrote: > On 03/04/19 18:10, Paul Ramsey wrote: > >> On Apr 3, 2019, at 9:08 AM, Paolo Cavallini wrote: > >> > >> Hi all, > >> I'm on a difficult situation: a debian sever with a pg9.4/pgis2.1 db has > >> been upgraded to stretch, therefore to pg9.6/pgis2.3. Now pg_dump will > >> complain of the missing pgis2.1 lib, even if I dump only a non public > >> (thus without pgis functions) schema. > >> How could I fix this? > >> > > Put a symlink to the postgis-2.3.so file, named as postgis-2.1.so > > done already, but it complains that the versions don't match Very interesting case, as it shows a problem with the idea that dropping minor version from the SO would fix this kind of problem. So, I guess what happens is that pg_dump wants to use the "canonical output" functions for the geometry types of some database (or why would pg_dump require that library?). Can you confirm the above ? Are you POSITIVE the database you're dumping does NOT use PostGIS types at all ? There must be, in that database, some record in pg_proc where probin like '%postgis%', can you check that ? In theory, any such function would be replaced by running a soft upgrade of PostGIS in that database. --strk; ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
same error, mismatching versions # pg_dropcluster --stop 9.6 main # pg_upgradecluster 9.4 main On 03/04/19 18:23, Paul Ramsey wrote: > Use a pg_upgrade process instead of a pg_dump. You should be able to that > with just the old data area and the new server software. > >> On Apr 3, 2019, at 9:21 AM, Paolo Cavallini wrote: >> >> I mean: server versions don't match (9.4 vs 9.6) >> >> On 03/04/19 18:20, Paolo Cavallini wrote: >>> done already, but it complains that the versions don't match >>> thanks >>> >>> On 03/04/19 18:10, Paul Ramsey wrote: Put a symlink to the postgis-2.3.so file, named as postgis-2.1.so P > On Apr 3, 2019, at 9:08 AM, Paolo Cavallini wrote: > > Hi all, > I'm on a difficult situation: a debian sever with a pg9.4/pgis2.1 db has > been upgraded to stretch, therefore to pg9.6/pgis2.3. Now pg_dump will > complain of the missing pgis2.1 lib, even if I dump only a non public > (thus without pgis functions) schema. > How could I fix this? > Thanks a lot. > -- > Paolo Cavallini - www.faunalia.eu > QGIS.ORG Chair: > http://planet.qgis.org/planet/user/28/tag/qgis%20board/ > ___ > postgis-users mailing list > postgis-users@lists.osgeo.org > https://lists.osgeo.org/mailman/listinfo/postgis-users ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users >>> >> >> -- >> Paolo Cavallini - www.faunalia.eu >> QGIS.ORG Chair: >> http://planet.qgis.org/planet/user/28/tag/qgis%20board/ >> ___ >> postgis-users mailing list >> postgis-users@lists.osgeo.org >> https://lists.osgeo.org/mailman/listinfo/postgis-users > > ___ > postgis-users mailing list > postgis-users@lists.osgeo.org > https://lists.osgeo.org/mailman/listinfo/postgis-users > -- Paolo Cavallini - www.faunalia.eu QGIS.ORG Chair: http://planet.qgis.org/planet/user/28/tag/qgis%20board/ ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
Use a pg_upgrade process instead of a pg_dump. You should be able to that with just the old data area and the new server software. > On Apr 3, 2019, at 9:21 AM, Paolo Cavallini wrote: > > I mean: server versions don't match (9.4 vs 9.6) > > On 03/04/19 18:20, Paolo Cavallini wrote: >> done already, but it complains that the versions don't match >> thanks >> >> On 03/04/19 18:10, Paul Ramsey wrote: >>> Put a symlink to the postgis-2.3.so file, named as postgis-2.1.so >>> >>> P >>> On Apr 3, 2019, at 9:08 AM, Paolo Cavallini wrote: Hi all, I'm on a difficult situation: a debian sever with a pg9.4/pgis2.1 db has been upgraded to stretch, therefore to pg9.6/pgis2.3. Now pg_dump will complain of the missing pgis2.1 lib, even if I dump only a non public (thus without pgis functions) schema. How could I fix this? Thanks a lot. -- Paolo Cavallini - www.faunalia.eu QGIS.ORG Chair: http://planet.qgis.org/planet/user/28/tag/qgis%20board/ ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users >>> >>> ___ >>> postgis-users mailing list >>> postgis-users@lists.osgeo.org >>> https://lists.osgeo.org/mailman/listinfo/postgis-users >>> >> > > -- > Paolo Cavallini - www.faunalia.eu > QGIS.ORG Chair: > http://planet.qgis.org/planet/user/28/tag/qgis%20board/ > ___ > postgis-users mailing list > postgis-users@lists.osgeo.org > https://lists.osgeo.org/mailman/listinfo/postgis-users ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
I mean: server versions don't match (9.4 vs 9.6) On 03/04/19 18:20, Paolo Cavallini wrote: > done already, but it complains that the versions don't match > thanks > > On 03/04/19 18:10, Paul Ramsey wrote: >> Put a symlink to the postgis-2.3.so file, named as postgis-2.1.so >> >> P >> >>> On Apr 3, 2019, at 9:08 AM, Paolo Cavallini wrote: >>> >>> Hi all, >>> I'm on a difficult situation: a debian sever with a pg9.4/pgis2.1 db has >>> been upgraded to stretch, therefore to pg9.6/pgis2.3. Now pg_dump will >>> complain of the missing pgis2.1 lib, even if I dump only a non public >>> (thus without pgis functions) schema. >>> How could I fix this? >>> Thanks a lot. >>> -- >>> Paolo Cavallini - www.faunalia.eu >>> QGIS.ORG Chair: >>> http://planet.qgis.org/planet/user/28/tag/qgis%20board/ >>> ___ >>> postgis-users mailing list >>> postgis-users@lists.osgeo.org >>> https://lists.osgeo.org/mailman/listinfo/postgis-users >> >> ___ >> postgis-users mailing list >> postgis-users@lists.osgeo.org >> https://lists.osgeo.org/mailman/listinfo/postgis-users >> > -- Paolo Cavallini - www.faunalia.eu QGIS.ORG Chair: http://planet.qgis.org/planet/user/28/tag/qgis%20board/ ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users
Re: [postgis-users] pg_dump on upgraded server
Put a symlink to the postgis-2.3.so file, named as postgis-2.1.so P > On Apr 3, 2019, at 9:08 AM, Paolo Cavallini wrote: > > Hi all, > I'm on a difficult situation: a debian sever with a pg9.4/pgis2.1 db has > been upgraded to stretch, therefore to pg9.6/pgis2.3. Now pg_dump will > complain of the missing pgis2.1 lib, even if I dump only a non public > (thus without pgis functions) schema. > How could I fix this? > Thanks a lot. > -- > Paolo Cavallini - www.faunalia.eu > QGIS.ORG Chair: > http://planet.qgis.org/planet/user/28/tag/qgis%20board/ > ___ > postgis-users mailing list > postgis-users@lists.osgeo.org > https://lists.osgeo.org/mailman/listinfo/postgis-users ___ postgis-users mailing list postgis-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/postgis-users