When connecting to PostgreSQL I get a Could Not Translate Hostname to Address error
Validated on 4 Oct 2022 • Last edited on 6 Sep 2023
psql: could not translate host name "cluster-do-user-1234567-0.db.ondigitalocean.com" to address: Name or service not known
A Could Not Translate Hostname to Address
error occurs when:
- You use the wrong DNS hostname.
- There are underlying problems with DNS resolution.
If you are getting this error:
- Verify that your hostname is correct.
- Verify whether the machine you’re connecting from has problems with DNS resolution.