February 2nd, 2012, 04:58 AM
Peer Authentication Failed
I pretty new to psql (noob really) but I am trying to configure it for use with a network monitoring software called Zabbix. I am running Ubuntu Server 11.10 with KDE desktop and psql 9.1.2. Now my issue is when I try to use the below command to just connect to psql:
psql -U zabbix
but I get this error:
psql: FATAL: Peer authentication failed for user "zabbix"
I have run that as is and with the sudo command also tried changing the user at the command line with the su command and running it under zabbix account but still get the same error and the services are definitely started. Not sure if there is something I am missing or there is an issue with the install/configuration of psql.
I also changed the pg_hba.conf file by adding the below to file including what is there by default:
local all all trust
local all all md5
host all all 127.0.0.1/32 trust
Any help would be awesome as I stumped with this.
February 2nd, 2012, 06:03 AM
Does the Zabbix software install a user called zabbix? If so, the docs should tell you what the default password is. I have no clue about postgres (just looked at the online docs), but it looks like you may want to use the -W flag to force a password prompt.
The moon on the one hand, the dawn on the other:
The moon is my sister, the dawn is my brother.
The moon on my left and the dawn on my right.
My brother, good morning: my sister, good night.
-- Hilaire Belloc