A method and system for optimizing storage performance of solid state hard disk based on load balancing

By distribute the storage area of ​​solid-state drives and dynamically adjusting the storage area of ​​solid-state drives, using linear sliding algorithms and time window detection technology, the problem of low accuracy in high load optimization of solid-state drive storage performance is solved, and more efficient data access and storage management is achieved.

CN119148950BActive Publication Date: 2025-03-18SHENZHEN RECADATA TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411661317.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-11-20
Publication Date
2025-03-18
Estimated Expiration
2044-11-20

AI Technical Summary

Technical Problem

Existing solid-state drive storage performance optimization technologies have low accuracy at high loads, especially when garbage collection operations occupy a large amount of resources, resulting in performance degradation.

Method used

By obtaining the storage area of ​​the solid-state drive for distributed division, extracting the cache area, using a linear sliding algorithm to calculate the similarity of data write requests, generating a write request queue, and detecting the load through the time window, dynamically adjusting the read and write ratio and storage weight, and optimizing the storage sub-region.

Benefits of technology

Improve data access efficiency and flexibility in storage management, reduce the risk of data loss, optimize write efficiency, improve system performance and data consistency, and ensure that the storage area is always in the best operating state.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119148950B_ABST
    Figure CN119148950B_ABST
Patent Text Reader

Abstract

The present invention relates to the technical field of data storage, and discloses a method and system for optimizing the storage performance of a solid-state hard disk based on load balancing, including: distributing a storage area; calculating the similarity of a data write request, generating a write request queue corresponding to the data write request according to the similarity, and detecting the write request load of the write request queue; generating a dynamic conversion factor of a read storage area in a storage sub-area according to the write request load, and calculating the storage weight of a write storage area in the storage sub-area; adjusting the write storage area in the storage sub-area according to the dynamic conversion factor and the storage weight, and generating an update sub-area according to the adjusted write storage area; writing the write data corresponding to the data write request in the write request queue in batches to the update sub-area, and detecting the storage performance optimization factor and optimization state of the update sub-area after writing. The present invention can improve the accuracy of optimizing the storage performance of a solid-state hard disk.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of data storage, and in particular to a method and system for optimizing the storage performance of a solid-state hard disk based on load balancing. Background Art

[0002] As the scale of data centers expands, the demand for cloud computing and big data analysis increases, and the amount of data generated by enterprises and users continues to increase, storage devices need to be able to handle higher read and write rates and greater data throughput. In order to improve the storage performance of solid-state drives, it is necessary to analyze the storage area of ​​the solid-state drive to improve storage performance.

[0003] Existing SSD storage performance optimization technologies are mostly aimed at optimizing garbage collection algorithms, reducing write amplification effects, and improving the overall performance and durability of SSDs. In actual applications, garbage collection may cause performance degradation under high load, especially when the recycling operation occupies a large number of resources, resulting in low accuracy when optimizing SSD storage performance. Summary of the invention

[0004] The present invention provides a method and system for optimizing the storage performance of a solid-state hard disk based on load balancing, the main purpose of which is to solve the problem of low accuracy when optimizing the storage performance of a solid-state hard disk.

[0005] To achieve the above object, the present invention provides a method for optimizing the storage performance of a solid state drive based on load balancing, comprising:

[0006] Obtain a preset storage area of ​​the solid-state hard disk, divide the storage area into distributed areas to obtain storage sub-areas, and extract a cache area corresponding to each storage sub-area;

[0007] Obtaining data write requests of the cache area, calculating similarities of the data write requests using a preset linear sliding algorithm, generating a write request queue corresponding to the data write request according to the similarities, and detecting a write request load of the write request queue through a preset time window;

[0008] Generate a dynamic conversion factor of a read storage area in the storage sub-area according to the write request load, and calculate a storage weight of a write storage area in the storage sub-area by a preset dual request weight algorithm;

[0009] Adjust the write storage area in the storage sub-area according to the dynamic conversion factor and the storage weight, and generate an update sub-area corresponding to the storage sub-area according to the adjusted write storage area;

[0010] The write data corresponding to the data write requests in the write request queue are written into the update sub-area in batches, and the storage performance optimization factor of the update sub-area after writing is detected, and the optimization state of the solid state drive is determined according to the storage performance optimization factor.

[0011] Optionally, the calculating the similarity of the data writing request by using a preset linear sliding algorithm includes:

[0012] Convert the data write request into a write string, and calculate a write hash value corresponding to the write string;

[0013] Determine the block point corresponding to the written hash value according to a preset block rule, and block the written hash value according to the block point to obtain the written block hash value, wherein the block rule is:

[0014]

[0015] in, Write the hash value The binary corresponding to the characters, For the default character binary, is the AND operator symbol, is the equality comparison operator;

[0016] The similarity of the data write request is calculated according to the write block hash value using the following linear sliding algorithm:

[0017]

[0018] in, Write request for data With data write request The similarity between is the total number of blocks for writing the block hash value, Write request for data Middle The linear coefficient of the hash value of the written block, Write request for data Middle The value written into the block hash value, Write request for data Middle The sliding coefficient of the hash value written to the block, Write request for data Middle The linear coefficient of the hash value written to the block, Write request for data Middle The value written into the block hash value, Write request for data Middle The sliding factor for writing block hash values.

[0019] Optionally, detecting the write request load of the write request queue through a preset time window includes:

[0020] Comparing the timestamp corresponding to each write data request in the write request queue with the time window, and generating a target write request queue according to the compared write request data;

[0021] Counting the number of requests in the target write request queue, and counting the request size of each data write request based on the number of requests;

[0022] The write request load of the target write request queue is calculated according to the request quantity and the request size, wherein the write request load is:

[0023]

[0024] in, For the write request load, For the The request size of a write data request, is the number of requests, is the window size of the time window.

[0025] Optionally, generating a dynamic conversion factor for a read storage area in the storage sub-area according to the write request load includes:

[0026] Detecting the area capacity of the blank area in the read storage area;

[0027] When the write request load is greater than the area capacity of the write storage area in the storage sub-area and the area capacity is greater than zero, determining the dynamic conversion factor as a preset first target conversion factor;

[0028] When the write request load is greater than the area capacity of the write storage area in the storage sub-area and the area capacity is equal to zero, determining the dynamic conversion factor as a preset second target conversion factor;

[0029] When the write request load is less than or equal to the area capacity of the write storage area in the storage sub-area, the dynamic conversion factor is determined as a preset third target conversion factor.

[0030] Optionally, the calculating the storage weight of the write storage area in the storage sub-area by using a preset dual request weight algorithm includes:

[0031] Counting the request frequency and request size of each block area in the write storage area;

[0032] Determining a dynamic frequency coefficient of the request frequency according to a dynamic change of the request frequency of the block area;

