Multiple PHPs

#1
Dear,

I setup multiple php in openlitespeed success link help http://open.litespeedtech.com/mediawiki/index.php/Help:Multiple_PHPs, but i check phpinfo for once php, only php52, php53 and php55 have Configure Command. php54,php56 and php70 not Configure Command and php_mysql not load, so php_mysql not run
Your PHP installation appears to be missing the MySQL extension which is required by WordPress.

PHP Version 5.4.45

System Linux vps9120.dotvndns.com 2.6.32-642.15.1.el6.x86_64 #1 SMP Fri Feb 24 14:31:22 UTC 2017 x86_64
Build Date Dec 10 2015 09:15:21
Server API LiteSpeed V6.9

PHP Version 5.3.29

System Linux vps9120.dotvndns.com 2.6.32-642.15.1.el6.x86_64 #1 SMP Fri Feb 24 14:31:22 UTC 2017 x86_64
Build Date Mar 1 2017 10:20:04
Configure Command './configure' '--build=x86_64-redhat-linux-gnu' '--host=x86_64-redhat-linux-gnu' '--target=x86_64-redhat-linux-gnu' '--program-prefix=' '--exec-prefix=/usr/local/lsws/lsphp53' '--bindir=/usr/local/lsws/lsphp53/bin' '--sbindir=/usr/local/lsws/lsphp53/sbin' '--sysconfdir=/usr/local/lsws/lsphp53/etc' '--datadir=/usr/local/lsws/lsphp53/share' '--includedir=/usr/local/lsws/lsphp53/include' '--libexecdir=/usr/local/lsws/lsphp53/libexec' '--localstatedir=/usr/local/lsws/lsphp53/var' '--sharedstatedir=/var/lib' '--mandir=/usr/local/lsws/lsphp53/share/man' '--infodir=/usr/share/info' '--cache-file=../config.cache' '--with-libdir=lib64' '--with-config-file-path=/usr/local/lsws/lsphp53/etc' '--with-config-file-scan-dir=/usr/local/lsws/lsphp53/etc/php.d' '--disable-debug' '--with-pic' '--disable-rpath' '--without-pear' '--with-bz2' '--with-exec-dir=/usr/local/lsws/lsphp53/bin' '--with-freetype-dir=/usr' '--with-png-dir=/usr' '--with-xpm-dir=/usr' '--enable-gd-native-ttf' '--with-t1lib=/usr' '--without-gdbm' '--with-gettext' '--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr' '--with-openssl' '--with-zlib' '--with-layout=GNU' '--enable-exif' '--enable-ftp' '--enable-magic-quotes' '--enable-sockets' '--with-kerberos' '--enable-ucd-snmp-hack' '--enable-shmop' '--enable-calendar' '--with-libxml-dir=/usr' '--enable-xml' '--with-system-tzdata' '--with-mhash' '--prefix=/usr/local/lsws/lsphp53' '--with-litespeed' '--libdir=/usr/local/lsws/lsphp53/lib64' '--enable-pcntl' '--with-imap=shared' '--with-imap-ssl' '--enable-mbstring=shared' '--enable-mbregex' '--with-gd=shared' '--enable-bcmath=shared' '--enable-dba=shared' '--with-db4=/usr' '--with-xmlrpc=shared' '--with-ldap=shared' '--with-ldap-sasl' '--enable-mysqlnd=shared' '--with-mysql=shared,mysqlnd' '--with-mysqli=shared,mysqlnd' '--with-mysql-sock=/var/lib/mysql/mysql.sock' '--enable-dom=shared' '--with-pgsql=shared' '--enable-wddx=shared' '--with-snmp=shared,/usr' '--enable-soap=shared' '--with-xsl=shared,/usr' '--enable-xmlreader=shared' '--enable-xmlwriter=shared' '--with-curl=shared,/usr' '--enable-fastcgi' '--enable-pdo=shared' '--with-pdo-odbc=shared,unixODBC,/usr' '--with-pdo-mysql=shared,mysqlnd' '--with-pdo-pgsql=shared,/usr' '--with-pdo-sqlite=shared,/usr' '--with-sqlite3=shared' '--with-sqlite=shared' '--enable-json=shared' '--enable-zip=shared' '--without-readline' '--with-libedit' '--with-pspell=shared' '--enable-phar=shared' '--with-mcrypt=shared,/usr' '--with-tidy=shared,/usr' '--enable-sysvmsg=shared' '--enable-sysvshm=shared' '--enable-sysvsem=shared' '--enable-posix=shared' '--with-unixODBC=shared,/usr' '--enable-fileinfo=shared' '--enable-intl=shared' '--with-icu-dir=/usr' '--with-enchant=shared,/usr' '--with-recode=shared,/usr'
Server API LiteSpeed V6.10

