I am trying to have airbyte connect to my postgres...
# replication-ask-ai
b
I am trying to have airbyte connect to my postgres database in the same cluster as external database. I am using the helm chart and have this in my values
Copy code
database:
    secretName: airbyte-secrets
    secretValue: postgresql-password
    host: postgresql-nodeport.database.svc.cluster.local
    port: 5432
Copy code
externalDatabase:
  host: postgresql-nodeport.database.svc.cluster.local
  user: test
  existingSecret: airbyte-secrets
  existingSecretPasswordKey: postgresql-password
  database: db-airbyte
  port: 5432
  jdbcUrl: jdbc:<postgresql://postgresql-nodeport.database.svc.cluster.local:5432/db-airbyte>
but its not working. I receive an error like this
Copy code
at org.postgresql.shaded.com.ongres.scram.common.stringprep.StringPreparations.normalize(StringPreparations.java:65) ~[postgresql-42.5.4.jar:42.5.4]	at org.postgresql.shaded.com.ongres.scram.common.ScramMechanisms.saltedPassword(ScramMechanisms.java:152) ~[postgresql-42.5.4.jar:42.5.4]	at org.postgresql.shaded.com.ongres.scram.common.ScramFunctions.saltedPassword(ScramFunctions.java:59) ~[postgresql-42.5.4.jar:42.5.4]	at org.postgresql.shaded.com.ongres.scram.client.ScramSession$ClientFinalProcessor.<init>(ScramSession.java:196) ~[postgresql-42.5.4.jar:42.5.4]	at org.postgresql.shaded.com.ongres.scram.client.ScramSession$ClientFinalProcessor.<init>(ScramSession.java:163) ~[postgresql-42.5.4.jar:42.5.4]	at org.postgresql.shaded.com.ongres.scram.client.ScramSession$ServerFirstProcessor.clientFinalProcessor(ScramSession.java:130) ~[postgresql-42.5.4.jar:42.5.4]	at org.postgresql.jre7.sasl.ScramAuthenticator.processServerFirstMessage(ScramAuthenticator.java:147) ~[postgresql-42.5.4.jar:42.5.4]	at org.postgresql.core.v3.ConnectionFactoryImpl.doAuthentication(ConnectionFactoryImpl.java:863) ~[postgresql-42.5.4.jar:42.5.4]	at org.postgresql.core.v3.ConnectionFactoryImpl.tryConnect(ConnectionFactoryImpl.java:203) ~[postgresql-42.5.4.jar:42.5.4]	at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:258) ~[postgresql-42.5.4.jar:42.5.4]	at org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:54) ~[postgresql-42.5.4.jar:42.5.4]	at org.postgresql.jdbc.PgConnection.<init>(PgConnection.java:253) ~[postgresql-42.5.4.jar:42.5.4]	at org.postgresql.Driver.makeConnection(Driver.java:434) ~[postgresql-42.5.4.jar:42.5.4]	at org.postgresql.Driver.connect(Driver.java:291) ~[postgresql-42.5.4.jar:42.5.4]	at com.zaxxer.hikari.util.DriverDataSource.getConnection(DriverDataSource.java:138) ~[HikariCP-5.0.1.jar:?]	at com.zaxxer.hikari.pool.PoolBase.newConnection(PoolBase.java:359) ~[HikariCP-5.0.1.jar:?]	at com.zaxxer.hikari.pool.PoolBase.newPoolEntry(PoolBase.java:201) ~[HikariCP-5.0.1.jar:?]	at com.zaxxer.hikari.pool.HikariPool.createPoolEntry(HikariPool.java:470) ~[HikariCP-5.0.1.jar:?]	at com.zaxxer.hikari.pool.HikariPool$PoolEntryCreator.call(HikariPool.java:733) ~[HikariCP-5.0.1.jar:?]	at com.zaxxer.hikari.pool.HikariPool$PoolEntryCreator.call(HikariPool.java:712) ~[HikariCP-5.0.1.jar:?]	at java.util.concurrent.FutureTask.run(FutureTask.java:317) ~[?:?]	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144) ~[?:?]	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642) ~[?:?]	at java.lang.Thread.run(Thread.java:1589) ~[?:?]
Any idea what I might be doing wrong?
k
Based on the information provided in the extracts, it seems like you have correctly set up the connection to your external Postgres database in your Helm chart values. However, the error message you're seeing suggests that there might be an issue with the authentication process when trying to connect to your Postgres database. Here are a few things you could check: 1. Ensure that the
secretName
and
secretValue
you've provided in your Helm chart values match the actual secret name and value in your Kubernetes cluster. The secret should contain the correct password for your Postgres database. 2. Check that the
user
and
database
values under
externalDatabase
in your Helm chart values are correct. The user should have the necessary permissions to access the specified database. 3. Verify that your Postgres database is correctly configured to allow connections from your Airbyte instance. If you're using Airbyte Cloud, you'll need to allow inbound traffic from Airbyte IPs as mentioned in the [Airbyte Security docs](https://docs.airbyte.com/operator-guides/security#network-security-1). 4. The
jdbcUrl
you've provided seems to have an extra
<
and
>
around the URL. Make sure to remove these as they might be causing issues with the connection. If you've checked all of these and are still experiencing issues, it might be helpful to look at the logs of your Airbyte server and worker pods for any additional error messages. You can do this by running
kubectl logs <pod-name>
for each of these pods. If none of the above helps, it might be a good idea to post your issue on the [Airbyte forum](https://discuss.airbyte.io) or [GitHub](https://github.com/airbytehq/airbyte/issues) for further assistance.