Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
litespeed_wiki:php [2018/09/13 21:19]
Michael Alegre [PHP SuEXEC Mode or non-suEXEC]
litespeed_wiki:php [2018/09/18 21:06] (current)
Michael Alegre [Configuration Tips]
Line 1: Line 1:
-====== PHP with LiteSpeed Web Server ​======+====== ​LSPHP (PHP + LSAPI) ​======
  
-===== How to configure PHP for LSWS on control ​panel environment? ===== +===== Installing and Configure LSPHP on LiteSpeed Web Server ===== 
-If you use any control panel such as cPanel, Plesk or DirectAdmin , there is no extra configuration required since LSWS installaion ​script will configure everything for you and you should run PHP out of the box after installation. LSWS will use the same PHP as Apache set on your control panel automatically. ​+ 
 +==== Control ​panel environment ==== 
 +If you use any control panel such as cPanel, Plesk or DirectAdmin , there is no extra configuration required since LSWS installation ​script will configure everything for you and you should ​be able to run PHP out of the box after installation. LSWS will use the same PHP version ​as Apache set on your control panel automatically. ​
  
 You can refer to the corresponding section for your environment to understand how it works for  You can refer to the corresponding section for your environment to understand how it works for 
Line 12: Line 14:
 If you are using CloudLinux, [[litespeed_wiki:​cloudlinux:​php-selector|PHP selector]] is the recommended way to set up PHP. If you are using CloudLinux, [[litespeed_wiki:​cloudlinux:​php-selector|PHP selector]] is the recommended way to set up PHP.
  
-===== Install and Configurate PHP on LSWS native mode Without ​Control Panel =====+==== Native (without ​control panel) ​====
  
-Unlike apache or nginx using php-fpm or fastcgi, LSWS uses lsphp, which is faster than php-fpm or fastcgi. On LSWS native ​mode, you can install ​lsphp from LiteSpeed CentOS, Ubuntu/​Debian repositories,​ then create/​configure external app and script handler to point LSWS to use newly installed ​php binaries. ​+Unlike apache or nginx using php-fpm or fastcgi, LSWS uses LSPHP, which is faster than php-fpm or fastcgi. On LSWS (native), you can install ​LSPHP from LiteSpeed CentOS, Ubuntu/​Debian repositories,​ then create/​configure external app and script handler to point LSWS to use the newly installed ​PHP binaries. ​
  
-Please see this [[litespeed_wiki:​php:​configuring-lsws-for-php|LSPHP Setup Overview]].+Please see [[litespeed_wiki:​php:​configuring-lsws-for-php|Configuring LiteSpeed Web Server for PHP]].
  
-==== Install LSPHP ==== 
-  * [[litespeed_wiki:​php:​rpm|Installing LSPHP via RPM: The fastest way to get PHP for CentOS]] 
-  * [[litespeed_wiki:​php:​apt|Installing LSPHP via APT: The fastest way to get PHP for Debian/​Ubuntu]] 
  
