MySQL Access from Apache/PHP forbidden by Kernel??

General Discussion of atomic repo and development projects.

Ask for help here with anything else not covered by other forums.
KaTXi
Forum User
Forum User
Posts: 15
Joined: Thu Apr 20, 2006 5:50 pm

MySQL Access from Apache/PHP forbidden by Kernel??

Unread post by KaTXi »

Here I am again :D
First of all, I have to recognice that this is my first SELinux install, so maybe the problem it's there.

The problem I have now is that I can't connect to a MySQL DB from a PHP, I have a connection error and in /var/log/messages I get this:

Code: Select all

Apr 22 12:30:50 areyero kernel: audit(1145727050.577:272): avc:  denied  { search } for  pid=21340 comm="httpd" name="/" dev=sdb2 ino=2 scontext=root:system_r:httpd_t tcontext=system_u:object_r:file_t tclass=dir
(yes, that pid is from apache).

The strange thing it's that I can connect to MySQL from Plesk, and PHPMyAdmin (well, "DB WebAdmin" :D ) works great and I can manage the database from there.

It doesn't seem a DB problem, I can also connect in command line using the same parameters (login, password, host, db...) than I'm using in PHP.
This same application is working great on our current host, BTW.
scott
Atomicorp Staff - Site Admin
Atomicorp Staff - Site Admin
Posts: 8355
Joined: Wed Dec 31, 1969 8:00 pm
Location: earth
Contact:

Unread post by scott »

Wish I could help you more here, SELinux is still pretty nebulous in its configuration and reporting. It where grsec was about 10 years ago. While I left support in for it in the ASL kernels, I turn it off by default, and rely on the grsec ACL system instead.
KaTXi
Forum User
Forum User
Posts: 15
Joined: Thu Apr 20, 2006 5:50 pm

Unread post by KaTXi »

I see... I guess that I should disable it, nobody is isn't it anyway :D
Post Reply