hosted by liquidweb


Go Back   Web Hosting Talk : Web Hosting Main Forums : VPS Hosting : mod_fcgid: can't apply process slot for
Reply

Forum Jump

mod_fcgid: can't apply process slot for

Reply Post New Thread In VPS Hosting Subscription
 
Send news tip View All Posts Thread Tools Search this Thread Display Modes
  #1  
Old
Web Hosting Guru
 
Join Date: Jul 2011
Location: Who knows
Posts: 269

mod_fcgid: can't apply process slot for


Hi all,
I'm having error log with this error "mod_fcgid: can't apply process slot for /home/MY DOMAIN/fcgi-bin/php5.fcgi"

Server running process became 400+ Ram used 1.4GB out of 2GB

VPS with Virtualmin Control Panel
Debian OS
2GB RAM

Please help me here.

__________________
Learn a lot in WHT many expert have helped me out...



Sponsored Links
  #2  
Old
Junior Guru Wannabe
 
Join Date: Jan 2013
Location: Virginia Beach, Va
Posts: 52
Post Setting FastCGI defaults

It looks like you're using FastCGI as your PHP handler, which by default has some pretty low limits associated with it, especially for MaxProcessCount. Since you're on a VPS you can bump up the defaults a bit to allow more concurrent PHP processes to run at once, and stop these types of errors from happening.

You might want to ask your host about this depending on how they have things configured for you. In my case the default settings for FastCGI are adjusted here:

/usr/local/apache/conf/php.conf

Here are the settings I've been using that seem to work in most cases:

Code:
# Fastcgi configuration for PHP5
LoadModule fcgid_module modules/mod_fcgid.so
MaxRequestsPerProcess 500
MaxProcessCount 3
MaxRequestLen 33554432
IPCCommTimeout 60
IdleTimeout 120
IdleScanInterval 30
BusyTimeout 120
BusyScanInterval 90
ErrorScanInterval 3
ZombieScanInterval 3
ProcessLifeTime 3600
If it's not your FastCGI limits that are causing these errors, I've also seen it where you need to correct permissions to (755) on the log directory FastCGI tries to use. I think in your case that'd be /var/log/virtualmin/, other common places to check would be /var/log/httpd and /usr/local/apache/logs/.

Hope that helps, good luck.

- Jacob

  #3  
Old
Web Hosting Guru
 
Join Date: Jul 2011
Location: Who knows
Posts: 269
Quote:
Originally Posted by JacobN View Post
It looks like you're using FastCGI as your PHP handler, which by default has some pretty low limits associated with it, especially for MaxProcessCount. Since you're on a VPS you can bump up the defaults a bit to allow more concurrent PHP processes to run at once, and stop these types of errors from happening.

You might want to ask your host about this depending on how they have things configured for you. In my case the default settings for FastCGI are adjusted here:

/usr/local/apache/conf/php.conf

Here are the settings I've been using that seem to work in most cases:

Code:
# Fastcgi configuration for PHP5
LoadModule fcgid_module modules/mod_fcgid.so
MaxRequestsPerProcess 500
MaxProcessCount 3
MaxRequestLen 33554432
IPCCommTimeout 60
IdleTimeout 120
IdleScanInterval 30
BusyTimeout 120
BusyScanInterval 90
ErrorScanInterval 3
ZombieScanInterval 3
ProcessLifeTime 3600
If it's not your FastCGI limits that are causing these errors, I've also seen it where you need to correct permissions to (755) on the log directory FastCGI tries to use. I think in your case that'd be /var/log/virtualmin/, other common places to check would be /var/log/httpd and /usr/local/apache/logs/.

Hope that helps, good luck.

- Jacob
Hi Jacob, Thank you so much for replying,
actually i try to find /usr/local/apache/conf/php.conf but i couldn't find apache directory in usr/local

for your 2nd option yes i have already change directory permission to 755 but still i face the same problem so i want to try your 1st option yet i couldn't find the file php.conf on ubuntu using apache2 / php5

Thank you

__________________
Learn a lot in WHT many expert have helped me out...


Last edited by anthonyinit; 01-04-2013 at 09:38 AM.
Sponsored Links
  #4  
Old
Web Hosting Guru
 
Join Date: Jul 2011
Location: Who knows
Posts: 269
is there anything to edit here?
/etc/apache2/mods-available/fcgid.conf

__________________
Learn a lot in WHT many expert have helped me out...

  #5  
Old
Junior Guru Wannabe
 
Join Date: Jan 2013
Location: Virginia Beach, Va
Posts: 52
Quote:
Originally Posted by anthonyinit View Post
is there anything to edit here?
/etc/apache2/mods-available/fcgid.conf
Hello Anthony,

No problem at all for the help.

Yes it does look like in your case you'd need to modify that file more than likely:

Code:
/etc/apache2/mods-available/fcgid.conf
Another way to check is by taking a look at the includes in your Apache httpd.conf file. If you don't know the location on your server you should be able to use:

Code:
locate httpd.conf
It will typically be in a .../apache/conf/httpd.conf location. Once you find the file run:

Code:
grep Include /usr/local/apache/conf/httpd.conf
That will spit back all your Apache includes, more than likely you'll see the path to your fcgid.conf there, confirming that configuration is getting applied into Apache.

You might have something currently along the lines of:

Code:
<IfModule mod_fcgid.c>
  AddHandler    fcgid-script .fcgi
  FcgidConnectTimeout 20
