Webserver being stopped on reboot

Junaid

Verified User
Joined
Oct 22, 2019
Messages
20
Hi, a weird problem I'm facing for a long.

So I have rebooted my server a few days back and then found none of the websites is working anymore. It is giving an error saying "503" after loading a long.

I've tried to troubleshoot the issue and after a lot of research, I found running a command "./build rewrite_confs" is fixing everything instantly.
I thought the issue got fixed but wonder it is happening on every reboot of the server. It is creating a lot of mess for me.

Please note that I'm using Openlitespeed as my webserver along with Cloudlinux.
Besides, I have run a command "chattr -i /usr/local/directadmin/custombuild/versions.txt" someday before for an issue of the custom build which was recommended by "@smtalk".
Reference: https://forum.directadmin.com/threads/problem-with-custombuild.62601/

Does anyone have the solution for it?

Thanks in advance. :(
 
What OS version 7 or 8?

Have you run
Code:
yum update
lately

If you reboot is litespeed running?
Code:
systemctl lsws status
running or stopped?

Have you run
Code:
systemctl lsws enable

I found running a command "./build rewrite_confs" is fixing everything instantly.
That could be because its starting the lightspeed server
 
Last edited:
found running command "service lsws restart" is also working after rebooting.

But I had to run it after every reboot. :(
 
What OS version 7 or 8?

Have you run
Code:
yum update
lately

If you reboot is litespeed running?
Code:
systemctl litespeed status
running or stopped?

Have you run
Code:
systemctl litespeed enable


That could be because its starting the lightspeed server
-OS Version is 7.
-Ran the yum update already.
- systemctl litespeed status is giving an output saying "Unknown operation 'litespeed'." In fact all the other commands with systemctl saying the same.

I agree with you. Now it seems litespeed is not running after reboot to me as well.
Because It is working nicely while i run command "service lsws restart" manually after reboot.
 
It is giving an output saying
The service command supports only basic LSB actions (start, stop, restart, try-restart, reload, force-reload, status). For other actions, please try to use systemctl.
 
Ok sorry try these
If you reboot is litespeed running?
Code:
Code:
systemctl lsws status
running or stopped?

Have you run
Code:
Code:
systemctl lsws enable
 
Ok sorry try these
If you reboot is litespeed running?
Code:
Code:
systemctl lsws status
running or stopped?

Have you run
Code:
Code:
systemctl lsws enable
This saying the same dear. Already tried.

Unknown operation 'lsws'.

and

"The service command supports only basic LSB actions (start, stop, restart, try-restart, reload, force-reload, status). For other actions, please try to use systemctl."
 
systemctl is working now after running "systemctl reload litespeed".

Then tried to enable litespeed by "systemctl enable litespeed".

Unfortunately it still giving the same issue. :(

Let me follow your build all procedures.
 
ok if you reboot now
and then run only service litespeed status
once the box comes online what do you get?

Also to Note
I found this https://forum.directadmin.com/threads/centos-7-7-openlitespeed-restart-error.59073/

You might want to a build All if you have not.

Code:
cd /usr/local/directadmin/custombuild
./build set_fastest
./build clean
./build update
./build all
Unfortunately, it results the same dear. :'(
Had to restart the litespeed to make the websites work.

I have checked the status of litespeed before the restart and it was showing active (running). But still, the websites did not being loaded. It just works fine with a simple litespeed restart. How weird it is. :'(
 
Is the service enabled? Not sure what the command is for that, I think systemctl <service> enable , enable/service might be swapped tho, i allways mess that up
 
Is the service enabled? Not sure what the command is for that, I think systemctl <service> enable , enable/service might be swapped tho, i allways mess that up
Yes the service is enabled and i have cross checked it.

It is showing active(running) on reboot but still needs "service litespeed restart" command to make the website works. :(
 
Yes the service is enabled and i have cross checked it.

It is showing active(running) on reboot but still needs "service litespeed restart" command to make the website works. :(
This is so strange. Have you tried rebuilding it (litespeed)?
 
Can you move lightspeed's boot script down the boot runtime list, so it starts after everything else....... Might not be it but worth a shot.
 
Can you move lightspeed's boot script down the boot runtime list, so it starts after everything else....... Might not be it but worth a shot.
That's a nice idea indeed.

Would you mind suggesting to me how can I do that?
I mean it would be something great for me if you can tell me the commands or the step I should follow.

Thank you ^_^
 
Back
Top