pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Adrian Klaver <adrian.klaver@aklaver.com>
To: TalGloz <glozmantal@gmail.com>
To: pgsql-general@postgresql.org
Subject: Re: Checking for Presence of Required Libraries Fails during PostgreSQL Upgrade
Date: Fri, 1 May 2020 15:11:39 -0700
Message-ID: <218736a4-9a36-9e56-67cd-52e55f9ed3ce@aklaver.com> (raw)
In-Reply-To: <1588370616126-0.post@n3.nabble.com>
References: <1588370616126-0.post@n3.nabble.com>

On 5/1/20 3:03 PM, TalGloz wrote:
> I'm trying to upgrade my PostgreSQL form 10.2 to 11.7 (and eventually to
> 12.x), when I run:
> 
>   /usr/pgsql-11/bin/pg_upgrade --old-bindir=/usr/pgsql-10/bin/
> --new-bindir=/usr/pgsql-11/bin/ --old-datadir=/var/lib/pgsql/10/data
> --new-datadir=/var/lib/pgsql/11/data --check
> 
> I get:
> 
> Checking for presence of required libraries   fatal
> Your installation references loadable libraries that are missing from the
> new installation.  You can add these libraries to the new installation,
> or remove the functions using them from the old installation.  A list of
> problem libraries is in the file:
>      loadable_libraries.txt"
> 
> my loadable_libraries.txt file shows:
> 
> could not load library "myfunc": ERROR:  could not access file "myfunc": No
> such file or directory
> could not load library "randomness": ERROR:  could not access file
> "randomness": No such file or directory
> could not load library "seal_diff_cpp": ERROR:  could not access file
> "seal_diff_cpp": No such file or directory
> could not load library "seal_mean_cxx": ERROR:  could not access file
> "seal_mean_cxx": No such file or directory
> could not load library "seal_mean_cxx_v2": ERROR:  could not access file
> "seal_mean_cxx_v2": No such file or directory
> could not load library "seal_variance_cxx": ERROR:  could not access file
> "seal_variance_cxx": No such file or directory
> could not load library "seal_diff_benchmark": ERROR:  could not access file
> "seal_diff_benchmark": No such file or Directory
> 
> Running:
> SELECT proname, probin, pronamespace
> FROM pg_proc
> WHERE probin IS NOT NULL AND pronamespace = 2200
> 
> Results in:
> 
> | proname                  | probin                       | pronamespace
> | bytea_size                | randomness              | 2200
> | sum_of_numbers      | myfunc                     | 2200
> | seal_diff_cpp            | seal_diff_cpp             | 2200
> | seal_mean_cxx_v2    | seal_mean_cxx_v2    | 2200
> | seal_variance_cxx     | seal_variance_cxx     | 2200
> | seal_diff_benchmark | seal_diff_benchmark  | 2200
> | seal_mean_cxx         | seal_mean_cxx         | 2200
> 
> All the 7 problematic libraries (.so) are manually created c extension
> functions. I can't just move them to /usr/pgsql-11/lib/ because they we
> compiled with PostgresSQL10 and not 11.

Why not compile them against 11?

Then follow step 5) here:

https://www.postgresql.org/docs/12/pgupgrade.html

> 
> How can I resolve this issue? How can I delete them properly if porting them
> to 11 is a painful process? Deleting them directly form /usr/pgsql-10/lib/
> doesn't help.

If there are objects in the 10 database that depend on the libraries 
then I imagine deleting them won't help.

> 
> 
> 
> --
> Sent from: https://www.postgresql-archive.org/PostgreSQL-general-f1843780.html
> 
> 


-- 
Adrian Klaver
adrian.klaver@aklaver.com





view thread (8+ messages)  latest in thread

Message-ID: <218736a4-9a36-9e56-67cd-52e55f9ed3ce@aklaver.com>
Permalink:  ../218736a4-9a36-9e56-67cd-52e55f9ed3ce@aklaver.com/
Also on:    postgresql.org/message-id/218736a4-9a36-9e56-67cd-52e55f9ed3ce@aklaver.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: adrian.klaver@aklaver.com, glozmantal@gmail.com
  Subject: Re: Checking for Presence of Required Libraries Fails during PostgreSQL Upgrade
  In-Reply-To: <218736a4-9a36-9e56-67cd-52e55f9ed3ce@aklaver.com>
  References: <1588370616126-0.post@n3.nabble.com> <218736a4-9a36-9e56-67cd-52e55f9ed3ce@aklaver.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox