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

Link to this comparison view

litespeed_wiki:install:commandline [2013/08/01 11:11]
litespeed_wiki:install:commandline [2014/06/27 16:04] (current)
Michael Armstrong
Line 1: Line 1:
-====== How to install ​LiteSpeed from Command Line ======+====== How to Set Up LiteSpeed ​Web Server ​from the Command Line ======
-Scope: Standard Edition and Enterprise ​Edition. +This wiki covers how to set up LSWS (either ​Enterprise ​or Standard edition) from the command line on a server that already has a working Apache installation. This wiki guides the user through the steps necessary to install LSWS and build PHP. **This wiki assumes that the user already has a working Apache installation.** LSWS will automatically read and run off the Apache configs already on this server.
-Audience: Those familiar with Unix/Linux console ​command line environment ​and see GUI as distraction ​and overhead.+
 +This wiki is meant for those familiar with the Unix/Linux console command line environment that see a GUI as a distraction and overhead. ​
 +This wiki is not meant for users using [[litespeed_wiki:​cpanel:​auto-installer|cPanel/​WHM]],​ [[litespeed_wiki:​plesk:​installation|Plesk]],​ or [[litespeed_wiki:​apache:​da|DirectAdmin]]. Users using a control panel should use the guide associated with their control panel.
 +===== Step 1: Download the LSWS package =====
-===== Step 1: Download LiteSpeed package ===== 
 Run the following commands from ssh as root Run the following commands from ssh as root
   cd /root   cd /root
-  wget http://​​packages/​4.0/​lsws-4.2.2-std-i386-linux.tar.gz+  wget http://​​packages/​4.0/​lsws-4.2.12-ent-x86_64-linux.tar.gz
-**Note:​** ​on some systems (Freebsd), fetch can be used+**Note:​** ​Replace the values in the URL to control for your OS and which version/​[[litespeed_wiki:​license:​what_license_to_choose|edition]] of LSWS you wish to download:
-===== Step 2: Unpack and Install =====+''​lsws-4.2.12-ent-x86_64-linux'' ​LSWS Enterprise 4.2.12 for 64bit Linux
-Unpack the tarball and install+''​lsws-4.2.10-std-i386-linux''​ = LSWS Standard 4.2.10 for 32bit Linux
-  ​tar zxf  lsws-4.2.2-std-i386-linux.tar.gz +''​lsws-4.2.12-ent-x86_64-freebsd6''​ = LSWS Enterprise 4.2.12 for 64bit FreeBSD 6.x 
-  cd lsws-4.2.2+ 
 +**Note:** On some systems (FreeBSD), fetch can be used. 
 +===== Step 2: Unpack and install ===== 
 +Unpack the tarball and run the install script 
 +  ​tar zxf  lsws-4.2.12-ent-x86_64-linux.tar.gz 
 +  cd lsws-4.2.12
   ./​   ./​
-If you set Port Offset to "​0",​ it may stop Apache and start LiteSpeed after successful installation,​ you may want to switch back to Apache temporarily as we still need to build PHP binary for LiteSpeed.+The installer will ask you a number of questions (covered in detail [[http://​​docs/​webserver/​install|here]]).
-===== Step 3Build matching PHP binary ===== +**Note:** The installer will ask you to set port offset. It may be best to set Port Offset to a number other than "​0"​. If Port Offset is set to "​0", ​LSWS may stop Apache and start LSWS after a successful installation. This is not idealsince we still need to build the PHP binary ​for LiteSpeed.
-There is pre-built PHP 4 binary coming with LSWS, however, you should ​build your own PHP binary ​using matching configuration options used by Apache mod_php+
-<​del>​If LiteSpeed is running, you should switch back to Apache temporarily by clicking "​switch to Apache"​ link.</​del>​ +===== Step 3: Build matching ​PHP =====
-Then, click "Build Matching ​PHP binary"​ link. It is going take a while.+
-**NOTE:**If you see below error message when Build Matching ​PHP, try increase "Max cPanel process memory (minimum: 256)" in cPanel (Main >> Server Configuration >> Tweak Settings) ​to at lease 512MB.+LSWS comes with a pre-built ​PHP 5 binarybut this only contains the barest of configurations and is not enough ​to run most websites. You should build your own PHP binary using configuration options to match those used by Apache
-<​file>​ +You can build PHP in two ways:
-Found Errors+
-ERROR/​usr/​local/​bin/​php -i returns 134 +  - Using the WebAdmin console. This is highly recommended,​ even for users who generally prefer the command line, as it combines steps. Simply access the WebAdmin through port 7080 and go to Actions > Compile PHP. There you will be guided through the steps to build PHP. 
 +  - [[litespeed_wiki:php:lsapi|From the command line.]]
-You can try to build matching PHP from command line +===== Step 4Verify and switch ports =====
-"/​usr/​local/​cpanel/​whostmgr/​cgi/​lsws/​"​ +
 +Restart LSWS
-===== Step 4: Start LiteSpeed again =====+  /​usr/​local/​lsws/​bin/​lswsctrl restart
-Just click "​Restart LiteSpeed"​ +Now you can verify ​on the port you've chosen with you port offset that everything works as expected. It should! 8-)
-Then you can verify ​if everything works as expected. It should! 8-)+
-If "Port Offset"​ is set to non-zero, ​you can now replace Apache with LiteSpeed Web Server. Just click "​Switch to LiteSpeed"​.+Once you've verified, switch LSWS onto port 80.
 That's it. That's it.
-**WARNING:​** Do **NOT** uncheck "​httpd"​ service under WHM service manager, otherwise WHM wont restart LiteSpeed automatically when configuration has been changed. ​ 
litespeed_wiki/install/commandline.1375369873.txt.gz · Last modified: 2013/08/01 11:11 by Michael