Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Example Analysis of SSD performance problems in MySQL Server

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)05/31 Report--

This article shares with you the content of a sample analysis of SSD performance issues in MySQL servers. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.

[question]

We have a HP server, and when SSD writes about 5000 IOPS, the% util reaches more than 80%. So whether there is any problem with the performance of this SSD, the following tests have been done to solve this problem.

[tools]

Blktrace is a tool used to troubleshoot IO performance under linux. It records the steps experienced by the IO and calculates the consumption of the IO request at each stage. Here are some key steps:

Q2G-time taken to generate IO requests, including remap and split

The time it takes for a G2I-IO request to enter IO Scheduler, including the time of merge

I2D-time for IO requests to wait in IO Scheduler

Time spent on driver and hardware for D2C-IO requests

Q2C-the time consumed by the entire IO request (G2I + I2D + D2C = Q2C), which is equivalent to the await of iostat.

Among them, D2C can be used as the index of hardware performance, and I2D can be used as the index of IO Scheduler performance.

[test 1. Compare the write performance of SSD before and after HP SSD Smart Path is enabled]

1. HP SSD Smart Path is on, SSD controller Caching is closed, Cache Ratio: 100% Read / 0% Write

The test results are as follows, mainly focusing on the AVG value of D2C (the time spent by IO requests on SSD), which is about 0.217ms

2. HP SSD Smart Path is off, SSD controller Caching is on, Cache Ratio: 10% Read / 90% Write

The test results are as follows, mainly focusing on the AVG value of D2C (the time spent by IO requests on SSD), which is about 0.0906ms

[conclusion]

The time spent on hardware of the former is about 2.4 times that of the latter. For write-based systems, it is recommended that HP SSD Smart Path is turned off and SSD controller Caching is turned on.

[test 2. Compare the performance of noop and deadline scheduling algorithms]

At present, there are four disk scheduling algorithms. The configuration value in our system is deadline, and it is recommended that SSD be configured as noop in many materials.

1. Anticipatory, suitable for personal PC, single disk system

2. CFQ (Complete Fair Queuing), default IO scheduling algorithm, completely fair queuing scheduling algorithm

3. Deadline, scheduling in each IO queue according to the deadline

4. Noop, simple FIFO queue for scheduling

The following are all tested with HP SSD Smart Path turned off

1. Deadline, mainly focusing on G2I and I2D

2. Modify it to noop

[conclusion]

Noop's IO Scheduler waits and consumes slightly better time than deadline, but the difference is not significant. If an assessment is required, further detailed testing in each scenario is required.

The following figure shows the comparison of online data tests on different scheduling algorithms:

[test 3. Compare the time spent on this server SSD with the same configuration SSD]

The AVG D2C is 0.0906 Ms, and the difference is not significant, indicating that the SSD of this server is normal in response time.

Thank you for reading! This is the end of this article on "sample analysis of SSD performance problems in MySQL servers". I hope the above content can be helpful to you, so that you can learn more knowledge. if you think the article is good, you can share it for more people to see!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report