[unsolved] I probably didn't install Litespeed correctly

#1
When checking the LiteSpeed admin I see that all services are running Litespeed.

Checking out the http header of a website shows that Apache/2.4.16 (cPanel) OpenSSL/1.0.1e-fips is still running.

Looking at the log from a minute ago I see the last 10 error log lines:
2015-10-26 02:31:08.238 ERROR [/usr/local/apache/conf/httpd.conf:776] Listener for 77.235.46.18:80 is not available!
2015-10-26 02:31:08.239 ERROR [/usr/local/apache/conf/httpd.conf:833] Listener for 77.235.46.18:80 is not available!
2015-10-26 02:31:08.240 ERROR [/usr/local/apache/conf/httpd.conf:889] Listener for 77.235.46.18:80 is not available!
2015-10-26 02:31:08.241 ERROR [/usr/local/apache/conf/httpd.conf:945] Listener for 77.235.46.18:80 is not available!
2015-10-26 02:31:08.241 ERROR [/usr/local/apache/conf/httpd.conf:226] Listener for *:80 is not available!
2015-10-26 02:47:36.839 ERROR HttpListener::start(): Can't listen at address adminListener: Address already in use!
2015-10-26 02:47:36.839 ERROR HttpServer::addListener(adminListener) failed to create new listener
2015-10-26 02:47:36.839 ERROR [config:admin:listener:adminListener] failed to start listener on address 77.235.46.18:7080!
2015-10-26 02:47:36.839 ERROR [config:admin:listener] No listener is available for admin virtual host!
2015-10-26 02:47:36.839 ERROR Fatal error in configuration, exit

How can I solve this?
 
#3
Thanks for your quick reply Nitewave. I have followed your instructions and LiteSpeed is active only now the websites with a database are giving a 404 error.
 
#4
Didn't restart Apache properly. Now it's running like you said it would :) first test reduce the page from 1.5s to 0.4s! Loving it already
 
#5
Need to come back to my statement.

Parts of the website's are not loading all parts, or are giving a 404 in return.

One of the errors I'm receiving in the WHM Plugin:

"Found Apache PHP binary at /usr/local/bin/php Version is 5.6.14 /usr/local/lsws/fcgi-bin/lsphp5 exists, but not runnable: ERROR: /usr/local/lsws/fcgi-bin/lsphp5 -i returns 126"
 
#7
I'm staying away till further instructions:

The HTTP header says Apache is running.

Inside WHM Litespeed tells me Litespeed is running and apache is offline.

What should I be doing next to solve this problem?
 
#9
I can't uninstall cause Litespeed gives the error that Apache is not running (The system itself says it's running)

Building a matching LSPHP gives the following error in the beginning:

==============================================
Start building PHP 5.6.14 with LSAPI
==============================================
Mon Oct 26 11:40:02 CET 2015

Changing to build directory /home/cpeasyapache/ls.src
*********************************************
**
** BUILD MATCHING PHP FAILED **************
**
** -- ERROR -- Cannot find php build directory for cPanel, please run EasyApache first to build PHP with correct options for Apache.
*********************************************
 
#10
can you switch back to apache ?

then run EasyApache (under apache), to build php, to make sure the websites works well first(under apache).

then Build a matching LSPhp again.
 
#11
Switching back to Apache gives the following error code, see pastebin below:
http://pastebin.com/i8gADNFz

Following the instruction from Litespeed gives me the following:

1) Stop LiteSpeed if lshttpd still running: killall -9 lshttpd
Response:
lshttpd: no process killed

