PassMark Logo
Home » Forum

Announcement

Collapse
No announcement yet.

PHP / CGI script returns no results on Apache RLimitMEM & RLimitCPU

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • David
    replied
    They will not tell me what the RLimitMem and RLimitCPU
    Probably got something to hide. If they told people the truth then people might be upset.
    But in the end it is your choice. There are 100s of other hosting companies out there. Dump them and move to a serious hosting company.

    Leave a comment:


  • binia7
    replied
    hi
    My hosting company is ipage. They will not tell me what the RLimitMem and RLimitCPU

    Leave a comment:


  • noface0711
    replied
    uninstalled/reinstalled and now it works again

    Leave a comment:


  • David
    replied
    I am going to start making a list of known bad hosting companies. These are the ones who in my opinion that so severely restrict your usage of PHP and CGI that it makes their service close to useless. (You could even say fraudulent, as they don't announce all these limits in advance of taking your money).

    Here is the list of hosts that are known to have this problem (they should be avoided in my opinion).

    Yahoo hosting
    Internet America (If you ask nicely to the right person, they may fix it for your server)
    EarthLink (at mid 2009, they also use very slow hardware, so really avoid these guys.)
    GoDaddy
    1&1 hosting
    Infinology
    Namesco (names.co.uk)
    ipage.com (limit was low, but they increase it upon request)
    Hostgator (limit was low, but they increase it upon request, as of May 2012)

    Update on Earthlink: Based on comments from a customer in Nov 2010 they are still running on older Sparc hardware and have low limits of allowable resource use. So they are still to be avoided IMHO.

    Update on 1&1: Based on comments from a customer in Feb 2012 they still a low 30MB RAM limit. So they are still to be avoided.

    Leave a comment:


  • David
    replied
    This thread was started 4 years ago. Even 32MB isn't much by today's standards (in 2009 with increasing volumes of data).

    PHP as a language isn't very efficient in using RAM, and so 64MB or 128MB is more reasonable for PHP when typical servers have 2GB or 4GB available.

    Leave a comment:


  • austenozzy
    replied
    Just a quick note to say thanks for this thread, it solved the problem for me!

    I called rackspace (we're lucky enough to have a dedicated server) and they altered the memory available to PHP from 8MB to 32B and it solved it straight away.

    Cheers,

    Austen.

    Leave a comment:


  • Ray
    replied
    The PHP test can be used to show that the problem is evident, but it is not conclusive to prove that there is no limit put in place.

    The reason is that it depends on how PHP is configured on the server. If the PHP scripting engine is setup as a CGI application which is forked by Apache, then the RLimit* operatives will apply and the PHP script can prove this. If they run within httpd however, the limits would not apply to the PHP engine.

    Leave a comment:


  • isd
    replied
    ok, thank you very much David, that helps to understand much better, btw. in my case the memory limit can be excluded as reason of those occurrences?

    thank you very much for help in advance
    ewa

    Leave a comment:


  • David
    replied
    If you see the "End test loop" message, Then no RAM or execution time limit was hit. Meaning that the server allowed the test script enough RAM to hold 2 million integers (which is about 8MB of RAM).

    You could try changing the test script to try a larger value. e.g.
    Code:
     
    for ($i = 0; $i < 10000000; $i++)
    This corresponds to about a >40MB RAM requirement.

    You can't make any direct comparision to the size of the zoom_wordmap.zdat file as not all of the zoom_wordmap.zdat is held in RAM at any one time.

    Leave a comment:


  • isd
    replied
    hello,
    i have one question regarding the results, please. so if my last line ends like:
    "integersallocated memory for 1995000 integersEnd test loop"
    it means on this server configuration my zoom_wordmap.zdat which weights 5839292 is limited to nearly 30% ?

    thank you very much for help in advance
    ewa

    Leave a comment:


  • Ray
    replied
    The code got line wrapped by the forum software, so some of the code appeared on a second line when it should have been on the same line. This may have been the cause of the error you are seeing.

    I've just edited the post and fixed up the wrapping. Copy and paste it again, exactly as it is. It should work now.

    Leave a comment:


  • carloant1953
    replied
    error message

    I have tested script test.php , but obtain this error message:

    Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /var/www/web236/html/test.php on line 7

    Parse error: parse error, unexpected T_PRINT in /var/www/web236/html/test.php on line 8

    thank you

    Leave a comment:


  • Ray
    replied
    I believe it is possible to modify RLimitMEM and RLimitCPU via .htaccess if the Apache server is configured to allow this. However, this is a highly unlikely setting unless you are on a dedicated server. This would otherwise mean that any account on your shared server may be requesting to use 100&#37; CPU or all available RAM, and the server is unlikely to handle this. If they maintain that you can control this, they should be able to tell you how to do so. The syntax should otherwise be the same as the setting in the php configuration file.

    Alternatively, they might be thinking of the memory limitation for PHP which is more commonly available for user control in .htaccess as described in this FAQ. This limit is applied prior to the Apache limit, which means that even if you have this limit allowing for 32MB of memory, if there is an Apache RLimitMEM set to 4MB, you will still be restricted to 4MB. It would be worth checking however, if it is the PHP limit that you are running into or the Apache one. The PHP limit should normally report an error message (eg. ""Fatal error: Allowed memory size of 8388608 bytes exhausted..." or similar) either on the page itself or in the server logs.

    Leave a comment:


  • glenna1984
    replied
    I ran the php test file and it stopped at 230000.

    My hosting company is 1and1. They will not tell me what the RLimitMem and RLimitCPU is -- so far.

    However, they maintain I can control this with .htacces.

    Do you agree, and if so, what are the commands?

    Leave a comment:


  • David
    replied
    Yes, you can upload the search files to any server that meets the requirements. The search results will still point back to the original documents on the original server.

    -----
    David

    Leave a comment:

Working...
X