Q:

postgresql: Peer authentication failure with md5

In setting up my postgresql installation, I determined that a user attempting to log in with a password, when not on its respective OS user, is failing authentication with the following message:
$ psql -d postgres confluence -W
psql: FATAL:  Peer authentication failed for user "confluence"

Some quick Google searches told me to update my pg_hba.conf file. Since I'm in CentOS 6.5, running postgresql 9.3, the file was located at /var/lib/pgsql/data/pg_hba.conf.
The file originally contained:
# TYPE  DATABASE    USER        CIDR-ADDRESS          METHOD
# "local" is for Unix domain socket connections only
local   all         all                               ident
# IPv4 local connections:
host    all         all         127.0.0.1/32          ident
# IPv6 local connections:
host    all         all         ::1/128               ident

The contents of the file are now:
# TYPE  DATABASE    USER        CIDR-ADDRESS          METHOD
# "local" is for Unix domain socket connections only
local   all   confluence                              md5
local   all         all                               md5
# IPv4 local connections:
host    all         all         127.0.0.1/32          md5
# IPv6 local connections:
host    all         all         ::1/128               md5

(I suspect the md5 on all of them is a tad excessive since I'm theoretically only dealing with domain socket connections at this point, but I'd like to get all of my bases covered.)
I expected a restart of postgresql to do the trick, so i executed:
sudo /etc/init.d/postgresql-9.3 restart

Which reported successfully. Unfortunately there was no change to the behavior of the login attempts.
In a final effort to get a fresh load of the configuration file, I performed a full reboot, but nothing has changed.
Thoughts on what is missing here, anyone?
Edit:
In an attempt to verify that the file is being considered at all, i changed the method all all connections to 'trust', and with a service restart as above, I'm getting the following:
$ psql -d postgres confluence
psql: FATAL: Peer authentication failed for user "confluence"

A:

If you are using Centos 6.5, and you have installed the RPMs provided by the Postgresql yum repo, then you will find the pg_hba.conf file is actually located in /var/lib/pgsql/9.3/data/, not /var/lib/pgsql/data/.
As you probably suspected by now, you have been modifying a file which is not read by the system at all.
The older postgresql RPMs used to place the postgresql data directory under /var/lib/pgsql/data, but at some point (9.0?) they moved it to a version-specific path, which makes it easier to run the pg_upgrade tool to migrate from one version to the next. Most likely, the directory you have been playing with is one left behind by one of these older versions.

