Litespeed web server logs taking up too much space. Please help.

#1
Hi,
I have a digital ocean droplet with ubuntu where i have installed cyberpanel with openlitespeed server and I am hosting a few starter blog sites for myself. Recently the droplet disk usage increased significantly from 30-35% to around 60% within a day. I am not very knowledgeable about using the ssh terminal however i have researched online and found out the lsws logs folder is taking a huge amount of space. I ran a command that gave me a list of files with the biggest size. Please check below

45292823 /
26199424 /usr
23155208 /usr/local
21697148 /usr/local/lsws
20799116 /usr/local/lsws/logs
20721768 /usr/local/lsws/logs/stderr.log.2024_09_12.01
9211216 /home
6272352 /var
As you can see the stderr.log.2024_09_12.01 is taking huge amount of space so I want to know

1- how to delete it properly and whether it is save to delete these log files?
2-How can i disable the logs and make sure that this does not happen again.
3- Also is there a way to read the log files and know what issue is creating these logs files in the first place?

I am not an expert in these things so please ignore if these questions sound stupid but I would appreciate if anyone can help or maybe guide me to where I can get more info about these issues.Thank you.
 
#3
Sorry my mistake I copied incorrect data as I am not very good with commands. However I installed this ncdu https://dev.yorhel.nl/ncdu/scr program which gives a graphical interface of the usage and i took some screenshot. You can see that the logs are taking around 20gb and my server is only 70 gb. Please check attached files.

The screenshot shows std error logs as around 20gb and i am not sure why when i run the command it shows in MBs. When i check digitalocean droplet stats it also shows the usage has increased so the logs are 20 GB and the disk is being used.
 

Attachments

Last edited:
#6
@Cold-Egg Thanks for the reply. I will delete the stderr log file but i just wanted to make sure that it will not affect the server in any negative way.So i understand that I can delete it without any issue.
 
Top