lsapi slave

Clockwork

Well-Known Member
#1
Hello,

I would like to add an lsapi slave to one of my litespeed webservers.

Is there any guide how to do this?

The webserver itself should still process php requests, not only the slave, so that I can use the performance from both servers.

I know how to build lsapi, but I'm stuck on the configuration on my lsws.
 

webizen

Well-Known Member
#4
a typical setup is as follows:
1. start lsphp from command line
PHP_LSAPI_MAX_REQUESTS=500 PHP_LSAPI_CHILDREN=35 /path/to/lsphp -b IP_address:port
2. setup external app (such as 'remote php') and script handler (for php handled by 'remote php' ext app) on web server.
external app:
address => IP_address: port (in step 1)
auto start => no
 

Clockwork

Well-Known Member
#5
might be a dump questions, but do I need to copy the php files to the remote php machine?

Because I receive errors like this:

PHP Warning: Unknown: failed to open stream: Operation not permitted in Unknown on line 0
 

webizen

Well-Known Member
#6
no need. however, php binary on the remote server needs proper permission to access the resource as if it runs from the web server.
 

webizen

Well-Known Member
#8
take it back. you need to copy the file(s) to the remote server. file path needs to be the same. if web server is chroot'd, file path starts from chroot (e.g. /path/to/chroot/lsws/...) needs to be under file system root of the remote server (/lsws/...).
 
Top