2) Restore Apache httpd if /usr/sbin/httpd_ls_bak exists: mv -f /usr/sbin/httpd_ls_bak /usr/sbin/httpd
Response:
mv: cannot stat `/usr/sbin/httpd_ls_bak': No such file or directory

3) Run the Apache restart command manually: service httpd restart and check for errors.
Response:
httpd not running, trying to start
httpd (pid 379) already running
httpd started
 
#13
1
Using the command #ps -ef | grep litespeed I get: root 4835 64344 0 12:07 pts/0 00:00:00 grep litespeed

Using the command killall -9 litespeed gives the error that no process got killed
--------------
2
Apache is running, the websites are working wel.

----------
3
Even though Apacke is running (cause the websites are up). Litespeed still doesn't recognise the fact that Apache is running so uninstallation of litespeed cannot be done.
 
#14
I have uninstalled Litespeed through SSH in the directory /usr/src/lsws/lsws-5.0.7/admin/misc only the Litespeed plugin is still enabled in WHM
Could it be that there is another litespeed installed? Cause the dir /usr/src/lsws/lsws-5.0.7 is still available


After some searching I found that there was another LiteSpeed installed from my first try. (I followed the directions at http://www.rackspace.com/knowledge_center/article/centos-installing-litespeed)

This one is located in /usr/local/lsws
 
Last edited:

Pong

Administrator
Staff member
#15
For cPanel, better using plug in to switch over between LiteSpeed and Apache.

Try to switch to LiteSpeed or Apache from plugin to see how it is going.
 
#16
Hi Pong, thanks for joining in :)

Since the start of this topic I haven't used SSH outside of what I have mentioned inside this topic. Apache is running but still doesn't get noticed.

In the mean while I have installed both Litespeed Installations, and installed Litespeed again through the auto-install plugin.

Even though it says that Litespeed is running and Apache is down inside the LiteSpeed plugin, doing a http header lookup shows me that Apache is still running.

I have tryed to build a matching LSPhp through the web panel of Litespeed which I came pretty far with, only ending with an error as shown below

http://pastebin.com/MuuZUWd6


But to be honest, I don't know what to do anymore at this point.

Edit
----
As the last Pastebin at the end mentioned an error [
configure: error: mcrypt.h not found. Please reinstall libmcrypt. ] I dove in that one.

I have installed libmcrypt and could continue the installation.

The installation was a success. I have restarted the LiteSpeed service and checked if the changes have been made using

cd /usr/local/lsws/fcgi-bin/
./lsphp5 -v

Output:
PHP 5.6.14 (litespeed) (built: Oct 26 2015 16:08:54)
Copyright (c) 1997-2015 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2015 Zend Technologies

The only thing is is that the webpages are still showing a 404....

What to do next...

I think i'm very close to installing litespeed now! The HTTP header is giving the correct header, static pages are being loaded only dynamic pages are only forbidden...
------------------------------

Great, I can't get inside any dynamic webpage.
Error: Access Forbidden

Error log:
2015-10-26 16:33:20.119 [ERROR] [31.151.199.39:53909] MIME type [application/x-httpd-ea-php56] for suffix '.php' does not allow serving as static file, access denied!
 
Last edited:

Pong

Administrator
Staff member
#18
A few things:
1. switching between LiteSpeed and Apache from plugin, plugin should recognize which server is running. Try it to make sure it works before doing other test.

2. Check your url: http://pastebin.com/MuuZUWd6, it is served from cloudflare-nginx. Could you temporarily turn cloudflare off for troubling shooting?

3. Which verison of easy apache are you running? Easy-aPache 3 is to compile PHP for Apache then build matching lsphp for LiteSpeed. While Easy Apache 4 is rpms based and requires easy apache litespeed package to work. For easy Apache php comping, you have to switch to Apache to run it.

4. For dynamic webpage access issue, any changes have you made to any configuration?
you can also check
https://www.litespeedtech.com/docs/webserver/config/security#restrictedScriptPermissionMask
https://www.litespeedtech.com/docs/webserver/config/security#restrictedDirPermissionMask

Suggest to troubleshoot one by one, otherwise it becomes a little complicated.
 

Pong

Administrator
Staff member
#20
MIME type [application/x-httpd-ea-php56] looks like you are using Easy Apache 4. seems no proper PHP handler yet.
 
Top