PHP Version 5.6.31
System Linux vps9120.dotvndns.com 2.6.32-642.15.1.el6.x86_64 #1 SMP Fri Feb 24 14:31:22 UTC 2017 x86_64
Build Date Jul 6 2017 20:37:57
Server API LiteSpeed V6.11

PHP Version 5.5.38

System Linux vps9120.dotvndns.com 2.6.32-642.15.1.el6.x86_64 #1 SMP Fri Feb 24 14:31:22 UTC 2017 x86_64
Build Date Jul 29 2016 17:43:48
Server API LiteSpeed V6.9

PHP Version 5.6.30 (Default)
System Linux vps9120.dotvndns.com 2.6.32-642.15.1.el6.x86_64 #1 SMP Fri Feb 24 14:31:22 UTC 2017 x86_64
Build Date Jul 11 2017 21:21:01
Configure Command './configure' '--prefix=/usr/local/lsws/lsphp5' '--with-config-file-scan-dir=/usr/local/lib/php.conf.d' '--with-curl=/usr/local/lib' '--with-gd' '--enable-gd-native-ttf' '--with-gettext' '--with-jpeg-dir=/usr/local/lib' '--with-freetype-dir=/usr/local/lib' '--with-libxml-dir=/usr/local/lib' '--with-kerberos' '--with-openssl' '--with-mcrypt' '--with-mhash' '--with-mysql=mysqlnd' '--with-mysql-sock=/var/lib/mysql/mysql.sock' '--with-mysqli=mysqlnd' '--with-pcre-regex=/usr/local' '--with-pdo-mysql=mysqlnd' '--with-pear' '--with-png-dir=/usr/local/lib' '--with-xsl' '--with-zlib' '--with-zlib-dir=/usr/local/lib' '--enable-zip' '--with-iconv=/usr/local' '--enable-bcmath' '--enable-calendar' '--enable-ftp' '--enable-sockets' '--enable-soap' '--enable-mbstring' '--with-icu-dir=/usr/local/icu' '--enable-intl' '--with-litespeed'
Server API LiteSpeed V6.10

PHP Version 7.0.21
System Linux vps9120.dotvndns.com 2.6.32-642.15.1.el6.x86_64 #1 SMP Fri Feb 24 14:31:22 UTC 2017 x86_64
Build Date Jul 6 2017 10:46:33
Server API LiteSpeed V6.11
 
Last edited:
#2
I ssh to server and run command below
/usr/local/lsws/lsphp56/bin/lsphp error

PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226/pdo_mysql.so' - /usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226/pdo_mysql.so: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226/pdo_odbc.so' - /usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226/pdo_odbc.so: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226/pdo_pgsql.so' - /usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226/pdo_pgsql.so: cannot open shared object file: No such file or directory in Unknown on line 0

