Hello. I posted a question in singger-targets but ...
# troubleshooting
j
Hello. I posted a question in singger-targets but this may be a better place for the issue I'm having. I'm doing a poc using target-redshift however I'm unable to get it to connect. I always get the following error:
Copy code
redshift_connector.error.InterfaceError: {'S': 'FATAL', 'C': '28000', 'M': 'no pg_hba.conf entry for host "::ffff:some.ip.address.1", user "some_user", database "test_db", SSL off', 'F': '/opt/brazil-pkg-cache/packages/RedshiftPADB/RedshiftPADB-1.0.17891.0/AL2_x86_64/generic-flavor/src/src/pg/src/backend/libpq/auth.c', 'L': '477', 'R': 'ClientAuthentication'}
ssl mode is off. Is there a different setting I need to configure so that it doesn't try to use pg_hba.conf?
c
Are there any special characters in your password that might be getting gobbled up somewhere, that is the only difference I can think of that might impact things different to you testing connection directly. Also when connecting from the docker container, are you using the same python library to attempt the connection for likeness.
j
Thanks. I'll look into the password. Currently I have it in the .env file surrounded by quotes ('), the password itself doesn't have quotes. As far as I can tell target-redshift is using
redshift_connector
library. I wrote a simple python script which uses
redshift_connector
to connect to redshift and does a simple
cursor.execute("SELECT 1")
query. I don't get any errors when running this script.
just an fyi... I was able to get over the error by setting ssl_enable to true and ssl_mode require
👍 1