ispconfig multiple php not working - everything looks ok

Discussion in 'Installation/Configuration' started by musa, Feb 10, 2014.

  1. musa

    musa New Member

    Hey all


    i have update a ISPCOnfig Server to the last release yesterday.
    To be able to use multiple PHP Versions.

    The update worked without problems - and i have compiled php 5.4
    (its a ubuntu lts).


    As howto i have used this one:

    http://www.howtoforge.de/anleitung/...-mit-ispconfig-3-benutzen-ubuntu-12-04-lts/3/


    afterwards i have added the php-fpm addtional php version and changed one webside to this php version.

    i see ispconfig had created the pool config file.
    the php fpm process is also running:

    Code:
    root      1081     1  0 10:44 ?        00:00:00 php-fpm: master process (/usr/local/php-5.4.25/etc/php-fpm.conf)
    web214    1084  1081  0 10:44 ?        00:00:00 php-fpm: pool web214
    web214    1085  1081  0 10:44 ?        00:00:00 php-fpm: pool web214
    www-data  1088  1081  0 10:44 ?        00:00:00 php-fpm: pool www
    www-data  1091  1081  0 10:44 ?        00:00:00 php-fpm: pool www
    
    the conf file created looks also ok:

    Code:
     pwd
    /usr/local/php-5.4.25/etc/pool.d
    [email protected]:/usr/local/php-5.4.25/etc/pool.d$ cat web214.conf
    [web214]
    
    listen = 127.0.0.1:9223
    listen.allowed_clients = 127.0.0.1
    
    user = web214
    group = client120
    
    pm = dynamic
    pm.max_children = 10
    pm.start_servers = 2
    pm.min_spare_servers = 1
    pm.max_spare_servers = 5
    pm.max_requests = 0
    
    chdir = /
    
    php_admin_value[open_basedir] = /var/www/clients/client120/web214/web:/var/www/clients/client120/web214/tmp:/var/www/xxx.yyy.zz/web:/srv/www/xxx.yyy.zz/web:/usr/share/php5:/tmp:/usr/share/phpmyadmin:/etc/phpmyadmin:/var/lib/phpmyadmin
    php_admin_value[session.save_path] = /var/www/clients/client120/web214/tmp
    php_admin_value[upload_tmp_dir] = /var/www/clients/client120/web214/tmp
    
    

    i see also in the apache conf file the config is changed to:

    Code:
             <IfModule mod_fastcgi.c>
                                    <Directory /var/www/clients/client120/web214/cgi-bin>
                                                    Order allow,deny
                                                    Allow from all
                                </Directory>
                    AddHandler php5-fcgi .php
                    Action php5-fcgi /php5-fcgi
                                    Alias /php5-fcgi /var/www/clients/client120/web214/cgi-bin/php5-fcgi-*-80-xxx.yyy.zz
                    FastCgiExternalServer /var/www/clients/client120/web214/cgi-bin/php5-fcgi-*-80-xxx.yyyy.zz -idle-timeout 300 -host 127.0.0.1:9223 -pass-header Authorization
                    </IfModule>
    



    but it still shows php 5.3 (the old/default php version).
    there must be something wrong or missing?!

    some help/input would be great.
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    I just checked the german guide at howtoforge.de, It seems as if the last wordpress update removed all bachslashes from the configure commands, I tried to add them back but wordpress removes them auomatically. IÄve now altered the guide so that all configure options are shown in one line, its nt that easy to read but it should work.

    Please redo the php configure and compilation, due to the missing backslases, the options were missing in the configure command.
     
  3. musa

    musa New Member

    Hello Till

    thank you for your answer.

    here is the configure i used (from config.status)
    i had reformated it by myself and also removed postgre
    so it has to be something else

    Code:
    '--prefix=/usr/local/php-5.4.25' '--exec-prefix=/usr/local/php-5.4.25' '--with-zlib-dir' '--with-freetype-dir' '--enable-mbstring' '--with-libxml-dir=/usr' '--enable-soap' '--enable-calendar' '--with-curl' '--with-mcrypt' '--with-gd' '--disable-rpath' '--enable-inline-optimization' '--with-zlib' '--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--enable-pcntl' '--enable-mbregex' '--with-mhash' '--enable-zip' '--with-pcre-regex' '--with-mysql' '--with-pdo-mysql' '--with-mysqli' '--with-jpeg-dir=/usr' '--with-png-dir=/usr' '--enable-gd-native-ttf' '--with-openssl' '--with-fpm-user=www-data' '--with-fpm-group=www-data' '--enable-ftp' '--with-imap' '--with-imap-ssl' '--with-kerberos' '--with-gettext' '--enable-fpm'
     
  4. musa

    musa New Member

    or is anyone else out which has multiple php versions and could post the apache part of the config
    to compare them?
     
  5. musa

    musa New Member

    is the problem maybe that ispconfig create the config like:
    <IfModule mod_fastcgi.c>

    but installed is only fcgid ?

    i think its pretty safe to install mod_fastcgi without break everything? :)
     
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    The apache config that is created by ispconfig is ok, it works on ten thousands of servers like this, so the issue must be a problem with your compiled php or base server install.

    mod_fastcgi is required for php-fpm, thats described in the perfect setup guides that had been released since php fpm support has been added in ispconfig.
     
  7. musa

    musa New Member

    yup sorry for that - i didnt install the server and didnt realise at the beginning.

    i'll try that tonight and post an update here.

    thank you for the input.
     
  8. musa

    musa New Member

    just a short feedback: it was indeed the missing fastcgi module.

    so the server "failed" back on the default php version.
    after installing fastcgi - it works following the howto i linked above.

    one small question: is there a way over a apache directive or something else
    to be able to give another place for the php.ini just for one customer so that he is able to make his own php.ini?
     
  9. till

    till Super Moderator Staff Member ISPConfig Developer

    See custom php.ini field on the options tab of the website settings in ispconfig.
     
  10. musa

    musa New Member

    sorry Till... but i dont get it


    you mean this one?
    [​IMG]

    thats for the php options, but i cant tell there look here and here for a php.ini file or is that possible? couldnt find it.. in the howtos not nor in the forum..

    the goal is that the customer can have his own php.ini file - or atleast put this options by himself in there so he can do it at his own. sorry if it was unclear.
     
  11. till

    till Super Moderator Staff Member ISPConfig Developer

    You can set custom php settings for your customer there.if the customer would be able to do i himself or if he weould get full access to the php.ini file, then he can take over your whole server as he weill be able to activate functions in php.ini that he shall nte be able to use and he will be able to remove path restrictions. I guess you dont want that as a hosting provider, at least if you have more then one customer on a server.
     

Share This Page