steampipe-postgres-fdw icon indicating copy to clipboard operation
steampipe-postgres-fdw copied to clipboard

/lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.32' not found while using cloudnativepg on top of fdw

Open sadathknorket opened this issue 1 year ago • 3 comments

Here is the error

ERROR:  could not load library "/usr/lib/postgresql/15/lib/steampipe_postgres_aws.so": /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.32' not found (required by /usr/lib/postgresql/15/lib/steampipe_postgres_aws.so)

I have the following Dockerfile for running postgres fdw

# Stage 1: Building the Go executable
FROM golang:1.22.2-bookworm AS build

WORKDIR /build

COPY ./ .

RUN go build -o main main.go

# Final image
FROM postgres:15

ENV TERM=xterm

RUN apt-get update && apt-get upgrade -y && \
    apt-get install -y curl && \
    rm -rf /var/lib/apt/lists/*

COPY install_fdw.sh /tmp/
RUN /tmp/install_fdw.sh && \
    rm /tmp/install_fdw.sh


COPY --from=build /build/main /
COPY --from=build /build/init.sh /docker-entrypoint-initdb.d

I decided to shift to cloudnativepg

and tried using postgres image with ghcr.io/cloudnative-pg/postgresql:15

Its very hard and error prone to upgrade GLIBC and I still did not succeed . Is there any other smart solution in place here?

sadathknorket avatar Aug 21 '24 14:08 sadathknorket