when i copy files all in /usr/local/lsws/lsphp56/lib64/php/modules/* to /usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226 and restart litespeed, when check again php-mysql good.

But php70 check error

/usr/local/lsws/lsphp70/bin/lsphp error

PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226/curl.so' - /usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226/curl.so: undefined symbol: _zend_hash_index_update_or_next_insert in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226/dba.so' - /usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226/dba.so: undefined symbol: _zend_list_delete in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226/dom.so' - /usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226/dom.so: undefined symbol: zval_used_for_init in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226/enchant.so' - /usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226/enchant.so: undefined symbol: _zend_list_delete in Unknown on line 0
 
#3
Hi @xikebattu

I just want to clarify the issues that you ran into:

1. Per the wiki, you ran the yum groupinstall command and it resulted in the "Unable to load dynamic library" errors. You copied the modules to the new directory, and that resolved the issue.

2. However, once that was copied over, you still ran into issues with PHP 70.

Is that correct?

If so, could you provide the following information:
1. What OS are you using?
2. How did you install OLS?

Thanks,
Kevin
 
#4
Hi Kevin,
first, I setup OLS 1.4.26 on centos 6,8 success and build php 5.6 default have all module php_mysql,..
Link check phpinfo php 5.6 default http://example.net/info.php, everything good.

secondary, I setup multy PHP do guide http://open.litespeedtech.com/mediawiki/index.php/Help:Multiple_PHPs
I ran yum groupinstall lsphp-all and all php52, php53, php54, php55, php56, php70 success. Check php-mysql on php52, php53 good, But php55, php56, php70 not show module mysql on phpinfo.

I try ran /usr/local/lsws/lsphp56/bin/lsphp command it error, so i copy files all in /usr/local/lsws/lsphp56/lib64/php/modules/* to /usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20131226 and restart litespeed, when check again php-mysql on php56 good. But php70 and php 55 still not show module mysql.

Link check php70 not show mysql modul : http://example.com/info2.php

Please help me fix mysql module show all version php.


Thanks.

lsfoo edit: removed domains.
 
Last edited by a moderator:
#6
Hi @xikebattu

A couple questions:

1. It looks like you were running Apache on your .com site. Could you please switch that to OLS so we can check the info page on that?
As a side note: OLS cannot read Apache configurations. Only our Enterprise product can do that. If you were attempting to use Apache configurations with OLS, that could be the cause of the issue.

2. It's possible that your external app settings is slightly off based on your warnings. Could you please paste your ext app settings?

3. If you were using Apache configs and manually set it up and still have issues, could you please run the following command:
Code:
rpm -qa | grep lsphp
Thanks,
Kevin
 
#7
Hi @xikebattu

A couple questions:

1. It looks like you were running Apache on your .com site. Could you please switch that to OLS so we can check the info page on that?
As a side note: OLS cannot read Apache configurations. Only our Enterprise product can do that. If you were attempting to use Apache configurations with OLS, that could be the cause of the issue.

2. It's possible that your external app settings is slightly off based on your warnings. Could you please paste your ext app settings?

3. If you were using Apache configs and manually set it up and still have issues, could you please run the following command:
Code:
rpm -qa | grep lsphp
Thanks,
Kevin


Hi Kevin,

I running OLS, not config OLS in apache configuration. link web phpinfo check http://example.net/info.hp

I ssh in my server run following command :

[root@vps9120 ~]# rpm -qa | grep lsphp
lsphp55-5.5.38-2.el6.x86_64
lsphp56-mysql-5.6.31-1.el6.x86_64
lsphp56-xml-5.6.31-1.el6.x86_64
lsphp56-pspell-5.6.31-1.el6.x86_64
lsphp53-common-5.3.29-2.el6.x86_64
lsphp56-xmlrpc-5.6.31-1.el6.x86_64
lsphp56-bcmath-5.6.31-1.el6.x86_64
lsphp55-pdo-5.5.38-2.el6.x86_64
lsphp53-process-5.3.29-2.el6.x86_64
lsphp54-enchant-5.4.45-1.el6.x86_64
lsphp55-mysql-5.5.38-2.el6.x86_64
lsphp53-mysql-5.3.29-2.el6.x86_64
lsphp52-mysql-5.2.17-1.el6.x86_64
lsphp53-gd-5.3.29-2.el6.x86_64
lsphp55-tidy-5.5.38-2.el6.x86_64
lsphp52-tidy-5.2.17-1.el6.x86_64
lsphp54-pspell-5.4.45-1.el6.x86_64
lsphp55-pspell-5.5.38-2.el6.x86_64
lsphp55-mcrypt-5.5.38-2.el6.x86_64
lsphp52-dba-5.2.17-1.el6.x86_64
lsphp52-5.2.17-1.el6.x86_64
lsphp53-mbstring-5.3.29-2.el6.x86_64
lsphp53-soap-5.3.29-2.el6.x86_64
lsphp54-bcmath-5.4.45-1.el6.x86_64
lsphp55-mbstring-5.5.38-2.el6.x86_64
lsphp55-soap-5.5.38-2.el6.x86_64
lsphp70-mysqlnd-7.0.21-1.el6.x86_64
lsphp70-dba-7.0.21-1.el6.x86_64
lsphp70-mcrypt-7.0.21-1.el6.x86_64
lsphp70-bcmath-7.0.21-1.el6.x86_64
lsphp70-xmlrpc-7.0.21-1.el6.x86_64
lsphp70-enchant-7.0.21-1.el6.x86_64
lsphp56-common-5.6.31-1.el6.x86_64
lsphp56-odbc-5.6.31-1.el6.x86_64
lsphp56-opcache-5.6.31-1.el6.x86_64
lsphp56-ldap-5.6.31-1.el6.x86_64
lsphp54-common-5.4.45-1.el6.x86_64
lsphp56-gmp-5.6.31-1.el6.x86_64
lsphp56-intl-5.6.31-1.el6.x86_64
lsphp56-recode-5.6.31-1.el6.x86_64
lsphp54-pdo-5.4.45-1.el6.x86_64
lsphp53-5.3.29-2.el6.x86_64
lsphp54-xml-5.4.45-1.el6.x86_64
lsphp53-xml-5.3.29-2.el6.x86_64
lsphp70-pear-1.10.1-1.el6.noarch
lsphp53-pear-1.9.5-1.el6.noarch
lsphp54-snmp-5.4.45-1.el6.x86_64
lsphp53-ioncube-loader-5.0.20-1.el6.x86_64
lsphp55-odbc-5.5.38-2.el6.x86_64
lsphp54-odbc-5.4.45-1.el6.x86_64
lsphp52-odbc-5.2.17-1.el6.x86_64
lsphp53-intl-5.3.29-2.el6.x86_64
lsphp54-gd-5.4.45-1.el6.x86_64
lsphp54-tidy-5.4.45-1.el6.x86_64
lsphp55-imap-5.5.38-2.el6.x86_64
lsphp52-xml-5.2.17-1.el6.x86_64
lsphp53-pspell-5.3.29-2.el6.x86_64
lsphp54-mcrypt-5.4.45-1.el6.x86_64
lsphp54-recode-5.4.45-1.el6.x86_64
lsphp52-xmlrpc-5.2.17-1.el6.x86_64
lsphp52-mbstring-5.2.17-1.el6.x86_64
lsphp53-ldap-5.3.29-2.el6.x86_64
lsphp53-dba-5.3.29-2.el6.x86_64
lsphp54-mbstring-5.4.45-1.el6.x86_64
lsphp54-dba-5.4.45-1.el6.x86_64
lsphp55-dba-5.5.38-2.el6.x86_64
lsphp55-gmp-5.5.38-2.el6.x86_64
lsphp70-pgsql-7.0.21-1.el6.x86_64
lsphp70-xml-7.0.21-1.el6.x86_64
lsphp70-soap-7.0.21-1.el6.x86_64
lsphp70-opcache-7.0.21-1.el6.x86_64
lsphp70-intl-7.0.21-1.el6.x86_64
lsphp70-gmp-7.0.21-1.el6.x86_64
lsphp56-pdo-5.6.31-1.el6.x86_64
lsphp56-mcrypt-5.6.31-1.el6.x86_64
lsphp56-dba-5.6.31-1.el6.x86_64
lsphp56-imap-5.6.31-1.el6.x86_64
lsphp55-common-5.5.38-2.el6.x86_64
lsphp56-gd-5.6.31-1.el6.x86_64
lsphp56-mbstring-5.6.31-1.el6.x86_64
lsphp54-5.4.45-1.el6.x86_64
lsphp53-pdo-5.3.29-2.el6.x86_64
lsphp55-process-5.5.38-2.el6.x86_64
lsphp52-snmp-5.2.17-1.el6.x86_64
lsphp53-snmp-5.3.29-2.el6.x86_64
lsphp55-pgsql-5.5.38-2.el6.x86_64
lsphp54-pgsql-5.4.45-1.el6.x86_64
lsphp53-odbc-5.3.29-2.el6.x86_64
lsphp55-intl-5.5.38-2.el6.x86_64
lsphp52-gd-5.2.17-1.el6.x86_64
lsphp53-tidy-5.3.29-2.el6.x86_64
lsphp54-imap-5.4.45-1.el6.x86_64
lsphp52-mcrypt-5.2.17-1.el6.x86_64
lsphp53-mcrypt-5.3.29-2.el6.x86_64
lsphp55-recode-5.5.38-2.el6.x86_64
lsphp52-ldap-5.2.17-1.el6.x86_64
lsphp52-process-5.2.17-1.el6.x86_64
lsphp53-xmlrpc-5.3.29-2.el6.x86_64
lsphp53-bcmath-5.3.29-2.el6.x86_64
lsphp54-soap-5.4.45-1.el6.x86_64
lsphp54-xmlrpc-5.4.45-1.el6.x86_64
lsphp55-xmlrpc-5.5.38-2.el6.x86_64
lsphp55-ldap-5.5.38-2.el6.x86_64
lsphp70-pdo-7.0.21-1.el6.x86_64
lsphp70-imap-7.0.21-1.el6.x86_64
lsphp70-7.0.21-1.el6.x86_64
lsphp70-recode-7.0.21-1.el6.x86_64
lsphp70-json-7.0.21-1.el6.x86_64
lsphp70-gd-7.0.21-1.el6.x86_64
lsphp70-process-7.0.21-1.el6.x86_64
lsphp56-pgsql-5.6.31-1.el6.x86_64
lsphp56-soap-5.6.31-1.el6.x86_64
lsphp56-enchant-5.6.31-1.el6.x86_64
lsphp56-process-5.6.31-1.el6.x86_64
lsphp52-common-5.2.17-1.el6.x86_64
lsphp56-snmp-5.6.31-1.el6.x86_64
lsphp56-tidy-5.6.31-1.el6.x86_64
lsphp56-5.6.31-1.el6.x86_64
lsphp52-pdo-5.2.17-1.el6.x86_64
lsphp55-xml-5.5.38-2.el6.x86_64
lsphp54-process-5.4.45-1.el6.x86_64
lsphp53-enchant-5.3.29-2.el6.x86_64
lsphp55-enchant-5.5.38-2.el6.x86_64
lsphp55-snmp-5.5.38-2.el6.x86_64
lsphp54-mysql-5.4.45-1.el6.x86_64
lsphp53-pgsql-5.3.29-2.el6.x86_64
lsphp52-pgsql-5.2.17-1.el6.x86_64
lsphp54-intl-5.4.45-1.el6.x86_64
lsphp55-gd-5.5.38-2.el6.x86_64
lsphp53-imap-5.3.29-2.el6.x86_64
lsphp52-imap-5.2.17-1.el6.x86_64
lsphp52-pspell-5.2.17-1.el6.x86_64
lsphp52-recode-5.2.17-1.el6.x86_64
lsphp53-recode-5.3.29-2.el6.x86_64
lsphp52-bcmath-5.2.17-1.el6.x86_64
lsphp52-soap-5.2.17-1.el6.x86_64
lsphp53-pecl-apc-5.3.29-3.el6.x86_64
lsphp54-ldap-5.4.45-1.el6.x86_64
lsphp54-pecl-apc-5.4.45-1.el6.x86_64
lsphp55-bcmath-5.5.38-2.el6.x86_64
lsphp55-opcache-5.5.38-2.el6.x86_64
lsphp70-common-7.0.21-1.el6.x86_64
lsphp70-odbc-7.0.21-1.el6.x86_64
lsphp70-ldap-7.0.21-1.el6.x86_64
lsphp70-tidy-7.0.21-1.el6.x86_64
lsphp70-mbstring-7.0.21-1.el6.x86_64
lsphp70-snmp-7.0.21-1.el6.x86_64
lsphp70-pspell-7.0.21-1.el6.x86_64
[root@vps9120 ~]#
 
Last edited by a moderator:

lskagan

Administrator
#8
You will want to make sure you created a new External App for each version of PHP installed. Then in vhosts point to the correct version under script handlers. You do not want to copy/paste files as this will break things more. It seems as though the links you sent are all Apache and are all using the default PHP Ext App + handler which would cause the issue.
 
Top