LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
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 02-02-2012, 10:42 AM   #1
mikeyyy2
LQ Newbie
 
Registered: Feb 2012
Posts: 2

Rep: Reputation: Disabled
PHP with suexec/fcgid


httpd.conf file:

Code:
LoadModule fcgid_module modules/mod_fcgid.so
AddHandler fcgid-script .php
FCGIWrapper /usr/local/php5 .php

# manual
MaxRequestsPerProcess 1000
FcgidMaxProcesses 200
FcgidProcessLifeTime 7200
MaxProcessCount 500
FcgidIOTimeout 400
FcgidIdleTimeout 600
FcgidIdleScanInterval 90
FcgidBusyTimeout 300
FcgidBusyScanInterval 80
ErrorScanInterval 3
ZombieScanInterval 3
DefaultMinClassProcessCount 0
DefaultMaxClassProcessCount 3
MaxRequestLen 20468982

<VirtualHost *>
    ServerName hostname
    DocumentRoot /home/web
    ServerAdmin web@web.com
    <IfModule mod_suphp.c>
        suPHP_UserGroup web web
    </IfModule>
         SuexecUserGroup web web
    UserDir disable
</VirtualHost>
and this is my wrapper:

Code:
#!/bin/sh
exec /usr/local/bin/php
my error is:

Code:
/usr/local/apache2/logs/suexec_log
[2019-09-03 06:55:28]: user mismatch (daemon instead of www)
Code:
/usr/local/apache2/logs/error_log
suexec policy violation: see suexec log for more details
Code:
[Tue Sep 03 06:55:28 2019] [warn] [client 127.0.0.1] (104)Connection reset by peer: mod_fcgid: error reading data from FastCGI server
[Tue Sep 03 06:55:28 2019] [error] [client 127.0.0.1] Premature end of script headers: phpinfo.php

UPDATES:

I've edited:

Code:
 /usr/local/apache2/bin/suexec -V
 -D AP_DOC_ROOT="/"
 -D AP_GID_MIN=100
 -D AP_HTTPD_USER="www"
 -D AP_LOG_EXEC="/usr/local/apache2/logs/suexec_log"
 -D AP_SAFE_PATH="/usr/local/bin:/usr/bin:/bin"
 -D AP_UID_MIN=100
 -D AP_USERDIR_SUFFIX="www"
but no I get no errors and nothing found...
 
  


Reply



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
issues with setting up apache, fcgid, php on CentOS ppostma1 Linux - Server 8 02-03-2012 03:16 PM
httpd-2.2.3 | error - suEXEC mechanism enabled (wrapper: /usr/sbin/suexec) jmahto Linux - Enterprise 3 07-14-2010 01:53 AM
Apache + PHP xdebug + fcgid = read data timeout in 40 seconds Miggleness Linux - Software 1 12-18-2009 09:43 AM
apache + php suexec gimmereeson Linux - Server 0 09-18-2007 11:24 AM
apache php suexec problem pecko Linux - Software 0 02-24-2006 05:22 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 09:29 PM.

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
Open Source Consulting | Domain Registration