apache2 + php: Resource deadlock avoided

  • I have a problem with my server.

    The webserver is responding with an internal server error after some time (could be a few minutes or a few hours).

    The only thing I find in log file is:

    1. [Thu Jan 15 15:51:48.167610 2015] [fcgid:emerg] [pid 11798:tid 139740158281472] (35)Resource deadlock avoided: [client] mod_fcgid: can't get pipe mutex
    2. [Thu Jan 15 15:52:53.712051 2015] [fcgid:emerg] [pid 14955:tid 139740275779328] (35)Resource deadlock avoided: [client] mod_fcgid: can't get pipe mutex
    3. [Thu Jan 15 16:37:27.794815 2015] [fcgid:emerg] [pid 20520:tid 139740158281472] (35)Resource deadlock avoided: [client] mod_fcgid: can't lock process table in pid 20520

    Ubuntu: 14.04
    Apache: 2.4.7
    PHP: 5.5.9 (fcgi)

    Has anyone an idea what causes this problem?

    Thx and regards


  • badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206

  • Unfortunately, this has not helped.

    I have the apache updated to 2.4.10 and php to 5.5.20.

    I have tested it with kernel 3.16.6 / 3.16.7 and 3.18.3.

    But at least once a day I got the error in the logs and the server returns from then on only 500 error (in this vhost).

    Does anyone have any other ideas?

  • @boe

    • Try to review your fcgid parameters
    • When the error 500 occurs, look at the process table to know which fcgid process ( can be caused by a zombie process ) is responsible and the related vuxxx user
    • Try to know which is the PHP application that is involved (using the vuxxx user ) and once done, check its PHP configuration (memory, max execution time)
    • Try to lower the value of the PHP_FCGI_MAX_REQUESTS parameter in the fcgid wrapper. Don't forget to adjust the value of the FcgidMaxRequestsPerProcess parameter from the fcgid_imscp.conf file too
    • Try to raise the value of the FcgidMaxProcessesPerClass parameter

    Don't forget to restart Apache after editing the parameters.

    BTW: You should consider to upgrade your i-MSCP version.


  • Re;


  • The tipps helped only a short time then the error occured again...

    So after a long time of testing the only solution I got was to change php from cgi to fpm. Afterwards the errors disappeared. And the hole system is now running stable.