LiteSpeed Web Server is a high-performance and scalable web server software for servers with high resource consumption and high visitor traffic. When your instant hits are high,
the Apache web server in cPanel will not be able to handle incoming requests. In this case, many Apache processes will start running on the server and server load values will increase. To prevent such problems, LiteSpeed must absolutely be installed on your
server.
LiteSpeed is software that can be installed on a 15-day trial basis. Before purchasing a license, you can install this trial version to check whether it is beneficial for your server. However, the trial version does not allow you to configure all settings.
LiteSpeed has different license categories based on CPU and RAM ratios. Before purchasing a license, check your server; if you are using a virtual server, you need a license based on the RAM amount; if it is a physical server, based on the number of processors.
Installation
LiteSpeed installation is straightforward. After installation, once the necessary adjustments are made for the server, it works without issues. The following commands are sufficient for installation.
cd /usr/src
wget http://www.litespeedtech.com/packages/cpanel/lsws_whm_plugin_install.sh
chmod 700 lsws_whm_plugin_install.sh
./lsws_whm_plugin_install.sh
rm -f lsws_whm_plugin_install.shIf you want to remove it later, running the command below is sufficient.
sh /usr/local/cpanel/whostmgr/docroot/cgi/lsws/lsws_whm_plugin_uninstall.shAfter the installation is complete, connect to the WHM panel and go to the “LiteSpeed Web Server Plugin for WHM” section under Plugins, then perform the installation from the “Install LiteSpeed Web Server” section.
On the installation page, you only need to confirm the license section, enter your email address, and set an admin password.
After the installation is successfully completed, click “Build matching PHP binary” to copy your existing Apache and PHP configuration to LiteSpeed exactly. When this is also done, click the “Switch to LiteSpeed” button from the LiteSpeed Plugin main page to
activate LiteSpeed as the web service. If any problems occur, clicking the “Switch to Apache” button is sufficient to return to the Apache web server.
Notes on Some Special Situations
If you receive a memory error during the “Build matching PHP binary” process, you can go to the Tweak Settings section in the WHM panel and set “Max cPanel process memory” to 512MB.
The “Build matching PHP binary” process can also be done from the console using the command below.
sh /usr/local/cpanel/whostmgr/cgi/lsws/cmd_buildmatchingphp.shIn the LiteSpeed Admin interface: Go to the Configuration section, then to the Server menu, switch to the Security tab, and click the Edit button at the beginning of the File Access table. There, set:
Follow Symbolic Link: No
Check Symbolic Link: YesPress the Save button in the table and save. This will prevent symlink files from running through the web service. It is important for security.
In the Admin interface, click on General and press the Edit button in the Using Apache Configuration File table. Here, just set the PHP suEXEC Max Conn value to 100 and save. This is an operation that needs to be done for those running PHP suEXEC during
installation. It allows up to 100 processes to be performed on a website. The default value comes as 10 and can cause problems on high-traffic websites.
In the Admin interface: Go to the External App section and press the Delete button at the end of the lsphp4 row to remove lsphp4. Then go to the Script Handler section from the tabs and delete php4 from there as well. Since PHP4 is no longer in use, we strongly
recommend removing it as a security risk.
If you have CloudLinux on your server, you can configure LiteSpeed to run in compatibility with CloudLinux from the Server Process section in General.
After making changes to the settings, the notice “Configuration has been modified. To apply changes, please visit Control Panel and execute a Graceful Restart. Apply Changes” will appear in the Admin interface. Click the Apply Changes link, then press Graceful
Restart from the Action section to restart the LiteSpeed service — this is how your changes will take effect.
Finally, you can monitor live statistics from the Real-Time Stats section in the Actions menu, and by going to the Server section under Configuration and then to the Tuning tab, you can edit the connection limits for your server and optimize your web service to
your liking. If you are using a LiteSpeed with 2 or more CPUs, you can also access and configure the free Cache feature from this section.
Leave a Comment
* Your comment will be published after approval.
Comments
1güvenlik ve optimizasyon önerileri, Litespeed kullanımını daha verimli hale getirmek için faydalı bilgiler sunuyor. Genel olarak, bu makale, hem yeni başlayanlar hem de deneyimli kullanıcılar için değerli bir rehber niteliğinde.