OperationalError: SCRAM authentication requires libpq version 10 or above

0

Glue is throwing this error when trying to work with psycopg2. How can I update libpq version on glue? This is a C library thats typically sym linked in the environment, this is not installed via python.

demandé il y a un an4317 vues
2 réponses
0

The version of libpq used by AWS Glue is managed by AWS and cannot be updated by users. However, you can try using an older version of psycopg2 that is compatible with the version of libpq used by AWS Glue.

You can also try using the pure Python implementation of PostgreSQL client library, psycopg2-binary, which does not have any dependency on libpq. You can install it by running the following command:

pip install psycopg2-binary

Once you have installed psycopg2-binary, you can import it in your Glue job and use it instead of psycopg2. For example:

import psycopg2_binary as psycopg2
# use psycopg2 in your code as usual

This should allow you to use PostgreSQL with AWS Glue without encountering the SCRAM authentication requires libpq version 10 or above error.

profile picture
EXPERT
répondu il y a un an
0

A temporary solution until libraries are updated is to revert the databases back to password encryption as MD5 after the database upgrade. This is accomplished by creating DB cluster custom parameter group, changing the parameter 'password_encryption' to MD5, and applying it to the cluster. Take note all nodes will need to be restarted.

You can see what password encryption is set to by running: CREATE EXTENSION rds_tools; SELECT * FROM rds_tools.role_password_encryption_type();

This will solve the problem quickly allowing for time to get all the libraries upgraded and tested.

profile pictureAWS
répondu il y a un an

Vous n'êtes pas connecté. Se connecter pour publier une réponse.

Une bonne réponse répond clairement à la question, contient des commentaires constructifs et encourage le développement professionnel de la personne qui pose la question.

Instructions pour répondre aux questions