Config issue. High %iowait when litespeed enabled

sahostking

Well-Known Member
#1
Having a major problem with litespeed and after asking cPanel for support they informed me it's either litespeed or CXS. I disabled CXS completely and still it had high diskio.

I then decided to do the following and switch between apache and litespeed to see the difference.

Litespeed:

07:37:25 PM CPU %user %nice %system %iowait %steal %idle
07:37:27 PM all 2.25 0.00 0.62 28.17 0.00 68.96
07:37:29 PM all 8.69 0.00 1.81 19.57 0.00 69.92
07:37:31 PM all 1.25 0.00 0.44 39.50 0.00 58.81
07:37:33 PM all 5.82 0.00 2.07 25.84 0.00 66.27
07:37:35 PM all 1.44 0.00 0.69 30.04 0.00 67.83
07:37:37 PM all 4.00 0.00 1.81 26.89 0.00 67.29
07:37:39 PM all 2.69 0.00 1.19 36.06 0.00 60.06
07:37:41 PM all 10.76 0.00 2.44 26.47 0.00 60.33
07:37:43 PM all 10.75 0.00 2.44 25.81 0.00 61.00
07:37:45 PM all 3.62 0.00 1.50 14.36 0.00 80.52
07:37:47 PM all 4.43 0.00 1.62 10.18 0.00 83.76
07:37:49 PM all 8.38 0.00 2.88 10.13 0.00 78.61
Average: all 5.34 0.00 1.63 24.42 0.00 68.62


If I switch to apache I get this:

07:53:20 PM CPU %user %nice %system %iowait %steal %idle
07:53:22 PM all 13.38 0.00 0.38 2.19 0.00 84.06
07:53:24 PM all 11.36 0.00 1.06 0.31 0.00 87.27
07:53:26 PM all 0.44 0.00 0.31 0.19 0.00 99.06
07:53:28 PM all 1.44 0.00 0.50 0.00 0.00 98.06
07:53:30 PM all 3.25 0.00 0.63 0.25 0.00 95.87
07:53:32 PM all 0.12 0.00 0.19 0.44 0.00 99.25
07:53:34 PM all 2.44 0.00 0.69 0.19 0.00 96.68
07:53:36 PM all 0.75 0.00 0.31 0.12 0.00 98.81
07:53:38 PM all 3.88 0.00 0.81 0.88 0.00 94.44
07:53:40 PM all 14.83 0.00 0.69 0.44 0.00 84.04
07:53:42 PM all 14.17 0.00 0.81 1.06 0.00 83.96
07:53:44 PM all 10.94 0.00 1.69 0.75 0.00 86.62
Average: all 6.42 0.00 0.67 0.57 0.00 92.34


Makes no sense thought litespeed is faster than apache by far. Maybe its a setup issue? What should I look out for?
 

mistwang

LiteSpeed Staff
#2
If this server is constantly dealing with dynamic content with request/response body larger than 1MB, LSWS may use temporary file to store the body data, which could increase disk I/O activities, cause higher I/O wait.

There could be other factors, you should check output of "iotop" was well.
 

mistwang

LiteSpeed Staff
#4
Generally, higher I/O wait is caused by higher disk I/O activities, why there are more disk I/O activities, I cannot answer it without checking the server. there are many factors.
But you need to need to identify where the disk I/O activities coming from. you can use iotop, then do some strace on the process generates a lot of disk I/O.
 
Top