[0033] Determining a dynamic capacity coefficient of the request size according to a dynamic change of the request size of the block area;

[0034] The storage weight of each block area in the write storage area of ​​the storage sub-area is calculated according to the dynamic frequency coefficient and the dynamic capacity coefficient by using the following dual request weight algorithm:

[0035]

[0036] in, The write storage area is The storage weight of each block area, is the dynamic frequency coefficient, is the dynamic capacity coefficient, For the The request frequency of the block area, For the The requested size of the block area, is the area number of the block area in the write storage area.

[0037] Optionally, adjusting the write storage area in the storage sub-area according to the dynamic conversion factor and the storage weight includes:

[0038] When the dynamic conversion factor is the first target conversion factor, converting the read area in the storage sub-area into a write area, and splicing the write area with the write storage area in the storage sub-area to obtain an adjusted write storage area;

[0039] When the dynamic conversion factor is the second target conversion factor, reclaiming the write storage area in the storage sub-area by using the storage weight to obtain a reclaimed area, and determining an adjusted write storage area according to the reclaimed area;

[0040] When the dynamic conversion factor is the third target conversion factor, the original write storage area in the storage sub-area is determined as the adjusted write storage area.

[0041] Optionally, generating an update sub-region corresponding to the storage sub-region according to the adjusted write storage region includes:

[0042] determining an adjusted read storage area according to the adjusted write storage area;

[0043] Optimizing the pre-acquired data storage mapping table corresponding to the storage sub-area according to the adjusted write storage area and the adjusted read storage area;

[0044] The storage sub-region is updated by using the optimized data storage mapping table to obtain an updated sub-region.

[0045] Optionally, the batch writing the write data corresponding to the data write requests in the write request queue into the update sub-area includes:

[0046] Detecting a dynamic conversion factor corresponding to the write request queue;

[0047] When the dynamic conversion factor is a preset first target conversion factor and a third target conversion factor, writing the write data corresponding to the data write request in the write request queue into the update sub-area at one time;

[0048] When the dynamic conversion factor is a preset second target conversion factor and the adjusted write area corresponding to the second target conversion factor is smaller than the requested storage capacity in the write request queue, dividing the data write requests in the write request queue to obtain data write request segments;

[0049] Refreshing the update sub-area according to a preset request waiting time;

[0050] The write data corresponding to the data write request segment is written in batches into the refreshed update sub-area.

[0051] Optionally, the storage performance optimization factor of the updated sub-area after the detection of writing includes:

[0052] Acquire an update performance indicator of the update sub-region and an original performance indicator of the storage sub-region;

[0053] The storage performance optimization factor is calculated according to the updated performance index and the original performance index, wherein the storage performance optimization factor is:

[0054]

[0055] in, is the storage performance optimization factor, The update performance indicator The indicator value of The original performance index The indicator value.

[0056] In order to solve the above problems, the present invention also provides a solid state hard disk storage performance optimization system based on load balancing, the system comprising:

[0057] A storage area division module is used to obtain a preset storage area of ​​the solid state hard disk, divide the storage area into distributed areas to obtain storage sub-areas, and extract a cache area corresponding to each storage sub-area;

[0058] A write request load detection module, used to obtain data write requests of the cache area, calculate the similarity of the data write requests using a preset linear sliding algorithm, generate a write request queue corresponding to the data write request according to the similarity, and detect the write request load of the write request queue through a preset time window;

[0059] A storage weight calculation module, used to generate a dynamic conversion factor of a read storage area in the storage sub-area according to the write request load, and calculate a storage weight of a write storage area in the storage sub-area by a preset dual request weight algorithm;

[0060] An update sub-region generating module, used for adjusting the write storage region in the storage sub-region according to the dynamic conversion factor and the storage weight, and generating an update sub-region corresponding to the storage sub-region according to the adjusted write storage region;

[0061] A storage optimization status determination module is used to batch write the write data corresponding to the data write requests in the write request queue into the update sub-area, and detect the storage performance optimization factor of the update sub-area after writing, and determine the optimization status of the solid-state drive according to the storage performance optimization factor.

[0062] The embodiments of the present invention can effectively improve the access efficiency of data and the flexibility of storage management by dividing the storage area into distributed areas, while reducing the risk of data loss; by analyzing the similarity of write requests, the storage method of data can be optimized, random writes can be reduced, and write efficiency can be improved; dynamic monitoring of the load of write requests is helpful to adjust the storage strategy in real time; dynamically adjusting the read-write ratio according to the load of write requests can better meet the performance requirements under different workloads; through the dual request weight algorithm, the write priority of the storage area can be reasonably allocated to improve the write performance and data consistency; adjusting the write storage area according to actual needs can optimize the utilization of storage resources; regularly detecting the storage performance optimization factor to ensure that the storage area is always in the best operating state. Therefore, the solid-state hard disk storage performance optimization method and system based on load balancing proposed by the present invention can solve the problem of low accuracy when optimizing the storage performance of solid-state hard disks. BRIEF DESCRIPTION OF THE DRAWINGS

[0063] Figure 1A schematic diagram of a process flow of a method for optimizing storage performance of a solid state drive based on load balancing provided by an embodiment of the present invention;

[0064] Figure 2 A schematic diagram of a process for detecting a write request load provided by an embodiment of the present invention;

[0065] Figure 3 A schematic diagram of a process for generating a dynamic conversion factor according to an embodiment of the present invention;

[0066] Figure 4 A functional module diagram of a solid-state hard disk storage performance optimization system based on load balancing provided by an embodiment of the present invention.

[0067] The realization of the purpose, functional features and advantages of the present invention will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0068] It should be understood that the specific embodiments described herein are only used to explain the present invention, and are not used to limit the present invention.

[0069] The embodiment of the present application provides a method for optimizing the storage performance of a solid-state hard disk based on load balancing. The execution subject of the method for optimizing the storage performance of a solid-state hard disk based on load balancing includes but is not limited to at least one of the electronic devices such as a server, a terminal, etc. that can be configured to execute the method provided by the embodiment of the present application. In other words, the method for optimizing the storage performance of a solid-state hard disk based on load balancing can be executed by software or hardware installed on a terminal device or a server device, and the software can be a blockchain platform. The server includes but is not limited to: a single server, a server cluster, a cloud server or a cloud server cluster, etc. The server can be an independent server, or it can be a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (Content Delivery Network, CDN), and big data and artificial intelligence platforms.

[0070] Reference Figure 1 FIG. 1 is a flow chart of a method for optimizing the storage performance of a solid-state hard disk based on load balancing provided by an embodiment of the present invention. In this embodiment, the method for optimizing the storage performance of a solid-state hard disk based on load balancing includes:

[0071] S1. Obtain a preset storage area of ​​a solid state hard disk, divide the storage area into distributed areas to obtain storage sub-areas, and extract a cache area corresponding to each storage sub-area.

[0072] In an embodiment of the present invention, the storage area refers to a specific part divided out of a solid state drive for storing files, applications or system data, wherein the information of the storage area can be obtained through a device manager or a command line tool based on the model and specifications of the solid state drive, that is, the block device information can be viewed using the lsblk command, and then detailed information can be obtained using the fdisk or parted command.

[0073] Furthermore, in order to be able to flexibly adjust the configuration of the storage area when storage requirements change and facilitate expansion or reduction, the storage area needs to be divided. By dividing the storage sub-areas, storage resources can be managed more effectively to ensure that high-priority tasks obtain the necessary storage performance without affecting the operation of other tasks.

[0074] In the embodiment of the present invention, the storage sub-area refers to a logical or physical storage area divided according to specific requirements (such as performance, capacity, access frequency, etc.) in a storage system.

[0075] In the embodiment of the present invention, the distributed division of the storage area to obtain storage sub-areas includes:

[0076] dividing the storage area into target storage areas according to a preset number of blocks;

[0077] Performing area identification on the target storage areas one by one to obtain target area identifications;

[0078] Perform horizontal division according to the target area identifier to obtain a horizontally divided area;

[0079] The horizontally divided areas are allocated distributed nodes one by one to obtain the storage sub-areas.

[0080] In detail, according to the preset number of custom blocks (such as 10, 100, 1000, etc.), the storage area is divided into multiple target storage areas, and a unique identifier is assigned to each target storage area, that is, sequential identification is performed from the first block to the last block after division, to ensure that subsequent operations can accurately identify and manage each area, and then according to the target area identification, each target storage area is horizontally divided to form multiple horizontally divided areas, so that each target storage area is horizontally arranged according to the order of the target area identification, and then each horizontally divided area is randomly assigned to different distributed storage nodes one by one, so as to obtain different storage sub-areas. When the first storage area is full, it will be stored in the second storage area, and the distributed storage areas will be stored in sequence. By distributing data to multiple storage areas, the risk of single point failure is reduced, the security of data is improved, and the storage load is reasonably distributed to avoid overload of a certain storage area, thereby improving the overall performance and response speed, and new storage areas can be flexibly added to meet the growing data storage needs.

[0081] Specifically, a corresponding cache area is allocated in each storage sub-area. The size of each cache area is determined according to the size and access mode of the storage sub-area, and there is consistency between the cache area and the storage sub-area. For example, a periodic refresh or real-time update method is adopted, wherein the cache API interface can be queried through the command line tool according to the identifier of the cache area, and then the cache area corresponding to each storage sub-area is obtained according to the API interface.

[0082] Furthermore, in order to evenly distribute each storage sub-area, it is necessary to classify resources based on the real-time number of write data requests. Therefore, it is necessary to obtain the write data requests of the cache area in each storage sub-area in real time, and then analyze the write data requests to achieve balanced storage of the storage area.

[0083] S2. Obtain data write requests from the cache area, calculate the similarity of the data write requests using a preset linear sliding algorithm, generate a write request queue corresponding to the data write requests based on the similarity, and detect the write request load of the write request queue through a preset time window.

[0084] In an embodiment of the present invention, the data write request is an instruction sent to a storage system such as a cache area or a storage area, and is used to store data to a specified key or location, including a key-value pair. The key is a name or identifier that uniquely identifies the data, and the stored data can be accessed in subsequent read requests. The value is the data to be stored, which can be a string, a number, an object, etc., wherein the data write request for the cache area can be obtained through a preset interceptor.

[0085] Furthermore, in order to improve storage efficiency, it is necessary to identify repeated or similar write requests to prevent data redundancy, which helps prevent duplicate data storage, saves storage space, and improves data management efficiency, thereby improving the overall performance of the storage system and reducing repeated operations.

[0086] In the embodiment of the present invention, the similarity refers to the similarity between two data writing requests.

[0087] In the embodiment of the present invention, the calculating the similarity of the data writing request by using a preset linear sliding algorithm includes:

[0088] Convert the data write request into a write string, and calculate a write hash value corresponding to the write string;

[0089] Determine the block point corresponding to the written hash value according to a preset block rule, and block the written hash value according to the block point to obtain the written block hash value, wherein the block rule is:

[0090]

[0091] in, Write the hash value The binary corresponding to the characters, For the default character binary, is the AND operator symbol, is the equality comparison operator;

[0092] The similarity of the data write request is calculated according to the write block hash value using the following linear sliding algorithm:

[0093]

[0094] in, Write request for data With data write request The similarity between is the total number of blocks for writing the block hash value, Write request for data Middle The linear coefficient of the hash value of the written block, Write request for data Middle The value written into the block hash value, Write request for data Middle The sliding coefficient of the hash value written to the block, Write request for data Middle The linear coefficient of the hash value of the written block, Write request for data Middle The value written into the block hash value, Write request for data Middle The sliding factor for writing block hash values.

[0095] In detail, all data write requests are converted into strings, that is, various parts of the request (such as field name, value, etc.) are concatenated in a certain format to represent the request content, that is, fields are separated by specific separators (such as commas and semicolons), organized in JSON format, and the strings are encoded (such as UTF-8) to ensure consistency between different systems, and the hash value of each converted string is calculated. The hash value is a fixed-length output obtained after the string is processed by a hash algorithm. The hash algorithm includes but is not limited to SHA-256. Using the SHA-256 algorithm, no matter how large the input data is, the output hash value is always 256 bits (32 bytes), that is, no matter how large or what the content of the input data is, the hash algorithm will generate a fixed-length hash value, which can quickly compare the similarity of data.

[0096] Specifically, the hash value generated by each data write request is divided into blocks, and each character in the hash value is compared with the preset character one by one. Only when the result of the bitwise AND operation of the binary and (m) of a certain character is zero, it is used as a block point, indicating that the specific character will be used as the basis for block division. For example, if the hash value is 2cf24dba5fb0a30e26e83, , then the block point corresponding to the hash value is the position corresponding to the character a, and the write hash value will be divided into several blocks according to the block point position, each block corresponds to a write block hash value, such as 2cf24dba5fb0a30e26e83 is divided into three write block hash values ​​2cf24dba, 5fb0a and 30e26e83, and the similarity of the data write request is calculated according to each write block hash value, that is, the ratio between the write block hash value and the total blocks is calculated using the linear sliding algorithm, where the similarity of the two data write requests is calculated only when the number of blocks of the two data write requests is the same, if the number of blocks of the two data write requests is different, they must be dissimilar, and the similarity is 0, and then the hash value corresponding to each block is linearly transformed, that is , and the linear coefficient The value of is the number of blocks, the sliding coefficient is the number of characters in the hash value of each block, and then the two data write requests are compared. If the hash values ​​of the two blocks are the same, the calculation result is 0, where The maximum value is 1, the minimum value is 0, and a value greater than 1 indicates dissimilarity, and only the number of similarities is counted.

[0097] For example, the hash value of data write request ① is 2cf24dba5fb0a30e26e83, and the hash value of data write request ② is 2cf24dba5fb0a30e26e83. The write block hash values ​​of data write request ① and data write request ② are 2cf24dba, 5fb0a, and 30e26e83, respectively. The linear coefficient value is 3, the sliding coefficient of 2cf24dba is 8, the sliding coefficient of 5fb0a is 5, and the sliding coefficient of 30e26e83 is 8. Each write block hash value is linearly converted and the converted values ​​are compared. The comparison values ​​of the three write block hash values ​​are all 0. At this time, , the similarity between data write request ① and data write request ② is 1, and as long as the similarity value between data write request ① and data write request ② is not 1, it means that the two are not similar.

[0098] Furthermore, a write request queue corresponding to the data write request is generated based on the similarity, that is, only one data write request with a similarity equal to 1 is retained; if the similarity between data write request ① and data write request ② is equal to 1, one data write request is retained arbitrarily and the other is deleted, and then a write request queue is generated in order from early to late according to the timestamps corresponding to the data write requests, wherein the write request queue refers to bringing multiple write requests together so that they can be processed in batches or executed one by one in a specific order to ensure the order and consistency of the operations.

[0099] Furthermore, it is necessary to analyze the storage load based on the write request queue, and then dynamically adjust the processing strategy according to the detected load conditions, such as increasing or decreasing concurrent write threads, adjusting the buffer size, etc., to improve processing efficiency.

[0100] In an embodiment of the present invention, the write request load refers to the overall load brought by the write request within a specific time window, reflecting the frequency and data volume of receiving and processing data write requests within a certain period of time, so as to reasonably allocate and optimize storage resources according to the load conditions.

[0101] In the embodiment of the present invention, refer to Figure 2 As shown, the detecting the write request load of the write request queue through a preset time window includes:

[0102] S21, comparing the timestamp corresponding to each write data request in the write request queue with the time window, and generating a target write request queue according to the compared write request data;

[0103] S22, counting the number of requests in the target write request queue, and counting the request size of each data write request according to the number of requests;

[0104] S23, calculating the write request load of the target write request queue according to the request quantity and the request size, wherein the write request load is:

[0105]

[0106] in, For the write request load, For the The request size of a write data request, is the number of requests, is the window size of the time window.

[0107] In detail, the timestamp of each request is extracted from the write request queue, and then the timestamp of each request is compared with the preset time window, the requests within the time window are screened out, and a target write request queue is generated, that is, the data write requests within the time window are composed of target write requests, and the data write requests that are not within the time window are temporarily put on hold. The time window is a fixed time period (such as 1 second, 5 seconds, etc.), and then the number of data write requests within the time window is counted, and the target write request queue is traversed to count the size of each request, so as to calculate the request load based on the number of requests and the request size.

[0108] Specifically, the total size of data write requests can be obtained by summing the sizes of all requests in the time window. The request load takes into account the number of requests and the total size, indicating the amount of data written per unit time, thereby determining the load of the storage area. For example, if 5 requests are received within the time window (T = 10) seconds, with sizes of 100 bytes, 200 bytes, 150 bytes, 250 bytes, and 300 bytes, respectively, then the load , so as to reasonably allocate and optimize storage resources according to the load conditions.

[0109] Furthermore, according to the real-time write request load, the configuration of the storage area can be dynamically adjusted to ensure efficient use of resources. For example, under high load conditions, the available read storage area is increased to cope with more read requests. Therefore, it is necessary to flexibly adjust according to the load conditions to adapt to different workload patterns.

[0110] S3. Generate a dynamic conversion factor of the read storage area in the storage sub-area according to the write request load, and calculate the storage weight of the write storage area in the storage sub-area by using a preset dual request weight algorithm.

[0111] In an embodiment of the present invention, the dynamic conversion factor refers to a parameter that is dynamically adjusted under specific conditions in order to optimize the management of storage resources and data writing efficiency. It is usually used to evaluate or change the allocation and processing strategy of data in the storage area, and dynamically adjust the use of resources according to the capacity and load of the current storage area to ensure efficient use of available storage space.

[0112] In the embodiment of the present invention, refer to Figure 3 As shown, generating a dynamic conversion factor for a read storage area in the storage sub-area according to the write request load includes:

[0113] S31, detecting the area capacity of the blank area in the read storage area;

[0114] S32, when the write request load is greater than the area capacity of the write storage area in the storage sub-area and the area capacity is greater than zero, determining the dynamic conversion factor as a preset first target conversion factor;

[0115] S33, when the write request load is greater than the area capacity of the write storage area in the storage sub-area and the area capacity is equal to zero, determining the dynamic conversion factor as a preset second target conversion factor;

[0116] S34: When the write request load is less than or equal to the area capacity of the write storage area in the storage sub-area, determine the dynamic conversion factor as a preset third target conversion factor.

[0117] In detail, the original storage sub-area is divided into a read area, a write area and a cache area, and the area capacity of the read area is obtained, and the available blank area capacity of the read storage area needs to be monitored in real time, wherein the read area and the blank area can be obtained through the command line, and then the area capacity of the read area and the blank area capacity can be obtained, and the capacity of each mount point can be displayed through the df -h command, including the used space and the available space.

[0118] Specifically, if the write request load is greater than the area capacity of the write storage area and the area capacity of the blank area is greater than 0, the dynamic conversion factor is set to the preset first target conversion factor (value 1), and the first target conversion factor means that the storage capacity of the write area corresponding to the write request load is full, and at this time the area capacity of the blank area corresponding to the read area is greater than zero, that is, the read area has an available area, then the read area is converted to the write area, and the first target conversion factor indicates that the read area is converted to the write area, which is suitable for high load conditions to ensure that write requests are processed first; if the write request load is greater than the area capacity of the write storage area and the area capacity of the blank area is equal to 0, the dynamic conversion factor is set to the preset second target conversion factor (value 2), and the first target conversion factor is set to the preset second target conversion factor (value 3). The second target conversion factor means that when the storage capacity of the write area corresponding to the write request load is full and the area capacity of the blank area corresponding to the read area is also full, it is necessary to call the recycling strategy for the write area and leave a blank area in the write area. The second target conversion factor indicates calling the recycling strategy and leaving a blank area in the write area. It is suitable for situations with extremely low available capacity and adopts a conservative strategy to avoid system overload. If the write request load is less than or equal to the area capacity of the write storage area, the dynamic conversion factor is set to the preset third target conversion factor (value 3). The third target conversion factor indicates that the write storage area at this time can store the data corresponding to the data request, and no transformation is required. Under normal load conditions, a stable read-write balance is maintained.

[0119] Furthermore, in order to achieve a more balanced load distribution, during the storage reclamation process, it is necessary to perform regional reclamation based on the storage weight of each block, thereby allocating write requests among different storage areas, reducing idle space, and improving the utilization efficiency of storage media.

[0120] In the embodiment of the present invention, the storage weight refers to the importance of each block area in the storage sub-area. Data is allocated to different storage areas according to the weight to optimize storage performance and resource utilization. Block areas with high frequency or large capacity requests will obtain higher weights, thereby optimizing the processing efficiency of these requests.

[0121] In the embodiment of the present invention, the calculation of the storage weight of the write storage area in the storage sub-area by using a preset dual request weight algorithm includes:

[0122] Counting the request frequency and request size of each block area in the write storage area;

[0123] Determining a dynamic frequency coefficient of the request frequency according to a dynamic change of the request frequency of the block area;

[0124] Determining a dynamic capacity coefficient of the request size according to a dynamic change of the request size of the block area;

[0125] The storage weight of each block area in the write storage area of ​​the storage sub-area is calculated according to the dynamic frequency coefficient and the dynamic capacity coefficient by using the following dual request weight algorithm:

[0126]

[0127] in, The write storage area is The storage weight of each block area, is the dynamic frequency coefficient, is the dynamic capacity coefficient, For the The request frequency of the block area, For the The requested size of the block area, is the area number of the block area in the write storage area.

[0128] In detail, monitor and record the request frequency and request size of each block area in the write storage area. Through the log system or monitoring tool, the information of each write request can be recorded in real time, including timestamp, request source, target block area, request size, etc., and the dynamic frequency coefficient can be calculated according to the dynamic changes of the request frequency of the block area. And calculate the dynamic capacity factor based on the dynamic changes in the request size of the block area , that is, when the capacity of the block area is full, then When the capacity of the block area is not full, the capacity coefficient is configured according to the increase in capacity. In the time window, for every increase of 100 bytes, the dynamic capacity coefficient increases by 1%, and for every increase of 200 bytes, the dynamic capacity coefficient is 2%; in the time window, for every increase in the number of accesses to the data in the block area, the dynamic frequency coefficient increases by 1%. For example, if the initial capacity coefficient is 1.0 and the initial frequency coefficient is 1.0, if the block area increases by 250 bytes in a time window, the dynamic capacity coefficient is , if the number of write requests to a block area in a time window is 5, then the dynamic frequency coefficient is , thereby calculating the storage weight of each block based on the dynamic capacity coefficient and the dynamic frequency coefficient.

[0129] Specifically, the dual request weight algorithm is used to calculate the storage weight of each block area. The dual request weight calculates the storage weight according to the request frequency and request size, and the calculated weight is normalized to ensure that the sum of the weights of all block areas is 1, which is convenient for subsequent load balancing and resource allocation. The storage weight is recalculated regularly (such as at regular intervals or when specific events occur) to adapt to changing request patterns and storage requirements. This can achieve effective management of each block area in the write storage area, ensuring efficient resource utilization and system performance optimization.

[0130] Furthermore, by dynamically adjusting the capacity factor and frequency factor, storage resources can be allocated more efficiently, ensuring that areas with high frequency and high capacity requirements have sufficient storage space and avoiding resource waste. The dynamic adjustment factor enables the system to intelligently distribute the load according to actual usage, avoiding overload in certain areas while ensuring the efficiency of other areas.

[0131] S4. Adjust the write storage area in the storage sub-area according to the dynamic conversion factor and the storage weight, and generate an update sub-area corresponding to the storage sub-area according to the adjusted write storage area.

[0132] In the embodiment of the present invention, by taking different values ​​of the dynamic conversion factor, the writing and reading strategies of the storage sub-areas can be flexibly adjusted to cope with different load conditions, thereby improving the efficiency of the storage system, enhancing resource utilization, and ensuring high-performance data processing capabilities.

[0133] In the embodiment of the present invention, adjusting the write storage area in the storage sub-area according to the dynamic conversion factor and the storage weight includes:

[0134] When the dynamic conversion factor is the first target conversion factor, converting the read area in the storage sub-area into a write area, and splicing the write area with the write storage area in the storage sub-area to obtain an adjusted write storage area;

[0135] When the dynamic conversion factor is the second target conversion factor, reclaiming the write storage area in the storage sub-area by using the storage weight to obtain a reclaimed area, and determining an adjusted write storage area according to the reclaimed area;

[0136] When the dynamic conversion factor is the third target conversion factor, the original write storage area in the storage sub-area is determined as the adjusted write storage area.

[0137] In detail, when the dynamic conversion factor is the first target conversion factor, that is, at this time, the read area in the storage sub-area needs to be converted into a write area, and the write area is spliced, and the data corresponding to the read area in the storage sub-area is migrated to the preset backup area, and the read area is converted into a write area to increase the available write space, thereby meeting high write requirements, and by splicing the write area, a larger continuous write storage area is formed, which improves the write performance, reduces fragmentation, and facilitates efficient data writing; when the dynamic conversion factor is the second target conversion factor, the write storage area is regionally reclaimed using the storage weight, and the data in the block area with a smaller storage weight is reclaimed to leave a blank area for data storage That is, when the write demand weakens or the storage space is insufficient, the storage weight is used to evaluate which areas can be reclaimed, and the inactive or redundant write storage areas are reclaimed to release space for new write requests. After the reclaim, the new write storage area is re-determined according to the size and position of the reclaimed area to ensure the write efficiency and space optimization; when the dynamic conversion factor is the third target conversion factor, the original write storage area is directly used as the adjusted write storage area, that is, when it is judged that the current write storage area has adapted to the load demand and there is no obvious performance problem, the original area is directly retained, which can reduce unnecessary resource reallocation under stable load, avoid excessive adjustment of the system, and improve stability and efficiency.

[0138] Furthermore, by taking different values ​​of the dynamic conversion factor, the writing and reading strategies of the storage sub-areas can be flexibly adjusted to cope with different load conditions, thereby regenerating the data storage area based on the adjusted writing area to achieve load balancing of the storage area.

[0139] In the embodiment of the present invention, the update sub-region refers to a region after the original storage sub-region is updated to improve data processing efficiency.

[0140] In the embodiment of the present invention, generating the update sub-region corresponding to the storage sub-region according to the adjusted write storage region includes:

[0141] determining an adjusted read storage area according to the adjusted write storage area;

[0142] Optimize the pre-acquired data storage mapping table corresponding to the storage sub-area according to the adjusted write storage area and the adjusted read storage area;

[0143] The storage sub-region is updated by using the optimized data storage mapping table to obtain an updated sub-region.

[0144] In detail, according to the adjusted write storage area, the current data access mode is analyzed, and the corresponding read storage area is determined to ensure the balance between the read operation and the write operation. According to the latest write data, the read storage area is dynamically adjusted to quickly respond to the read request. In combination with the adjusted write storage area and read storage area, the data storage mapping table corresponding to the pre-acquired storage sub-area is optimized, and the data storage address and the data are mapped and optimized to determine the adjusted data storage address. According to the frequency of use and access mode of the data, the mapping relationship is rearranged and updated. By optimizing the mapping table, the data access efficiency can be improved and the data positioning can be ensured to be more accurate. Then, the optimized data storage mapping table is used to update the storage sub-area and generate an updated sub-area to ensure that the data in the storage sub-area is always kept up to date. Through the precise mapping relationship, the data is quickly located and updated, thereby improving the overall storage performance.

[0145] Furthermore, generating updated sub-areas not only improves data consistency and storage efficiency, but also optimizes the overall performance of the system. This dynamic adjustment and optimization mechanism provides the storage system with better flexibility and responsiveness, and writing data once based on the updated storage area can significantly reduce the response time of each request and improve the response speed of data storage.

[0146] S5. Write the write data corresponding to the data write requests in the write request queue into the update sub-area in batches, detect the storage performance optimization factor of the update sub-area after writing, and determine the optimization state of the solid state drive according to the storage performance optimization factor.

[0147] In an embodiment of the present invention, batch writing can reduce the overhead of each write operation, reduce the context switching and resource usage of the system when processing multiple separate write requests, and batch writing in the update sub-area can ensure that multiple related data are updated at the same time, reducing the risk of data inconsistency caused by multiple writes.

[0148] In the embodiment of the present invention, the step of writing the write data corresponding to the data write requests in the write request queue into the update sub-area in batches includes:

[0149] Detecting a dynamic conversion factor corresponding to the write request queue;

[0150] When the dynamic conversion factor is a preset first target conversion factor and a third target conversion factor, writing the write data corresponding to the data write request in the write request queue into the update sub-area at one time;

[0151] When the dynamic conversion factor is a preset second target conversion factor and the adjusted write area corresponding to the second target conversion factor is smaller than the requested storage capacity in the write request queue, dividing the data write requests in the write request queue to obtain data write request segments;

[0152] Refreshing the update sub-area according to a preset request waiting time;

[0153] The write data corresponding to the data write request segment is written in batches into the refreshed update sub-area.

[0154] In detail, the dynamic conversion factor previously determined by the write request queue is monitored. When the dynamic conversion factor is equal to the first target conversion factor and the third target conversion factor, the data in the entire write request queue is written to the update sub-area at one time; when the dynamic conversion factor is equal to the second target conversion factor, it is necessary to check whether the adjusted write area size is smaller than the requested storage capacity of the write request queue. If so, it means that the currently available write space is limited, and the data in the write request queue will be divided to form multiple data write request segments. Each request segment will be adjusted according to the currently available storage space and the size of the request to ensure that it does not exceed the capacity limit of the update sub-area. Before processing these request segments, the update sub-area is refreshed according to the preset request waiting time, which means that before writing new data, the update sub-area is ensured to be in the latest state to reduce the risk of data conflicts or inconsistencies.

[0155] Specifically, batch writing of divided data write request segments into the refreshed update sub-areas helps to improve efficiency, reduce write latency, and ensure data consistency, thereby optimizing the way data is written by dynamically detecting and processing write requests, and being able to intelligently adjust write strategies under different load and storage conditions to improve system performance and stability.

[0156] Furthermore, after writing data to the updated storage area, it is also necessary to monitor the storage performance of the adjusted storage area to evaluate the storage performance of the adjusted SSD. Monitoring the storage performance after writing can provide real-time feedback, allowing the system to dynamically adjust the storage configuration according to the current performance, such as modifying the data distribution or caching strategy to adapt to the changing workload.

[0157] In an embodiment of the present invention, the storage performance optimization factor is an indicator used to evaluate and quantify the degree of improvement in storage system performance. It helps to determine the performance changes of the storage system after a specific operation (such as data writing or updating) by comparing the updated performance indicator with the original performance indicator.

[0158] In the embodiment of the present invention, the storage performance optimization factor of the updated sub-area after the detection of writing includes:

[0159] Acquire an update performance indicator of the update sub-region and an original performance indicator of the storage sub-region;

[0160] The storage performance optimization factor is calculated according to the updated performance index and the original performance index, wherein the storage performance optimization factor is:

[0161]

[0162] in, is the storage performance optimization factor, The update performance indicator The indicator value of is the index in the original performance index The indicator value.

[0163] In detail, the update performance indicators and the original performance indicators include read performance indicators (such as read throughput or latency), write performance indicators (such as write throughput or latency), space utilization (ratio of actual used space to total space), cache hit rate, and fragmentation rate (fragmentation degree of storage area), wherein the total amount of data and time consumed in writing can be monitored to calculate the corresponding throughput and latency, and then the actual used space and total space can be obtained by using storage management tools or command line tools (such as df command in Linux system), space utilization = actual used space / total space × 100%; the number of cache hits and the total number of requests can be obtained by monitoring the statistical data of cache management software or storage controller, cache hit rate = cache hit number / total number of requests × 100%; the fragmentation rate can be calculated by checking the usage and continuity of storage blocks, and can be expressed as the ratio of the number of fragmented blocks to the total number of blocks.

[0164] Specifically, if the updated performance indicator is better than the original indicator, the optimization factor is 1, indicating that the performance has been significantly improved; if there is at least one updated indicator that exceeds the original indicator, the optimization factor is 0.5, indicating that there is a certain degree of optimization; if there is no improvement in the updated performance, the optimization factor is 0, indicating that the performance has not improved, and then the optimization state of the solid-state drive is determined according to the storage performance optimization factor. When the optimization factor is 1, it indicates that the optimization state is the best state, all performance indicators are within the ideal range, and the solid-state drive runs efficiently and healthily; when the optimization factor is 0.5, it indicates that the optimization state is a medium state; when the optimization factor is 0, it indicates that the optimization state is the worst state.

[0165] The embodiments of the present invention can effectively improve the access efficiency of data and the flexibility of storage management by dividing the storage area into distributed areas, while reducing the risk of data loss; by analyzing the similarity of write requests, the storage method of data can be optimized, random writes can be reduced, and write efficiency can be improved; dynamic monitoring of the load of write requests is helpful to adjust the storage strategy in real time; dynamically adjusting the read-write ratio according to the load of write requests can better meet the performance requirements under different workloads; through the dual request weight algorithm, the write priority of the storage area can be reasonably allocated to improve the write performance and data consistency; adjusting the write storage area according to actual needs can optimize the utilization of storage resources; regularly detecting the storage performance optimization factor to ensure that the storage area is always in the best operating state. Therefore, the solid-state hard disk storage performance optimization method and system based on load balancing proposed by the present invention can solve the problem of low accuracy when optimizing the storage performance of solid-state hard disks.

[0166] like Figure 4 , which is a functional module diagram of a solid-state hard disk storage performance optimization system based on load balancing provided by an embodiment of the present invention.

[0167] The solid state disk storage performance optimization system 100 based on load balancing of the present invention can be installed in an electronic device. According to the functions implemented, the solid state disk storage performance optimization system 100 based on load balancing can include a storage area division module 101, a write request load detection module 102, a storage weight calculation module 103, an update sub-area generation module 104 and a storage optimization state determination module 105. The module of the present invention can also be called a unit, which refers to a series of computer program segments that can be executed by an electronic device processor and can complete fixed functions, which are stored in the memory of the electronic device.

[0168] In this embodiment, the functions of each module / unit are as follows:

[0169] The storage area division module 101 is used to obtain a preset storage area of ​​the solid state hard disk, divide the storage area into distributed areas to obtain storage sub-areas, and extract a cache area corresponding to each storage sub-area;

[0170] The write request load detection module 102 is used to obtain the data write request of the cache area, calculate the similarity of the data write request by using a preset linear sliding algorithm, generate a write request queue corresponding to the data write request according to the similarity, and detect the write request load of the write request queue through a preset time window;

[0171] The storage weight calculation module 103 is used to generate a dynamic conversion factor of the read storage area in the storage sub-area according to the write request load, and calculate the storage weight of the write storage area in the storage sub-area by a preset dual request weight algorithm;

[0172] The update sub-region generating module 104 is used to adjust the write storage region in the storage sub-region according to the dynamic conversion factor and the storage weight, and generate an update sub-region corresponding to the storage sub-region according to the adjusted write storage region;

[0173] The storage optimization status determination module 105 is used to batch write the write data corresponding to the data write requests in the write request queue into the update sub-area, and detect the storage performance optimization factor of the update sub-area after writing, and determine the optimization status of the solid state drive according to the storage performance optimization factor.

[0174] In detail, each module described in the load balancing-based solid-state hard disk storage performance optimization system 100 in the embodiment of the present invention is used in the same manner as described above. Figures 1 to 3 The same technical means as the solid-state hard disk storage performance optimization method based on load balancing described in the above are used and can produce the same technical effects, which will not be repeated here.

[0175] In the several embodiments provided by the present invention, it should be understood that the disclosed systems and methods can be implemented in other ways. For example, the system embodiments described above are only illustrative, for example, the division of the modules is only a logical function division, and there may be other division methods in actual implementation.

[0176] The modules described as separate components may or may not be physically separated, and the components shown as modules may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0177] In addition, each functional module in each embodiment of the present invention may be integrated into one processing unit, each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of hardware plus software functional modules.

[0178] It is obvious to those skilled in the art that the present invention is not limited to the details of the above exemplary embodiments, and that the present invention can be implemented in other specific forms without departing from the spirit or essential characteristics of the present invention.

[0179] Therefore, no matter from which point of view, the embodiments should be regarded as illustrative and non-restrictive, and the scope of the present invention is not limited only according to the above description, and it is intended that all changes within the meaning and scope of equivalent elements within the scope of protection are included in the present invention.

[0180] The embodiments of the present application can acquire and process relevant data based on artificial intelligence technology. Artificial Intelligence (AI) is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results.

[0181] In addition, it is clear that the word "comprising" does not exclude other units or steps, and the singular does not exclude the plural. Multiple units or systems stated in a system claim can also be implemented by one unit or system through software or hardware. The words first, second, etc. are used to indicate names, and do not indicate any particular order.

[0182] Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical solution of the present invention can be modified or replaced by equivalents without departing from the spirit and scope of the technical solution of the present invention.

Claims

1. A method for optimizing storage performance of a solid state drive based on load balancing, characterized in that: The method comprises: Obtain a preset storage area of ​​the solid-state hard disk, divide the storage area into distributed areas to obtain storage sub-areas, and extract a cache area corresponding to each storage sub-area; Obtaining a data write request for the cache area, and calculating the similarity of the data write request using a preset linear sliding algorithm, including: converting the data write request into a write string, and calculating a write hash value corresponding to the write string; determining a block point corresponding to the write hash value according to a preset block rule, and dividing the write hash value into blocks according to the block point to obtain a write block hash value, wherein the block rule is: in, Write the hash value The binary corresponding to the characters, For the default character binary, is the AND operator symbol, is the equality comparison operator; The similarity of the data write request is calculated according to the write block hash value using the following linear sliding algorithm: in, Write request for data With data write request The similarity between is the total number of blocks for writing the block hash value, Write request for data Middle The linear coefficient of the hash value of the written block, Write request for data Middle The value written into the block hash value, Write request for data Middle The sliding coefficient of the hash value written to the block, Write request for data Middle The linear coefficient of the hash value of the written block, Write request for data Middle The value written into the block hash value, Write request for data Middle The sliding coefficient of the hash value written into the block; generating a write request queue corresponding to the data write request according to the similarity, and detecting a write request load of the write request queue through a preset time window; Generating a dynamic conversion factor of the read storage area in the storage sub-area according to the write request load, including: detecting the area capacity of the blank area in the read storage area; when the write request load is greater than the area capacity of the write storage area in the storage sub-area and the area capacity is greater than zero, determining the dynamic conversion factor as a preset first target conversion factor; when the write request load is greater than the area capacity of the write storage area in the storage sub-area and the area capacity is equal to zero, determining the dynamic conversion factor as a preset second target conversion factor; when the write request load is less than or equal to the area capacity of the write storage area in the storage sub-area, determining the dynamic conversion factor as a preset third target conversion factor, and calculating the storage weight of the write storage area in the storage sub-area by a preset dual request weight algorithm; The write storage area in the storage sub-area is adjusted according to the dynamic conversion factor and the storage weight, including: when the dynamic conversion factor is the first target conversion factor, converting the read area in the storage sub-area into a write area, splicing the write area with the write storage area in the storage sub-area to obtain an adjusted write storage area; when the dynamic conversion factor is the second target conversion factor, using the storage weight to reclaim the write storage area in the storage sub-area to obtain a reclaimed area, and determining the adjusted write storage area according to the reclaimed area; when the dynamic conversion factor is the third target conversion factor, determining the original write storage area in the storage sub-area as the adjusted write storage area, and generating an update sub-area corresponding to the storage sub-area according to the adjusted write storage area; The write data corresponding to the data write requests in the write request queue are written into the update sub-area in batches, and the storage performance optimization factor of the update sub-area after writing is detected, and the optimization state of the solid state drive is determined according to the storage performance optimization factor.

2. The method for optimizing the storage performance of a solid state drive based on load balancing according to claim 1, characterized in that: The detecting the write request load of the write request queue through a preset time window includes: Comparing the timestamp corresponding to each write data request in the write request queue with the time window, and generating a target write request queue according to the compared write request data; Counting the number of requests in the target write request queue, and counting the request size of each data write request based on the number of requests; The write request load of the target write request queue is calculated according to the request quantity and the request size, wherein the write request load is: in, For the write request load, For the The request size of a write data request, is the number of requests, is the window size of the time window.

3. The method for optimizing the storage performance of a solid state drive based on load balancing according to claim 1, characterized in that: The calculating the storage weight of the write storage area in the storage sub-area by using a preset dual request weight algorithm includes: Counting the request frequency and request size of each block area in the write storage area; Determining a dynamic frequency coefficient of the request frequency according to a dynamic change of the request frequency of the block area; Determining a dynamic capacity coefficient of the request size according to a dynamic change of the request size of the block area; The storage weight of each block area in the write storage area of ​​the storage sub-area is calculated according to the dynamic frequency coefficient and the dynamic capacity coefficient by using the following dual request weight algorithm: in, The write storage area is The storage weight of each block area, is the dynamic frequency coefficient, is the dynamic capacity coefficient, For the The request frequency of the block area, For the The requested size of the block area, is the area number of the block area in the write storage area.

4. The method for optimizing the storage performance of a solid state drive based on load balancing according to claim 1, characterized in that: The step of generating an update sub-region corresponding to the storage sub-region according to the adjusted write storage region includes: determining an adjusted read storage area according to the adjusted write storage area; Optimizing the pre-acquired data storage mapping table corresponding to the storage sub-area according to the adjusted write storage area and the adjusted read storage area; The storage sub-region is updated by using the optimized data storage mapping table to obtain an updated sub-region.

5. The method for optimizing the storage performance of a solid state drive based on load balancing according to claim 1, characterized in that: The step of batch-writing the write data corresponding to the data write requests in the write request queue into the update sub-area includes: Detecting a dynamic conversion factor corresponding to the write request queue; When the dynamic conversion factor is a preset first target conversion factor and a third target conversion factor, writing the write data corresponding to the data write request in the write request queue into the update sub-area at one time; When the dynamic conversion factor is a preset second target conversion factor and the adjusted write area corresponding to the second target conversion factor is smaller than the requested storage capacity in the write request queue, dividing the data write requests in the write request queue to obtain data write request segments; Refreshing the update sub-area according to a preset request waiting time; The write data corresponding to the data write request segment is written in batches into the refreshed update sub-area.

6. The method for optimizing the storage performance of a solid state drive based on load balancing according to claim 1, characterized in that: The storage performance optimization factor of the updated sub-area after the detection of writing includes: Acquire an update performance indicator of the update sub-region and an original performance indicator of the storage sub-region; The storage performance optimization factor is calculated according to the updated performance index and the original performance index, wherein the storage performance optimization factor is: in, is the storage performance optimization factor, The update performance indicator The indicator value of The original performance index The indicator value.

7. A solid state hard disk storage performance optimization system based on load balancing, characterized in that: Used to execute the method for optimizing the storage performance of a solid-state hard disk based on load balancing according to any one of claims 1 to 6, the system comprising: A storage area division module is used to obtain a preset storage area of ​​the solid state hard disk, divide the storage area into distributed areas to obtain storage sub-areas, and extract a cache area corresponding to each storage sub-area; A write request load detection module is used to obtain the data write request of the cache area, and calculate the similarity of the data write request using a preset linear sliding algorithm, including: converting the data write request into a write string, and calculating the write hash value corresponding to the write string; determining the block point corresponding to the write hash value according to a preset block rule, and blocking the write hash value according to the block point to obtain the write block hash value, wherein the block rule is: in, Write the hash value The binary corresponding to the characters, For the default character binary, is the AND operator symbol, is the equality comparison operator; The similarity of the data write request is calculated according to the write block hash value using the following linear sliding algorithm: in, Write request for data With data write request The similarity between is the total number of blocks for writing the block hash value, Write request for data Middle The linear coefficient of the hash value of the written block, Write request for data Middle The value written into the block hash value, Write request for data Middle The sliding coefficient of the hash value written to the block, Write request for data Middle The linear coefficient of the hash value of the written block, Write request for data Middle The value written into the block hash value, Write request for data Middle The sliding coefficient of the hash value written into the block; generating a write request queue corresponding to the data write request according to the similarity, and detecting a write request load of the write request queue through a preset time window; A storage weight calculation module, used to generate a dynamic conversion factor of the read storage area in the storage sub-area according to the write request load, including: detecting the area capacity of the blank area in the read storage area; when the write request load is greater than the area capacity of the write storage area in the storage sub-area and the area capacity is greater than zero, determining the dynamic conversion factor as a preset first target conversion factor; when the write request load is greater than the area capacity of the write storage area in the storage sub-area and the area capacity is equal to zero, determining the dynamic conversion factor as a preset second target conversion factor; when the write request load is less than or equal to the area capacity of the write storage area in the storage sub-area, determining the dynamic conversion factor as a preset third target conversion factor, and calculating the storage weight of the write storage area in the storage sub-area by a preset dual request weight algorithm; An update sub-region generation module, used for adjusting the write storage region in the storage sub-region according to the dynamic conversion factor and the storage weight, including: when the dynamic conversion factor is the first target conversion factor, converting the read region in the storage sub-region into a write region, splicing the write storage region with the write storage region in the storage sub-region to obtain an adjusted write storage region; when the dynamic conversion factor is the second target conversion factor, using the storage weight to reclaim the write storage region in the storage sub-region to obtain a reclaimed region, and determining the adjusted write storage region according to the reclaimed region; when the dynamic conversion factor is the third target conversion factor, determining the original write storage region in the storage sub-region as the adjusted write storage region, and generating an update sub-region corresponding to the storage sub-region according to the adjusted write storage region; A storage optimization status determination module is used to batch write the write data corresponding to the data write requests in the write request queue into the update sub-area, and detect the storage performance optimization factor of the update sub-area after writing, and determine the optimization status of the solid-state drive according to the storage performance optimization factor.

Citation Information

Patent Citations

  • Data distribution method for decentralized distributed heterogeneous storage system

    CN109196459A

  • Intelligent data storage management method and device

    CN109783019A