I’ve installed postgresql 9.2 on linux (kubuntu) and the last version of pgadmin3, but when I connect them I have this error:
An error has occurred:
Error connecting to the server: fe_sendauth: no password supplied
What can I do?
I have also configured tomcat for my web application in java. In fact, postgresql was working before trying my application.
Whether a password is required depends on your settings in
pg_hba.conf. And there are different ways you can connect – different settings in pg_hba.conf may apply.I quote the help shipped with pgAdmin 3 for the “Host” field in the connection (“server”) settings:
If you connect via Unix socket the rules for “local” apply.
Whereas when connecting via TCP/IP “host” (or “hostssl”) rules applies.
If you have a line like this at the top your pg_hba.conf file:
or:
.. then you can connect locally without password if your system user is “postgres” and your database user is “postgres”, too.