Re: apache permission denied

From: Chris Cosner <ccosner(at)stanford(dot)edu>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: apache permission denied
Date: 2008-07-10 18:49:11
Message-ID: 487659A7.7080208@stanford.edu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Peter Eisentraut wrote:
> Am Donnerstag, 10. Juli 2008 schrieb Chris Cosner:
>> 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
>
> An strace of the program would probably give definite insight, but "Permission
> denied" sounds to me like a file system error message. Possibly, you don't
> have proper permissions (at least u+x) on the socket file (in (/tmp). But
> you would have to have done serious "customization" to get to that state.
> Mayb you have some fancy security configured around your Apache instance?
>

Thanks--SELinux was in fact enabled, and when I set it to permissive
(i.e., audit only), httpd error_log now gives a login error:

DBI connect('dbname=db','',...) failed: FATAL: role "apache" is not
permitted to log in at /home/www/cgi-bin/db.lib line 1635

The postgresql version is 8.1.11

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Scott Marlowe 2008-07-10 18:50:52 Regex problem
Previous Message Marc Munro 2008-07-10 18:39:53 Re: pgmemcache status