[Resolved] LSAPI + Suxec deamon mode + multiple PHP versions + cPanel ?

Status
Not open for further replies.

wanah

Well-Known Member
#1
Hello,

I'm about to try to add PHP 5.4 and PHP 5.5 support to our server running cPanel + Litespeed + CloudLinux

Can I just follow this :

http://www.litespeedtech.com/support/wiki/doku.php?id=litespeed_wiki:multiple_phps_in_control_panel_lsws

Wil it work ?

Thanks
 
Last edited by a moderator:

NiteWave

Administrator
#4
run lsphp5xx on command line:
#/path/to/lsphp5xx -i|grep "Configuration File (php.ini) Path"

an example:
/usr/local/lsws/fcgi-bin>./lsphp5 -i|grep -A 1 "Configuration File (php.ini) Path"
Configuration File (php.ini) Path => /usr/local/lsws/lsphp5/lib
Loaded Configuration File => /usr/local/lsws/lsphp5/lib/php.ini
in above example, put php.ini under /usr/local/lsws/lsphp5/lib
 

wanah

Well-Known Member
#5
Thanks,

I think i've got php 5.4 installed and configured, I now guess I've got to configure cagefs so users can run php with suexec

I'll ask CloudLinux about this.
 

wanah

Well-Known Member
#6
OK, I've sort of got it working, however it's using an old lsapi version.

My cPanel's default PHP version is using LiteSpeed V6.3

However the PHP 5.4 I built following the instructions you gave says :

LiteSpeed V5.5

What did I do wrong ? How do I specify the LSAPI version when I build PHP ?

Thanks
 

NiteWave

Administrator
#7
maybe you select the php from php selector from cloudlinux ?

if casefs enabled ... Sorry, I'm not clear about it at the moment, just give you a quick hint. :)
 

wanah

Well-Known Member
#8
No, I manually compiled PHP to /usr/local/lsws/php54

/usr/local/lsws is mounted by default in CloudLinux so this folder is already fully accessible.

My issue seems to be that the --with-litespeed configured PHP with LSAPI 5.5

I'm running PHP in deamon mode which is not compatible with PHP selector yet, that's why I compiled it manually.

Do I have to add anything else to the PHP configure command to get PHP to compile with LSAPI 6.3 and not LSAPI 5.5 ?
 

wanah

Well-Known Member
#10
Hello,

The instructions didn't metionion using a build utility, I ran ./configure [...] '--with-litespeed'

However I did buil PHP version 5.4.20 and this file contains

Code:
PHP_VER = array('5'=>
		 array(
		 	'5.5.3',
		 	'5.4.19',
		 	'5.3.27',
			'5.2.17'),
		 '4'=>
		 array('4.4.9'));

define ('LSAPI_VERSION', '6.3');
Does this mean I can't go over 5.4.19 ?

Also I did not use this file, it does conatin 'LSAPI_VERSION', '6.3' but how is the ./configure command supposed to know that ?
 
#11
re-read the thread from beginning, got idea what might have been wrong.

this file is used for build lsphp from lsadmin consonle:
/usr/local/lsws/admin/html/utility/build_php/buildconf.inc.php

and it'll update from time to time when new release/build comes out, so not a issue regarding "can't go over 5.4.19"

this wiki http://www.litespeedtech.com/support/wiki/doku.php?id=litespeed_wiki:multiple_phps_in_control_panel_lsws don't mention lsapi version.

just now I downloaded latest php-5.4.20 source, sapi/litespeed still in 5.5 version. to build with latest lsapi 6.3, please go https://www.litespeedtech.com/open-source/litespeed-sapi/download to get the latest 6.3, extract it, and replace all *.h and *.c in php-5.4.20/sapi/litespeed/ (and keep other files), then start build lsphp-5.4.20, the lsapi will be latest lsapi 6.3

I think(not verify yet) the GUI in admin console to build lsphp has automated above process.

Sorry for the inconvenience caused.
 
Last edited by a moderator:
Status
Not open for further replies.
Top