PXF Extension Creation Fails with "undefined symbol: pg_strerror"
search cancel

PXF Extension Creation Fails with "undefined symbol: pg_strerror"

book

Article ID: 447059

calendar_today

Updated On:

Products

VMware Tanzu Data Suite

Issue/Introduction

Symptom

When attempting to initialize the PXF (Platform Extension Framework) extension in Greenplum Database using the CREATE EXTENSION pxf; command, the execution fails with the following error:

ERROR:  could not load library "/usr/local/pxf-gp7/gpextable/pxf.so": /usr/local/pxf-gp7/gpextable/pxf.so: undefined symbol: pg_strerror (dfmgr.c:237)

Cause

Cause

This error occurs because the incorrect PXF installation package was deployed on the cluster. Specifically, the PXF package compiled for Greenplum 7 (pxf-gp7) was inadvertently installed on a Greenplum 6 cluster.

Greenplum 6 and Greenplum 7 have different underlying architectures and PostgreSQL dependencies. Because the Greenplum 7 shared library (pxf.so) is being loaded on a Greenplum 6 database, the system encounters an undefined symbol (pg_strerror) that it cannot resolve, leading to the library load failure.

The incorrect installation path can be explicitly seen in the error message itself: /usr/local/pxf-gp7/...

Resolution

Resolution

To resolve this issue, you must remove the incorrect Greenplum 7 PXF package and install the correct PXF package designed for Greenplum 6.

Step 1: Verify the incorrect installation Run the following commands on your host to confirm that the pxf-gp7 package is currently installed and in use:

# Check the installed PXF rpm package
$ rpm -qa | grep pxf

# Check which binary is currently in use in your path
$ which pxf

Step 2: Uninstall the incorrect package Remove the existing pxf-gp7 package from all hosts in the cluster using your OS package manager (e.g., yum or rpm).

Step 3: Install the correct package

  1. Download the correct PXF package for Greenplum 6 (e.g., pxf-gp6-<version>.rpm) from the Broadcom/Tanzu Network.

  2. Install the pxf-gp6 package on all hosts in the Greenplum cluster.

  3. Re-run the PXF initialization steps (prepare, register, and sync): refer to: https://techdocs.broadcom.com/us/en/vmware-tanzu/data-solutions/tanzu-greenplum-platform-extension-framework/7-1/gp-pxf/instcfg_pxf.html 

    $ pxf cluster prepare
    $ pxf cluster register
    $ pxf cluster sync
    
  4. Log into the database and recreate the extension:

    CREATE EXTENSION pxf;