Your HostICan Community  


Go Back   Your HostICan Community > HostICan Web Hosting > Virtual Private Servers (VPS)

Virtual Private Servers (VPS) Need help with your VPS plan on HostICan? Please feel free to ask and we'll give you the answers!

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 10-24-2007, 01:16 PM
itwasntme's Avatar
itwasntme itwasntme is offline
Senior Member
 
Join Date: Sep 2007
Posts: 136
Default Cannot Allocate Memory Error

I'm getting the following error in cPanel's error log:

Quote:
[Wed Oct 24 07:59:10 2007] [error] [client 66.249.72.162] (12)Cannot allocate memory: couldn't create child process: /opt/suphp/sbin/suphp for /home//public_html/index.php
It's been happening every day for the last few days at about the same time, and the site goes down for a while before recovering. It has also happened twice in the afternoon over the past several days. My client is going nuts because they thought moving to a VPS would solve all our problems.

Yesterday, after talking to tech support, I made the following changes to php.ini:
Code:
memory_limit = 256M
max_execution_time = 300
That doubled the memory and the execution time, but this morning, as you can see by the date in the error above, I got the same error.

Unfortunately, I haven't found a way to reproduce the error myself.

I spoke to Hostican again today, and on their advice I restarted Apache just now. The person I spoke to suggested that I consider reverting to an earlier version of PHP (I have 5.2.4) and/or setting up a cron job to restart Apache each morning. He also suggested I post here.

I did a WhoIs on the IP for the error above and it was Google. Kind of interesting, maybe if Google is crawling the site every morning at the same time that would explain the timing, anyway. I don't know if Google has been the culprit each time, though.

Does anyone have any ideas how I can troubleshoot this further or steps I can take to prevent it from happening? Should I go with an earlier version of PHP? Set up a cron job to restart Apache?

I usually try one thing at a time to try to identify what works, so the order to try things in is another question, and since I restarted Apache today, maybe I should give it a day to see if it happens tomorrow?
Reply With Quote
  #2  
Old 10-24-2007, 02:20 PM
chopper chopper is offline
Member
 
Join Date: Sep 2007
Posts: 38
Default

I had a load of problems with php 5.2.4 Im curently running php 5.2.3. I have not hada problem since. So try to downgrade php. What version of apache you running?
Reply With Quote
  #3  
Old 10-24-2007, 02:31 PM
itwasntme's Avatar
itwasntme itwasntme is offline
Senior Member
 
Join Date: Sep 2007
Posts: 136
Default

What kind of problems were you having with PHP 5.2.4? Were you getting any "cannot allocate memory" errors?

I'm running Apache 2.2.6.
Reply With Quote
  #4  
Old 10-24-2007, 02:35 PM
chopper chopper is offline
Member
 
Join Date: Sep 2007
Posts: 38
Default

Yep Samething among others.
Reply With Quote
  #5  
Old 10-24-2007, 02:41 PM
itwasntme's Avatar
itwasntme itwasntme is offline
Senior Member
 
Join Date: Sep 2007
Posts: 136
Default

Thanks for the quick reply.

I guess reverting to PHP 5.2.3 is the way to go. I would like to wait to see if the restart of Apache does the trick, but I'm thinking it's less likely to be the fix than going with the earlier version of PHP based on your experience and what Hostican told me earlier today.

Can I do the reversion to 5.2.3 myself, or is that a support ticket thing?
Reply With Quote
  #6  
Old 10-24-2007, 03:30 PM
chopper chopper is offline
Member
 
Join Date: Sep 2007
Posts: 38
Default

You can do it yourself. through WHM.
Reply With Quote
  #7  
Old 10-24-2007, 03:55 PM
itwasntme's Avatar
itwasntme itwasntme is offline
Senior Member
 
Join Date: Sep 2007
Posts: 136
Default

Cool. I haven't got a clue how to do it, so I'll post another thread asking for some instructions. I'll bet others can use them, too.

Thanks for your help.
Reply With Quote
  #8  
Old 10-24-2007, 04:16 PM
lnxcode's Avatar
lnxcode lnxcode is offline
The British Kid
 
Join Date: Sep 2007
Location: Richmond, VA
Posts: 1,954
Send a message via AIM to lnxcode Send a message via Skype™ to lnxcode
Default

We always recommend sticking about a version behind the latest, as with the latest we find more and more common bugs like this one... where stuff doesn't work. Thanks for the help on this one chopper and itwasntme - this will help others too.
__________________
Thanks,

Denis Motova
Affiliate / Operations Manager

HostICan Answers | HostICan Newsletter | HostICan Blog | Become a HostICan Affiliate | Create a Support Ticket.
Reply With Quote
  #9  
Old 10-26-2007, 01:23 PM
itwasntme's Avatar
itwasntme itwasntme is offline
Senior Member
 
Join Date: Sep 2007
Posts: 136
Default

Well, Hostican downgraded PHP to version 5.2.2 as CGI, and unfortunately, I still got a bunch of 500 errors this am and another "Cannot allocate memory".

So here's a summary of what has been tried so far:
  1. Increase memory_limit to 256M and max_execution_time to 300.
  2. Restart Apache.
  3. Downgrade from PHP 5.2.4 to 5.2.2.

I am at a loss as to what else to do to solve this. Any ideas?
Reply With Quote
  #10  
Old 10-26-2007, 03:08 PM
lnxcode's Avatar
lnxcode lnxcode is offline
The British Kid
 
Join Date: Sep 2007
Location: Richmond, VA
Posts: 1,954
Send a message via AIM to lnxcode Send a message via Skype™ to lnxcode
Default

Hey

I know that you where asking how to do it before (PHP as CGI) so here is a url link too:
http://forum.hostican.com/virtual-pr...r-php-cgi.html

When you restart apache does it fix the issue?
__________________
Thanks,

Denis Motova
Affiliate / Operations Manager

HostICan Answers | HostICan Newsletter | HostICan Blog | Become a HostICan Affiliate | Create a Support Ticket.
Reply With Quote
Reply

Tags
allocate, error, memory

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
HTML code is On
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Fatal Error : Out of Memory ayashi Virtual Private Servers (VPS) 8 06-21-2008 03:21 AM
Mysql Error captainron19 PHP / MySQL Assistance 4 06-14-2008 08:16 AM
Apache-WHM Parsing Error (1 change per session) marcOpolo Virtual Private Servers (VPS) 0 01-29-2008 08:26 PM
Ajust memory on my vps Mars Virtual Private Servers (VPS) 8 01-14-2008 02:22 PM
CGI error domz Shared Hosting 3 10-04-2007 04:10 AM


All times are GMT -4. The time now is 01:26 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.

Copyright © 2003 - 2008 HostICan. All Rights Reserved.