</IfModule>
Below your AddHandler line, is where you can set all the settings for FastCGI. Just use the same rules I mentioned before, you probably don't need to use all of them, as that errors is typically just from the MaxProcessCount 3 rule not being there. However in my experience the other settings are also helpful from a maximizing performance, and reducing errors standpoint for FastCGI. Since for instance without the MaxRequestLen 33554432 being set, you could encounter upload errors from your PHP scripts.

Let me know if that did the trick for you.

- Jacob

  #6  
Old
Web Hosting Guru
 
Join Date: Jul 2011
Location: Who knows
Posts: 269
Hi again Jacob,
my httpd.conf also located in the same directory
Quote:
/etc/apache2
but there is nothing on the file it is blank, however apache2.conf has many details

in my fcgid.conf file i see exactly same thing u mention
Quote:
<IfModule mod_fcgid.c>
AddHandler fcgid-script .fcgi
FcgidConnectTimeout 20
</IfModule>
so i edit that file and add what you mansion before now it looks like this
Quote:
<IfModule mod_fcgid.c>
AddHandler fcgid-script .fcgi
FcgidConnectTimeout 20
MaxProcessCount 3
MaxRequestLen 33554432
</IfModule>
hope this way is correct, i don't have much experience on these things and my server is unmanaged. one more thing about a week ago i contacted my hosting company and seek their help and they told me that my issue is more likely FcgidMaxProcesses and FcgidMaxRequestLen exact the same thing you mention but i didn't know how and where to edit this but thanks to you now i know which file to edit, now that i edit these value i should give sometime and see if this will fix my issue and i will keep you posted

once i thank you so much for your support.

__________________
Learn a lot in WHT many expert have helped me out...

  #7  
Old
Disabled
 
Join Date: Jan 2013
Posts: 4
Quote:
Originally Posted by anthonyinit View Post
Hi all,
I'm having error log with this error "mod_fcgid: can't apply process slot for /home/MY DOMAIN/fcgi-bin/php5.fcgi"

Server running process became 400+ Ram used 1.4GB out of 2GB

VPS with Virtualmin Control Panel
Debian OS
2GB RAM

Please help me here.
Why don't u use mod_php or suphp or dso ?

  #8  
Old
Web Hosting Guru
 
Join Date: Jul 2011
Location: Who knows
Posts: 269
Quote:
JacobN
So far no crash found in 2 days i guess u helped me troubleshoot my issue. server running smooth apache2 running smooth

Thank you so much

__________________
Learn a lot in WHT many expert have helped me out...

  #9  
Old
Junior Guru Wannabe
 
Join Date: Jan 2013
Location: Virginia Beach, Va
Posts: 52
Quote:
Originally Posted by anthonyinit View Post
Thank you so much
Hey anthonyinit,

Awesome! No problem at all, I know that's a frustrating problem to deal with, so glad to hear that worked for you.

I've had countless VPS customers that I've had to do these steps for on our own cPanel/CentOS servers where I work <<snipped>> Thanks for getting back to me and letting me know the same tactics appear to work elsewhere as well

Hope things keep chugging along nicely for you!

- Jacob


Last edited by not-even-a-mouse; 02-21-2013 at 06:55 PM.
Reply

Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache+FastCGI - mod_fcgid: can't apply process slot vbgamer45 Hosting Security and Technology 1 07-06-2011 05:20 PM
CSS, CS1.6, TF2, DoD & More! $10 10-Slot 1000FPS, $15 10-Slot 2000FPS Brad Groux Other Hosting Offers 0 10-20-2010 10:14 AM
CSS, CS1.6, TF2, DoD & More! $10 10-Slot 1000FPS, $15 10-Slot 2000FPS Brad Groux Other Hosting Offers 0 10-10-2010 11:24 PM
Web Templates Site banner slot available - 1 slot left for 20,000 uniques! KCgame Advertising Offers 0 01-05-2010 11:33 PM
LimitZero.net - West Game Servers! $2.25/Pub Slot $1.50/Priv Slot zxfire Dedicated Hosting Offers 9 05-15-2005 01:25 AM

Related posts from TheWhir.com
Title Type Date Posted
Health Care Provider Faces $150,000 Fine After Failing to Apply Software Patches Web Hosting News 2014-12-17 11:21:19
The eMetrics Summit Toronto - May 12-15, 2014 Web Hosting Events 2014-04-14 15:33:02
Virginia Cybersecurity Startup Accelerator MACH37 Opens up Applications for Spring Cohort Web Hosting News 2013-12-18 12:33:20
Symantec to Discontinue Backup Exec.Cloud; Customers Presented with Next-Step Options Web Hosting News 2013-12-03 14:49:46
Amazon Web Services Reduces Price of DynamoDB NoSQL, Adds Reserved Capacity Web Hosting News 2013-03-08 15:19:40


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes
Postbit Selector

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

Forum Jump
Login:
Log in with your username and password
Username:
Password:



Forgot Password?
WHT Host Brief Email:

We respect your privacy. We will never sell, rent, or give away your address to any outside party, ever.

Advertisement:
Web Hosting News:
WHT Membership
WHT Membership



 

X

Welcome to WebHostingTalk.com

Create your username to jump into the discussion!

WebHostingTalk.com is the largest, most influentual web hosting community on the Internet. Join us by filling in the form below.


(4 digit year)

Already a member?