Home Server Apache Solution to: How do I fix the following error when using Apache/PHP/FastCGI/suEXEC?...

Get social!

I use FastCGI/suEXEC on my Apache server for PHP scripts. Recently, when creating a new virtual host, the following error message creeped up in the global Apache log error file (not the virtual host’s error file):

suexec policy violation: see suexec log for more details

Accompanying this error was a 500 error in the browser.

Solution

suEXEC is picky about file permissions. I needed to set the virtual hosts fastcgi wrapper script (and parent folder, I think) to the user/group I set in the SuexecUserGroup setting in the Apache config file. So because I had these two lines in the conf file:

I had to chown the script and parent folder like this:

Silly mistake that was quickly fixed.

Caveats

I’m not 100% sure if changing the permissions on the parent folder is necessary. You can try just the script first, and if that doesn’t work, then change the parent folder perms as well.

Leave a Reply

Bad Behavior has blocked 35 access attempts in the last 7 days.