Announcement

Collapse
No announcement yet.

fcgid53.sh not support selector with php4.4 and php5.1

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

  • fcgid53.sh not support selector with php4.4 and php5.1

    fcgid53.sh not support selector with php4.4 and php5.1

    Cloudlinux 6.5 (Centos)
    DirectAdmin v1.44.3 + custombuild 2.0.0-RC6
    PHP from cloudlinux relo atl-php

    problem is

    Code:
    PHP_FCGI_MAX_REQUESTS=0
    
    export PHP_FCGI_MAX_REQUESTS
    when this parameter present in /usr/local/safe-bin/fcgid53.sh (why fcgid53.sh??? script only switcher and compatible with any php version) and in DA php selector switched to version 4.4 or 5.1 in error log appears

    Code:
    PHP_FCGI_MAX_REQUESTS is not valid
    for test i comment

    Code:
    #PHP_FCGI_MAX_REQUESTS=0
    
    #export PHP_FCGI_MAX_REQUESTS
    and update skeleton for cagefs. Now work fine, but PHP_FCGI_MAX_REQUESTS=500 (default value)

    have you any solution?

  • #2
    After spoke with cloudlinux support and i was receive new cloudlinux version of file fcgid53.sh

    Code:
    #---------------
    
    #!/bin/sh
    
    PHP_VER=53
    
    OPTIONS=
    
    if [ "$1" != "" ]; then
    
    if [ -s "$1" ]; then
    
    OPTIONS=" -c ${1} ${OPTIONS}"
    
    fi
    
    fi
    
    if php -v|grep -q 5.; then
    
    PHP_FCGI_MAX_REQUESTS=0
    
    export PHP_FCGI_MAX_REQUESTS
    
    PHP_FCGI_CHILDREN=0
    
    export PHP_FCGI_CHILDREN
    
    exec /usr/local/php53/bin/php-cgi53 ${OPTIONS}
    
    else exec /usr/local/php53/bin/php-cgi53 ${OPTIONS};
    
    fi
    
    #---------------
    here is my version

    Code:
    [root@da1 ~]# cat /usr/local/safe-bin/fcgid53.sh
    
    #!/bin/sh
    
    PHP_VER=53
    
    OPTIONS=
    
    if [ "$1" != "" ]; then
    
    if [ -s "$1" ]; then
    
    OPTIONS=" -c ${1} ${OPTIONS}"
    
    fi
    
    fi
    
    if [ "$2" != "" ]; then
    
    OPTIONS="${OPTIONS} ${2} ${3} ${4} ${5} ${6} ${7} ${8} ${9} ${10} ${11} ${12}"
    
    fi
    
    CL_PHP_VER=`php -v | grep ^PHP | awk {print $2} | sed -e s/.[0-9]+$//`
    
    if [ "${CL_PHP_VER}" != "4.4" ] && [ "${CL_PHP_VER}" != "5.1" ]; then
    
    PHP_FCGI_MAX_REQUESTS=0
    
    export PHP_FCGI_MAX_REQUESTS
    
    PHP_FCGI_CHILDREN=0
    
    export PHP_FCGI_CHILDREN
    
    fi
    
    exec /usr/local/php53/bin/php-cgi53 ${OPTIONS}

    Comment

    Working...
    X