Using RHEL 5, with Postgresql 8.1, Apache, mod_perl, mod_auth_pgsql, DBI, DBD::Pg

Perl cgi scripts that access the database get the following in httpd error_log: DBI connect('dbname=db','',...) failed: could not connect to server: Permission denied

A direct test with a simple SQL command in the file, "command"
# sudo -u apache psql db < command
psql: FATAL:  role "apache" is not permitted to log in

At the psql command line, \z shows
apache=arwdRxt
for all tables

And httpd.conf definitely has
User apache
Group apache

I have restarted httpd and postmaster and the machine. These scripts work with postgresql 7x, but the grant syntax is different in 8x, so I wonder if the problem is how to grant apache privileges, or some extra step I'm missing.

--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

Reply via email to