How to Minimize Excessive Disk I/O

Hello Guys,

Just want to know if you have any idea on how to How to Minimize Excessive Disk I/O?

Thanks.
@Foxdemon96

Maybe increase your RAM so db reads are not disk intensive.

Hello @rmehta,

Thanks for the great information. Though, I’m not still sure how do it right now.

My Server running under DigitalOcean
16GB Memory
8 vCPUs
100 SSD DISK

Thanks.
@Foxdemon96

Most disk I/O will be caused by misconfigured swap. I don’t know off-hand, but I’m sure there will be some optimisation apps that can analyse/report back on it for you.

Have you configured swapiness?

Excessive Disk I/O can come from many sources:

  • incorrectly configured swap space (as @trentmu described)
  • incorrectly configured mariadb can also cause a lot of disk access
  • fail2ban can also get stuck running way more than it should and may need to be altered

These are the ones I have encountered in the past and really only the mariadb adjustments reduced the swapfile usage enough to show a marked improvement in system performance.

See this thread for some additional info:

Most of my servers run with the following configuration:

5 CPU cores
10240mb RAM memory
150gb SSD drives
5TB transfer limit

I have many of these running between 15 and 35 users each with actual database sizes between 1.5 and 3.0gb in size. I have no speed issues and very little disk I/O to cause issues.

Even though I have 10gb of memory, I used the 20% guideline as my setting for the mariadb configuration. This leave enough resources for nginx, and the dozens of other system functions to operate properly without having to access swap space and without maxing our the reserved buffers.

Of course… Your mileage may vary! :sunglasses:

BKM

1 Like

Hello @trentmu,

Sorry but I don’t know yet how to configure swapiness.

But, once I configure it right now is there any consequence that I must take precautions first beforehand.

Thanks.
@Foxdemon96

Hello @bkm,

Thanks for sharing your ideas.

Thanks.
@bkm

Here’s a post by CodingCoffee that contains the commands you will probably need

Hello @trentmu,

Thanks so much for this great info.

Thanks.
@Foxdemon96