From e39924ca2926a495320b5705e9c2886fea06f6b4 Mon Sep 17 00:00:00 2001 From: Craig Comstock Date: Thu, 20 Jun 2024 16:59:48 -0500 Subject: [PATCH] Adjusted calling pg_upgrade during upgrade to include LD_LIBRARY_PATH of previous installation pg_upgrade calls postgres which includes reference to libssl that may change during upgrade which will cause postgres to not be executable Add LD_LIBRARY_PATH=$BACKUP_DIR/lib/ to address this issue. Ticket: ENT-11853 Changelog: title --- packaging/common/cfengine-hub/postinstall.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packaging/common/cfengine-hub/postinstall.sh b/packaging/common/cfengine-hub/postinstall.sh index 31d39f61f..a3528232f 100644 --- a/packaging/common/cfengine-hub/postinstall.sh +++ b/packaging/common/cfengine-hub/postinstall.sh @@ -525,7 +525,7 @@ check_disk_space() { # and then importing it into new one migrate_db_using_pg_upgrade() { - su cfpostgres -c "$PREFIX/bin/pg_upgrade --old-bindir=$BACKUP_DIR/bin --new-bindir=$PREFIX/bin --old-datadir=$BACKUP_DIR/data --new-datadir=$PREFIX/state/pg/data" + su cfpostgres -c "LD_LIBRARY_PATH=$BACKUP_DIR/lib/ $PREFIX/bin/pg_upgrade --old-bindir=$BACKUP_DIR/bin --new-bindir=$PREFIX/bin --old-datadir=$BACKUP_DIR/data --new-datadir=$PREFIX/state/pg/data" } migrate_db_using_pipe() {