Good morning, Collective Intelligence.
I've recently had to resurrect a postgresql-9.1 database by plugging the raw data directory files into a fresh install. All my data is intact, except I can't open up my PostGIS spatial data.
I'm able to enable spatial data on new databases with:
CREATE extension postgis;
However, trying to access data in the recovered spatial databases results in an error.
For example,
SELECT PostGIS_full_version();
throws an error:
ERROR: could not access file "$libdir/postgis-2.0": No such file or directory
SQL state: 58P01
Context: SQL statement "SELECT postgis_lib_version()"
PL/pgSQL function "postgis_full_version" line 17 at SQL statement
I've seen this post on the topic, but there's not enough information to solve my problem.
ERROR: could not access file "$libdir/postgis-2.0" postgresapp
This is my PostGIS version:
POSTGIS="2.1.0SVN" GEOS="3.4.1-CAPI-1.8.0 r3892" PROJ="Rel. 4.7.1, 23 September 2009" GDAL="GDAL 1.7.3, released 2010/11/10" LIBXML="2.7.8" LIBJSON="UNKNOWN" (core procs from "2.1.0SVN" need upgrade) RASTER (raster procs from "2.1.0SVN" need upgrade)
I'm assuming this is a path variable I need to reset somehow, though I'm not sure how to access it.
Appreciate very much your tips.
Forgot to say: I did check the setting in the pg_config file for the libdir. It's set to usr/lib/postgresql/9.1/lib which is working properly for new databases that I enable. Is there a way to check the setting on the old data? How would it be different? Thx.