• Our team is looking to connect with folks who use email services provided by Plesk, or a premium service. If you'd like to be part of the discovery process and share your experiences, we invite you to complete this short screening survey. If your responses match the persona we are looking for, you'll receive a link to schedule a call at your convenience. We look forward to hearing from you!
  • We are looking for U.S.-based freelancer or agency working with SEO or WordPress for a quick 30-min interviews to gather feedback on XOVI, a successful German SEO tool we’re looking to launch in the U.S.
    If you qualify and participate, you’ll receive a $30 Amazon gift card as a thank-you. Please apply here. Thanks for helping shape a better SEO product for agencies!
  • The BIND DNS server has already been deprecated and removed from Plesk for Windows.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS. We strongly recommend transitioning to Microsoft DNS within the next 6 weeks, before the Plesk 18.0.70 release.
  • The Horde component is removed from Plesk Installer. We recommend switching to another webmail software supported in Plesk.

Plesk 12 - Multiple PHP Versions - CLI?

futureweb

Regular Pleskian
Hey there,

for Apache it's no problem to switch the PHP Versions within Plesk - but how can I switch the PHP Versions within the Shell for Customers with Shell Access?

Thank you
Andreas Schnederle-Wagner
 
As for the PATH - this won't work as the Users on this Plesk Server only got CHROOTED ENVs ...
So I guess the only way is to add the correct Version manually to the CHROOT ... :-/

(not looked into the SCL yet)

Andreas
 
Hi futureweb,

you might be looking for a complete tutorial, so I would suggest you try this one: How to enable multiple PHP Versions in Parallels Plesk 11.5 and Plesk Automation 11.5 on Linux ( KB - article 118 378 ). :) ... and "yes" .. this is for Plesk 12 as well, and it has even been updated today.
Hi futureweb,

Hi,
I have PLESK 12/CentOS 6/php-5.3 and also use php-5.2.17 for soma domains.
Following your guide, I tried to install also php-5.1.6, however got following errors at step "Configure".Is the guide valid for any PHP version?
If not, could you send me the correct installation procedure for php-5.1.6?

[root@mysrv src]# cd /usr/local/src/php516
[root@mysrv php516]# ./configure '--with-libdir=lib64' '--cache-file=../config.cache' '--prefix=/usr/local/php516-cgi' '--with-config-file-path=/usr/local/php516-cgi/etc' '--disable-debug' '--with-pic' '--disable-rpath' '--with-bz2' '--with-curl' '--with-freetype-dir=/usr/local/php516-cgi' '--with-png-dir=/usr/local/php516-cgi' '--enable-gd-native-ttf' '--without-gdbm' '--with-gettext' '--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr/local/php516-cgi' '--with-openssl' '--with-pspell' '--with-pcre-regex' '--with-zlib' '--enable-exif' '--enable-ftp' '--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--enable-sysvmsg' '--enable-wddx' '--with-kerberos' '--with-unixODBC=/usr' '--enable-shmop' '--enable-calendar' '--without-sqlite3' '--with-libxml-dir=/usr/local/php516-cgi' '--enable-pcntl' '--with-imap' '--with-imap-ssl' '--enable-mbstring' '--enable-mbregex' '--with-gd' '--enable-bcmath' '--with-xmlrpc' '--with-ldap' '--with-ldap-sasl' '--with-mysql=/usr' '--with-mysqli' '--with-snmp' '--enable-soap' '--with-xsl' '--enable-xmlreader' '--enable-xmlwriter' '--enable-pdo' '--with-pdo-mysql' '--with-pdo-pgsql' '--with-pear=/usr/local/php516-cgi/pear' '--enable-intl' '--without-pdo-sqlite' '--with-config-file-scan-dir=/usr/local/php516-cgi/php.d' '--enable-cgi'

creating cache ../config.cache
checking for Cygwin environment... no
checking for mingw32 environment... no
checking for egrep... grep -E
checking for a sed that does not truncate output... /bin/sed
checking host system type... x86_64-unknown-linux-gnu
checking target system type... x86_64-unknown-linux-gnu
checking for gcc... gcc
checking whether the C compiler (gcc ) works... yes
checking whether the C compiler (gcc ) is a cross-compiler... no
checking whether we are using GNU C... yes
checking whether gcc accepts -g... yes
checking whether gcc and cc understand -c and -o together... yes
checking how to run the C preprocessor... gcc -E
checking for AIX... no
checking whether ln -s works... yes
checking if compiler supports -R... no
checking if compiler supports -Wl,-rpath,... yes
checking for re2c... no
configure: warning: You will need re2c 0.9.11 or later if you want to regenerate PHP parsers.
checking for gawk... gawk
checking for bison... no
checking for byacc... no
checking for bison version... invalid
configure: warning: bison versions supported for regeneration of the Zend/PHP parsers: 1.28 1.35 1.75 1.875 2.0 2.1 2.2 2.3 (found: none).
checking for flex... lex
checking for yywrap in -ll... no
checking lex output file root... ./configure: line 3246: lex: command not found
configure: error: cannot find output from lex; giving up
[root@mysrv php516]#
 
checking for flex... lex
checking for yywrap in -ll... no
checking lex output file root... ./configure: line 3246: lex: command not found
configure: error: cannot find output from lex; giving up

Just install missing flex:

# yum install flex
 
Back
Top