-==== Create/​Configrate PHP external apps and script handlers ​==== +===== Execution Method ===== 
-  ​* ​[[litespeed_wiki:​other-ext-apps:setup|create a PHP external application mapping to the installed PHP Binary]] +Please see [[litespeed_wiki:​php:which_php_setup_am_i_using|suEXEC or non-suEXEC]]guide to figure out which PHP execution method you are using.
-  * [[litespeed_wiki:​php:​configuring-lsws-for-php#​the_script_or_context_handler|set ​script handler mapping ​to the PHP external application]].+
  
- +===== Process Modes: ProcessGroup/​Daemon/​Worker =====
-===== PHP Execution Method ===== +
-Please see [[litespeed_wiki:​php:​which_php_setup_am_i_using|suEXEC or non-suEXEC]],​ a guide to figure out which PHP setup you are using. +
- +
-===== PHP Process Modes: ProcessGroup/​Daemon/​Worker =====+
  
 LiteSpeed Web Server offers a number of different [[litespeed_wiki:​php:​process-mode|PHP process modes]] for the various needs and goals of shared hosting providers: [[litespeed_wiki:​php:​process-mode#​processgroup_mode|ProcessGroup mode]], [[litespeed_wiki:​php:​process-mode#​daemon_mode|Daemon mode]], and [[litespeed_wiki:​php:​process-mode#​worker_mode|Worker mode]]. LiteSpeed Web Server offers a number of different [[litespeed_wiki:​php:​process-mode|PHP process modes]] for the various needs and goals of shared hosting providers: [[litespeed_wiki:​php:​process-mode#​processgroup_mode|ProcessGroup mode]], [[litespeed_wiki:​php:​process-mode#​daemon_mode|Daemon mode]], and [[litespeed_wiki:​php:​process-mode#​worker_mode|Worker mode]].
  
  
-===== PHP Opcode Cache =====+===== Opcode Cache =====
   * [[litespeed_wiki:​php:​opcode_cache|Opcode Caching Overview: An introduction to opcode caching, its limitations,​ and popular opcode caches]]   * [[litespeed_wiki:​php:​opcode_cache|Opcode Caching Overview: An introduction to opcode caching, its limitations,​ and popular opcode caches]]
   * [[litespeed_wiki:​php:​enable_opcode_cache|Enable opcode cache: How to enable PHP opcode cache for LiteSpeed]]   * [[litespeed_wiki:​php:​enable_opcode_cache|Enable opcode cache: How to enable PHP opcode cache for LiteSpeed]]
  
-===== PHP Detached Mode ===== +===== Detached Mode ===== 
-  ​* ​[[litespeed_wiki:​php:​detached_mode|LSWS 5.3 introduce PHP detached ​mode]]+As of LiteSpeed Web Server version 5.3, LSPHP can be run independent of the web server in [[litespeed_wiki:​php:​detached_mode|Detached ​mode]]. This allows the LSPHP process, and it's opcode cache, to survive through server restarts.
  
-===== PHP Troubleshooting =====+===== Troubleshooting =====
   * [[litespeed_wiki:​php:​execution-errors|PHP Execution Errors: Basic steps to troubleshoot PHP-related issues in LSWS.]]   * [[litespeed_wiki:​php:​execution-errors|PHP Execution Errors: Basic steps to troubleshoot PHP-related issues in LSWS.]]
   * [[litespeed_wiki:​php:​503-errors|PHP 503 Errors: Basic steps to troubleshoot PHP-503-related issues in LSWS.]]   * [[litespeed_wiki:​php:​503-errors|PHP 503 Errors: Basic steps to troubleshoot PHP-503-related issues in LSWS.]]
Line 49: Line 43:
  
 ===== Set up Multiple Versions of PHP===== ===== Set up Multiple Versions of PHP=====
-  * [[litespeed_wiki:​php:​running-multiple-versions-with-a-control-panel|Running Multiple PHP versions in LiteSpeed with a Control Panel]] 
   * [[litespeed_wiki:​cpanel:​easyapache4-config|Configuring cPanel + EasyApache 4 with LiteSpeed]]   * [[litespeed_wiki:​cpanel:​easyapache4-config|Configuring cPanel + EasyApache 4 with LiteSpeed]]
  
-===== Install PHP PECL Extensions on LSWS native mode or OpenLiteSpeed =====+===== Install PHP PECL Extensions on LiteSpeed Web Server (Native) ​or OpenLiteSpeed =====
 Check the availability of LSPHP PECL extention or build by yourself? See [[litespeed_wiki:​php:​pecl-extension|How to install pecl extention for LSPHP]]. Check the availability of LSPHP PECL extention or build by yourself? See [[litespeed_wiki:​php:​pecl-extension|How to install pecl extention for LSPHP]].
  
Line 67: Line 60:
   * [[litespeed_wiki:​php:​mysql-persistent-connections|Performance tip: avoid php/mysql persistent connections.]]   * [[litespeed_wiki:​php:​mysql-persistent-connections|Performance tip: avoid php/mysql persistent connections.]]
   * [[litespeed_wiki:​php:​run-without-timeouts|Disable PHP timeouts: Make LSWS compatible with long-running processes]]   * [[litespeed_wiki:​php:​run-without-timeouts|Disable PHP timeouts: Make LSWS compatible with long-running processes]]
-  * [[litespeed_wiki:​php:​generate-source-code-with-lsapi|Use LSAPI to generate source code for viewing with a browser]]+  * [[litespeed_wiki:​php:​generate-source-code-with-lsapi|Use LSAPI to generate ​formatted PHP source code for viewing with a browser]]
   * [[litespeed_wiki:​php:​fcgi-environment-variables|Supported environment variables for non-LSAPI applications]]   * [[litespeed_wiki:​php:​fcgi-environment-variables|Supported environment variables for non-LSAPI applications]]
   * [[litespeed_wiki:​php:​maxwaitq-limit|PHP Max Wait Queue Limit: Preventing the PHP wait queue from getting too long]]   * [[litespeed_wiki:​php:​maxwaitq-limit|PHP Max Wait Queue Limit: Preventing the PHP wait queue from getting too long]]
Line 75: Line 68:
   * [[litespeed_wiki:​php:​user-user.ini-with-lsphp|How to use .user.ini with LSPHP]]   * [[litespeed_wiki:​php:​user-user.ini-with-lsphp|How to use .user.ini with LSPHP]]
   * [[litespeed_wiki:​php:​per-user-php-ini|Four methods for enabling per-user php.ini]]   * [[litespeed_wiki:​php:​per-user-php-ini|Four methods for enabling per-user php.ini]]
-  * [[litespeed_wiki:​php:​per-directory-php|Enabling per-directory PHP in LSWS Native Mode]]+  * [[litespeed_wiki:​php:​per-directory-php|Enabling per-directory PHP in LSWS (native)]]
  
 ===== Add-Ons/​Extensions ===== ===== Add-Ons/​Extensions =====
-  * [[http://​www.litespeedtech.com/​support/​forum/​showthread.php?​t=874|How to connect ​to Oracle with PHP + LSAPI]] +  * [[http://​www.litespeedtech.com/​support/​forum/​showthread.php?​t=874|Connecting ​to Oracle with PHP + LSAPI]] 
-  * [[http://​wowtutorial.org/​tutorial/​3.html|How to build a LiteSpeed PHP5 LSAPI With Suhosin Patch and Extension on FreeBSD 6.2]] +  * [[http://​wowtutorial.org/​tutorial/​3.html|Building ​a LiteSpeed PHP5 LSAPI With Suhosin Patch and Extension on FreeBSD 6.2]]
-  * [[litespeed_wiki:​php:​uploadprogress_bar|How to set up an upload progress bar for PHP]]+
   * [[litespeed_wiki:​php:​new_relic|How to get New Relic to work with LSWS]]   * [[litespeed_wiki:​php:​new_relic|How to get New Relic to work with LSWS]]
  
-===== Archive Only ===== +
-The following articles are deprecated and are listed here for archival purposes only: +
-  * [[litespeed_wiki:​php:​lsapi|Compiling PHP with LSAPI through the WebAdmin console]] +
-  * [[litespeed_wiki:​php:​lsapi-troubleshooting|A troubleshooting guide for compiling and installing a custom PHP with LSAPI]] +
-  * [[litespeed_wiki:​php:​lsapi-for-ubuntu-or-debian|How to create a .deb package with PHP + LSAPI for Ubuntu Dapper Drake and Edgy Eft]]+
 
litespeed_wiki/php.1536873564.txt.gz · Last modified: 2018/09/13 21:19 by Michael Alegre