#63 hugh php process (200-600MB) w/mmcache

open
nobody
None
5
2003-11-04
2003-11-04
kyle wong
No

recently I found that my server always have some very
strange php process which take several hundreds MB of
memory or take > 90% CPU load (but not in big size) for
several minutes. These process start appear from 2.4.4
(I'm really sure). I can't tell if it's mmcache's problem
but I don't have such problem before. I have to kill -9
PID to end it but many times, another strange process
appear within a minute.

19135 nobody 16 0 696M 597M 2132 R 20.9 59.4 0:16 0
httpd

Discussion

  • Dmitry Stogov
    Dmitry Stogov
    2003-11-04

    Logged In: YES
    user_id=124551

    What is your "mmcache.shm_size" setting. 2.4.4 did
    premapping of all shared memory on HTTPD load.
    Try to use 2.4.5, it does shared memory mapping only on
    memory access.
    The process which take 90% CPU can handle a http request.

     
  • kyle wong
    kyle wong
    2003-11-04

    Logged In: YES
    user_id=185056

    my "mmcache.shm_size" is "32", and I'm using 2.4.5 already
    (but mmcache() show 2.4.4?!). I downloaded again the
    source, re-compile ... but mmcache() still shows 2.4.4

    also some typo from my previous message. "These process
    start appear from 2.4.4 (I'm really sure)." should be "These
    process start appear from 2.4.4 (I'm not really sure)"

     
  • kyle wong
    kyle wong
    2003-11-04

    Logged In: YES
    user_id=185056

    my "mmcache.shm_size" is "32", and I'm using 2.4.5 already
    (but mmcache() show 2.4.4?!). I downloaded again the
    source, re-compile ... but mmcache() still shows 2.4.4

    also some typo from my previous message. "These process
    start appear from 2.4.4 (I'm really sure)." should be "These
    process start appear from 2.4.4 (I'm not really sure)"

     
  • kyle wong
    kyle wong
    2003-11-04

    Logged In: YES
    user_id=185056

    my "mmcache.shm_size" is "32", and I'm using 2.4.5 already
    (but mmcache() show 2.4.4?!). I downloaded again the
    source, re-compile ... but mmcache() still shows 2.4.4

    also some typo from my previous message. "These process
    start appear from 2.4.4 (I'm really sure)." should be "These
    process start appear from 2.4.4 (I'm not really sure)"

     
  • kyle wong
    kyle wong
    2003-11-04

    Logged In: YES
    user_id=185056

    my "mmcache.shm_size" is "32", and I'm using 2.4.5 already
    (but mmcache() show 2.4.4?!). I downloaded again the
    source, re-compile ... but mmcache() still shows 2.4.4

    also some typo from my previous message. "These process
    start appear from 2.4.4 (I'm really sure)." should be "These
    process start appear from 2.4.4 (I'm not really sure)"

     
  • Dmitry Stogov
    Dmitry Stogov
    2003-11-04

    Logged In: YES
    user_id=124551

    You did not install mmcache properly.
    Did you restart httpd?
    mmcache() and phpinfo() mast show 2.4.5.

     
  • kyle wong
    kyle wong
    2003-11-04

    Logged In: YES
    user_id=185056

    Yes you are correct .... Now I've installed 2.4.5 correctly.

    still, the same mmcache_get/mmcache_put problem with
    unserialized object with 2.4.5

     
  • Dmitry Stogov
    Dmitry Stogov
    2003-11-04

    Logged In: YES
    user_id=124551

    Hi, Kyle. I didn't see into name. :)
    May be the problem of mmcache_get/mmcache_put comes
    from memory overflow? mmcache_get/put don't understend
    references, so recursive structures will break them.
    Can you provide full working testcase with all data? (Files
    those you send to me was not anough to repeat the problem)

     
  • kyle wong
    kyle wong
    2003-11-05

    Logged In: YES
    user_id=185056

    Dear dstogov,

    here attach a full working testcase, I can reproduce the same
    problem when the testcase I send you.

     
  • kyle wong
    kyle wong
    2003-11-05

    Logged In: YES
    user_id=185056

    Dear dstogov,

    here attach a full working testcase, I can reproduce the same
    problem when the testcase I send you.

     
  • Mitch Harder
    Mitch Harder
    2003-11-07

    Logged In: YES
    user_id=155894

    I have encountered a similar problem, although my test
    server is much smaller than kylewong's.

    However, in my case, a can only replicate the problem when
    my apache server is being accessed at the same time it is
    being restarted. I don't have a certain page that generates
    this behaviour, but if I stop and start apache, and have
    another web browser accesing apache, I begin to get a few
    rogue httpd processes that absord all my available memory
    and cpu time (except for the cpu time being used by the swap
    daemon).

    I have found the same behaviour under 2.4.5 and 2.4.6.

    If I catch it in time, and can kill -9 the affected httpd
    processes, otherwise, my smaller test server gets unstable,
    and starts shutting stuff down.