Lighttpd rewording, remove PHP 5 refs (#1522)

Co-authored-by: Christoph M. Becker <cmbecker69@gmx.de>
This commit is contained in:
Sergey Panteleev 2022-04-15 13:43:22 +03:00 committed by GitHub
parent 96f69db3ae
commit 7006df7c1f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -14,19 +14,16 @@
</para>
<para>
Fastcgi is the preferred SAPI to connect PHP and Lighttpd. Fastcgi is
automagically enabled in php-cgi in PHP 5.3, but for older versions configure
PHP with --enable-fastcgi. To confirm that PHP has fastcgi enabled,
<literal>php -v</literal> should contain <literal>PHP 5.2.5 (cgi-fcgi)</literal>
Before PHP 5.2.3, fastcgi was enabled on the php binary (there was no php-cgi).
FastCGI is the preferred SAPI to connect PHP and Lighttpd. FastCGI is
automagically enabled in php-cgi.
</para>
<sect2 xml:id="install.unix.lighttpd-14.lighttpd-spawn">
<title>Letting Lighttpd spawn php processes</title>
<para>
To configure Lighttpd to connect to php and spawn fastcgi processes, edit
lighttpd.conf. Sockets are preferred to connect to fastcgi processes on
To configure Lighttpd to connect to PHP and spawn FastCGI processes, edit
<filename>lighttpd.conf</filename>. Sockets are preferred to connect to FastCGI processes on
the local system.
</para>
@ -55,15 +52,15 @@ fastcgi.server = ( ".php" =>
</example>
<para>
The bin-path directive allows lighttpd to spawn fastcgi processes dynamically.
PHP will spawn children according to the PHP_FCGI_CHILDREN environment
variable. The "bin-environment" directive sets the environment for the
The <filename>bin-path</filename> directive allows lighttpd to spawn FastCGI processes dynamically.
PHP will spawn children according to the <envar>PHP_FCGI_CHILDREN</envar> environment
variable. The <literal>bin-environment</literal> directive sets the environment for the
spawned processes. PHP will kill a child process after the number of
requests specified by PHP_FCGI_MAX_REQUESTS is reached. The directives
"min-procs" and "max-procs" should generally be avoided with PHP. PHP
requests specified by <envar>PHP_FCGI_MAX_REQUESTS</envar> is reached. The directives
<literal>min-procs</literal> and <literal>max-procs</literal> should generally be avoided with PHP. PHP
manages its own children and opcode caches like APC will only share among
children managed by PHP. If "min-procs" is set to something greater than 1,
the total number of php responders will be multiplied PHP_FCGI_CHILDREN
children managed by PHP. If <literal>min-procs</literal> is set to something greater than <literal>1</literal>,
the total number of php responders will be multiplied <envar>PHP_FCGI_CHILDREN</envar>
(2 min-procs * 16 children gives 32 responders).
</para>
</sect2>
@ -73,7 +70,7 @@ fastcgi.server = ( ".php" =>
<para>
Lighttpd provides a program called spawn-fcgi to make the process of
spawning fastcgi processes easier.
spawning FastCGI processes easier.
</para>
</sect2>
@ -82,9 +79,9 @@ fastcgi.server = ( ".php" =>
<para>
It is possible to spawn processes without spawn-fcgi, though a bit of
heavy-lifting is required. Setting the PHP_FCGI_CHILDREN environment var
heavy-lifting is required. Setting the <envar>PHP_FCGI_CHILDREN</envar> environment var
controls how many children PHP will spawn to handle incoming requests.
Setting PHP_FCGI_MAX_REQUESTS will determine how long (in requests) each
Setting <envar>PHP_FCGI_MAX_REQUESTS</envar> will determine how long (in requests) each
child will live. Here's a simple bash script to help spawn php responders.
</para>
@ -123,7 +120,7 @@ echo $! > "$PHP_PID"
<title>Connecting to remote FCGI instances</title>
<para>
Fastcgi instances can be spawned on multiple remote machines in order to
FastCGI instances can be spawned on multiple remote machines in order to
scale applications.
</para>
@ -140,7 +137,6 @@ fastcgi.server = ( ".php" =>
</example>
</sect2>
</sect1>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml