https://linen.dev logo
#ask-community-for-troubleshooting
Title
# ask-community-for-troubleshooting
i

Isaline L.

07/14/2021, 1:15 PM
Hello, I'm trying to setup my Postgres DB as a destination with Airbyte running locally. It works fine when I use a super user, but doesn't work with my dedicated Airbyte user. I can connect without an issue when accessing the DB directly with that user, but Airbyte gets a "Could not connect with provided configuration. ERROR: permission denied for database <database>". Any idea? The DB is hosted on AWS RDS, but the IP is allowed (and again, it works when using a super user, and when accessing it via other tools). Thanks in advance!
1
u

[DEPRECATED] Marcos Marx

07/14/2021, 1:19 PM
It works fine when I use a super user, but doesn't work with my dedicated Airbyte user.
this works fine when connecting using Airbyte but with the super user?
i

Isaline L.

07/14/2021, 1:23 PM
Yep, if I use the super user in my Airbyte config it works.
So it seems than it's not a problem with the database itself.
u

[DEPRECATED] Marcos Marx

07/14/2021, 1:24 PM
Can you confirm you gave the right permissions to
airbyte
user?
i

Isaline L.

07/14/2021, 1:41 PM
I confirm indeed.
It would give me a different error though, since I can access the DB with the airbyte user? 🤔
u

[DEPRECATED] Marcos Marx

07/14/2021, 1:55 PM
Probably, if you dont have access to your database the error should be: Could access database IP-POSTGRES-RDS. not permission denied
did you commit the grant schema for the airbyte user? (not pro on Postgres syntax if this is needed)
i

Isaline L.

07/14/2021, 2:14 PM
I don't think that's necessary indeed, I can see that they are set the correct way in DB.. I'm probably doing something so stupid I can't see it. 😅 I'll try again later with a clearer mind, thanks for you help in any case. 🙂
Well actually, found the culprit!
airbyte rocket 1
The user needs to be able to create schema as well, I checked my logs, the connection succeeded, but then it was trying to create the schema (if not exists), and that's what was going wrong.
I don't know how easy that would be, but it would be pretty useful to add the details from the error.
The actual error was
Copy code
ERROR: permission denied for database <schema>
STATEMENT: CREATE SCHEMA IF NOT EXISTS <schema>
with the second line it was obvious.
(Note that I could have thought earlier about checking the logs too. 😅 )