LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices



Reply
 
Search this Thread
Old 07-07-2010, 08:11 PM   #1
chris_J_W
LQ Newbie
 
Registered: Aug 2003
Posts: 7

Rep: Reputation: 0
Question Apache2, suexec error: command not in docroot (/usr/bin/php-cgi)


Hi, I'm having a bit of trouble getting suexec to run properly.

Basically when I try execute a PHP script with SuexecUserGroup set, I get the following error:

uid: (501/uname) gid: (501/501) cmd: php-cgi
command not in docroot (/usr/bin/php-cgi)

Without SuexecUserGroup set, they work fine, but obviously aren't executed as the script's owner.

Here's one of the domain's configs:
Code:
<VirtualHost *:80>
    ServerName www.domain
    ServerAlias domain

    SuexecUserGroup uname gname

    ServerAdmin webmaster@domain
    DocumentRoot /var/www/domain/public_html


    <Directory /var/www/domain/public_html/>
        Order allow,deny
        allow from all
    </Directory>

    ErrorLog logs/domain-error_log
    CustomLog logs/domain-access_log common
</VirtualHost>
And the suexec config info

Code:
suexec -V
 -D AP_DOC_ROOT="/var/www"
 -D AP_GID_MIN=100
 -D AP_HTTPD_USER="apache"
 -D AP_LOG_EXEC="/var/log/httpd/suexec.log"
 -D AP_SAFE_PATH="/usr/local/bin:/usr/bin:/bin"
 -D AP_UID_MIN=500
 -D AP_USERDIR_SUFFIX="public_html"
Any suggestions on what I might be doing wrong? I can provide other info if needed.



For a bit of background info, the end result i'm trying to achieve is for files that get uploaded via a php script to be owned by the user account that owns the script rather than by the apache user. From what I can tell, suexec is the way to accomplish this.
 
Old 07-17-2010, 03:57 PM   #2
millergroup
Member
 
Registered: Oct 2009
Posts: 39

Rep: Reputation: 15
Try SuexecUserGroup apache apache

Last edited by millergroup; 07-17-2010 at 03:59 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
echo $PATH = /home/g3rc4n/bin:/usr/local/bin:/usr/bin:/bin:/usr/games ? i_heart_pandas Linux - Software 7 09-18-2009 09:33 AM
Error compiling PHP: /usr/bin/ld: cannot find -lltdl nyheat Linux - Server 4 09-16-2009 03:40 PM
Apache2 cgi-bin Forbidden Access cluckshot Linux - Software 5 01-09-2009 01:26 PM
why can't create a folder in /usr/lib/cgi-bin adam_ant Linux - Software 2 12-07-2005 06:05 AM
linux command error message bash: /usr/bin/find: No such file or directory sundaram123 Linux - General 8 04-02-2002 08:18 AM


All times are GMT -5. The time now is 12:24 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration