CN112148221B - Method, device, equipment and storage medium for inspecting redundant array of inexpensive disks - Google Patents

Method, device, equipment and storage medium for inspecting redundant array of inexpensive disks Download PDF

Info

Publication number
CN112148221B
CN112148221B CN202010986784.5A CN202010986784A CN112148221B CN 112148221 B CN112148221 B CN 112148221B CN 202010986784 A CN202010986784 A CN 202010986784A CN 112148221 B CN112148221 B CN 112148221B
Authority
CN
China
Prior art keywords
information
write
patrol
stripe
strip
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010986784.5A
Other languages
Chinese (zh)
Other versions
CN112148221A (en
Inventor
刘丹
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Inspur Data Technology Co Ltd
Original Assignee
Beijing Inspur Data Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Inspur Data Technology Co Ltd filed Critical Beijing Inspur Data Technology Co Ltd
Priority to CN202010986784.5A priority Critical patent/CN112148221B/en
Publication of CN112148221A publication Critical patent/CN112148221A/en
Application granted granted Critical
Publication of CN112148221B publication Critical patent/CN112148221B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0614Improving the reliability of storage systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0653Monitoring storage devices or systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/0671In-line storage system
    • G06F3/0683Plurality of storage devices
    • G06F3/0689Disk arrays, e.g. RAID, JBOD

Abstract

The invention discloses a method, a device, equipment and a computer readable storage medium for inspecting a redundant array of a disk, wherein the method comprises the following steps: after the execution of the write request sent by the client is completed, obtaining the stripe information corresponding to the write request; writing the stripe information into a write patrol circular queue; the write inspection circular queue is a data structure of last-in first-out; obtaining target strip information from the write inspection circular queue, and performing data consistency inspection on strips corresponding to the target strip information; according to the invention, the stripe information which is written in by the latest finishing data is written in the write inspection circulating queue, the data structure is utilized as the write inspection circulating queue which is the last-in first-out, so that the latest inspected data is ensured to be the latest written data, and the instantaneity of data inspection is improved; and by utilizing the cycle characteristic of the write patrol loop queue, old strip information can be circularly covered, and the latest strip information can be kept stored, so that the sampling patrol function is realized when the data writing speed is higher than the patrol speed.

Description

Method, device, equipment and storage medium for inspecting redundant array of inexpensive disks
Technical Field
The present invention relates to the field of storage systems, and in particular, to a method, an apparatus, a device, and a computer readable storage medium for inspecting a redundant array of inexpensive disks.
Background
With the year-by-year expansion of storage systems, disk array (Redundant Arrays of Independent Disks, RAID, i.e., redundant array of disks) technology improves the throughput of the storage systems by a data striping technique, and improves the reliability of the storage systems by a data redundancy technique. Disk array technology is now becoming a common means of guaranteeing large-scale storage, and is commonly found in various management systems that need to store large-scale data. However, due to the large number of disks required to form the disk array, over time, the disks also have silence or sector damage caused by reduced magnetic properties and damaged media, and RAID inspection is required to be performed periodically to isolate and repair bad sectors in time.
At present, the capacity of a disk supported by RAID is larger and larger, so as to reduce the influence on normal business, the patrol task is generally used as a background task with lower priority, and the patrol is performed according to a certain spatial sequence, and the period is generally counted in days. The problem with such inspection is that the inspection cycle is relatively long, and the strip that has just been inspected needs to wait for the next inspection cycle before being inspected again. For the data which is written frequently recently, the data can be inspected for a long time, and even a period of inspection is needed, so that the inspection loses the capability of real-time detection, and the inspection effect is greatly reduced.
Therefore, how to provide a method for rapidly checking the latest writing, which improves the real-time performance of data inspection, further enhances the active detection capability of the storage system, and improves the reliability of the storage system is an urgent problem to be solved nowadays.
Disclosure of Invention
The invention aims to provide a method, a device, equipment and a computer readable storage medium for inspecting a redundant array of a disk, so as to improve the real-time performance of data inspection, further enhance the active detection capability of a storage system and improve the reliability of the storage system.
In order to solve the above technical problems, the present invention provides a method for inspecting a redundant array of inexpensive disks, including:
after the execution of a write request sent by a client is completed, obtaining stripe information corresponding to the write request;
writing the strip information into a write patrol circular queue; the write patrol circular queue is of a last-in first-out data structure, and the write patrol circular queue stores the preset quantity of strip information at most;
acquiring target strip information from the write inspection circular queue, and performing data consistency inspection on strips corresponding to the target strip information; the target strip information is the preset number of strip information written in the write patrol loop queue.
Optionally, the writing the stripe information to a write patrol loop queue includes:
writing the stripe information into the write patrol circular queue according to the data write completion sequence corresponding to the stripe information; the first stripe information is written into the write patrol circular queue before the second stripe information, the first stripe information is any stripe information, and the second stripe information is any stripe information with the data writing completion time later than that of the first stripe information.
Optionally, the writing the stripe information into the write patrol loop queue according to the data write completion sequence corresponding to the stripe information includes:
if the write patrol circular queue already stores the preset quantity of the strip information, the current strip information is written into the tail of the write patrol circular queue in a covering mode, and the head mark of the write patrol circular queue is updated, so that the current strip information is located at the head of the write patrol circular queue; the current strip information is any strip information.
Optionally, the method further comprises:
acquiring special band information;
suspending execution of the write request and writing the special stripe information to a write patrol loop queue.
Optionally, the method further comprises:
and after the special stripe information is obtained from the write patrol loop queue and the data consistency check is carried out on the stripe corresponding to the special stripe information, the write request is restored to be executed.
Optionally, the acquiring the special band information includes:
after detecting a repaired first target strip, obtaining strip information of the first target strip; the special band information comprises band information of the first target band, and the first target band is a band with data inconsistency determined by inspection.
Optionally, the acquiring the special band information includes:
after a second target strip is detected, strip information of the second target strip is obtained; the special stripe information comprises stripe information of the second target stripe, and the second target stripe is a stripe which is temporarily offline from a disk when writing data of a corresponding write request.
The invention also provides a patrol device of the redundant array of inexpensive disks, comprising:
the acquisition module is used for acquiring the stripe information corresponding to the write request after the write request sent by the client is executed;
the writing module is used for writing the strip information into a write patrol circular queue; the write patrol circular queue is of a last-in first-out data structure, and the write patrol circular queue stores the preset quantity of strip information at most;
the inspection module is used for acquiring target strip information from the write inspection circular queue and carrying out data consistency inspection on strips corresponding to the target strip information; the target strip information is the preset number of strip information written in the write patrol loop queue.
The invention also provides a patrol equipment of the disk redundant array, which comprises:
a memory for storing a computer program;
and the processor is used for realizing the steps of the inspection method of the redundant array of inexpensive disks when executing the computer program.
In addition, the invention also provides a computer readable storage medium, wherein the computer readable storage medium stores a computer program, and the computer program realizes the steps of the inspection method of the redundant array of magnetic disks when being executed by a processor.
The invention provides a method for inspecting a redundant array of inexpensive disks, which comprises the following steps: after the execution of the write request sent by the client is completed, obtaining the stripe information corresponding to the write request; writing the stripe information into a write patrol circular queue; the write inspection circular queue is of a last-in first-out data structure, and the write inspection circular queue stores the strip information of the preset quantity at most; obtaining target strip information from the write inspection circular queue, and performing data consistency inspection on strips corresponding to the target strip information; the target strip information is the preset quantity of strip information written after the target strip information is written into the inspection circular queue;
therefore, the stripe information which is written into the data is written into the write-patrol circular queue, the data structure is utilized to ensure that the data which is first-in and first-out is the data which is written into the data recently, and the instantaneity of data patrol is improved; and by utilizing the circulation characteristic of the write patrol loop queue, old strip information can be circularly covered, and stored strip information is kept up to date, so that the sampling patrol function is realized when the data writing speed is high and the patrol speed is high, the active detection capability of the storage system is further enhanced, and the reliability of the storage system is improved. In addition, the invention also provides a patrol device, equipment and a computer readable storage medium of the redundant array of inexpensive disks, which have the same beneficial effects.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings that are required to be used in the embodiments or the description of the prior art will be briefly described below, and it is obvious that the drawings in the following description are only embodiments of the present invention, and that other drawings can be obtained according to the provided drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flowchart of a method for inspecting a redundant array of inexpensive disks according to an embodiment of the present invention;
fig. 2 is a schematic diagram of an inspection principle of an inspection method for a redundant array of inexpensive disks according to an embodiment of the present invention;
FIG. 3 is a block diagram illustrating a patrol device for redundant array of inexpensive disks according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of an inspection apparatus for a redundant array of inexpensive disks according to an embodiment of the present invention.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention, and it is apparent that the described embodiments are some embodiments of the present invention, but not all embodiments of the present invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
Referring to fig. 1, fig. 1 is a flowchart of a method for inspecting a redundant array of inexpensive disks according to an embodiment of the present invention. The method may include:
step 101: and after the write request sent by the client is executed, acquiring the stripe information corresponding to the write request.
The write request in this step may be a request for writing data sent by a client (client) of a storage system (e.g. a server) to the storage system, and accordingly, the storage system may execute the write request (i.e. execute service IO) to write the data corresponding to the write request in a stripe corresponding to the redundant array of disks (i.e. the disk array). The stripe information in this step may be information of a stripe in which data corresponding to the write request is written; for the specific content of the stripe information, the designer may set the stripe information as a stripe number, so long as the processor of the storage system can determine the stripe of the data corresponding to the write request by using the stripe information corresponding to the write request, which is not limited in this embodiment.
It may be understood that the purpose of this step may be that, after the processor of the storage system performs the write request sent by the client, the processor obtains stripe information corresponding to the performed write request, that is, information of a stripe of data corresponding to the write request.
Specifically, for the specific mode of acquiring the stripe information corresponding to the write request after the execution of the write request sent by the client by the processor in this step, the designer may set the specific mode according to the practical scenario and the user requirement, for example, the processor may acquire the stripe information corresponding to the stripe as the stripe information corresponding to the write request after the stripe writes the data corresponding to the write request. The processor may also determine stripe information corresponding to each write request (i.e. information of a stripe to which data of the write request needs to be written) after receiving the write request sent by the client, and obtain stripe information corresponding to the write request after execution of the write request is completed later; that is, this step may be preceded by a step of determining stripe information corresponding to the write request sent by the client. The embodiment does not limit the execution of the write request, as long as the processor can obtain the stripe information corresponding to the write request after the execution of the write request sent by the completion client.
Step 102: writing the stripe information into a write patrol circular queue; the write patrol cycle queue is of a last-in first-out data structure, and the write patrol cycle queue stores the preset quantity of strip information at most.
The write patrol circular queue in this step may be a LIFO (last in first out ) circular queue for storing stripe information in a last in first out data structure; specifically, the maximum length of the queue of the write-patrol circular queue may be M (e.g. 2000), that is, the write-patrol circular queue may store at most a preset number (M) of stripe information, and when the number of stripe information written in the write-patrol circular queue reaches the preset number, if the stripe information is written in the write-patrol circular queue, the write-patrol circular queue is circularly covered, that is, the stripe information written in the write-patrol circular queue earliest starts to be covered, so that the stripe information in the write-patrol circular queue is kept to be updated preset number of stripe information.
It can be understood that the purpose of this step may be that the processor updates the write-patrol circular queue by writing the currently acquired stripe information into the write-patrol circular queue, and since the write-patrol circular queue has the characteristics of a last-in first-out, the latest written stripe information can be preferentially fetched from the write-patrol circular queue during patrol, and at this time, the time distance between patrol and the write-in data of the client is shorter, and the requirement of real-time patrol can be basically approached.
Specifically, since the write patrol loop queue is a data structure of last-in first-out, the processor in this step writes the stripe information into the write patrol loop queue, and may write the stripe information into the head (i.e., the queue head) of the write patrol loop queue for the processor. Specifically, for the specific mode that the processor writes the stripe information into the write-patrol circular queue in the step, the specific mode can be set by a designer according to a practical scene and user requirements, for example, the processor can write the stripe information into the write-patrol circular queue according to the data write-in completion sequence corresponding to the stripe information; the first strip information is written into the write inspection circulation queue before the second strip information, the first strip information is any strip information, and the second strip information is any strip information with the data writing completion time later than that of the first strip information; that is, the processor may sort the stripe information acquired in the preset time interval according to the time when the data writing is completed, and sequentially write the stripe information into the write patrol loop queue according to the order of the time from early to late, so that the processor may first take out the stripe information with the late data writing completion time from the write patrol loop queue during patrol. The processor can also write the stripe information into the write patrol circular queue according to the write request receiving sequence corresponding to the stripe information; the third strip information is written into the write patrol circular queue before the fourth strip information, the third strip information is any strip information, and the fourth strip information is any strip information with corresponding write request receiving time later than the third strip information. The processor may further obtain stripe information corresponding to the write request after the execution of the write request sent by each client is completed, and directly write the stripe information into the write patrol loop queue. The present embodiment does not impose any limitation on this.
Correspondingly, as shown in fig. 2, in the process that the processor writes each piece of strip information into the write-patrol circular queue, if the write-patrol circular queue already stores a preset number of pieces of strip information, the processor may insert the current strip information into the head of the write-patrol circular queue, i.e. overwrite the current strip information into the tail of the write-patrol circular queue, and update the head identifier (iter) of the write-patrol circular queue, so that the current strip information is located at the head of the write-patrol circular queue; the current strip information is any strip information.
It should be noted that, in this embodiment, by using the cycle characteristic of the write patrol loop queue, old stripe information can be circularly covered, and stored stripe information is kept up to date, so that when the data writing speed is high, that is, when the stripe information writing speed of the write patrol loop queue is greater than the patrol fetching speed, the sampling patrol function is realized. Furthermore, in this embodiment, the stripe information obtained in the step 101 may be sampled and screened, so that the stripe information obtained after screening is written into the write-patrol circular queue, so as to avoid the problem that the sampling function implemented by the write-patrol circular queue is not perfect enough when the writing speed is too fast; for example, when the processor acquires the strip information according to a preset time interval, the processor can judge whether the number of the strip information acquired currently is larger than a threshold value; if the number of the band information is larger than the threshold value, sampling and screening the currently acquired band information, and writing the screened band information with the target number (such as the threshold value) into a write inspection circulation queue; if the band information is not greater than the threshold value, the band information acquired at present is directly written into the write patrol circular queue.
Step 103: obtaining target strip information from the write inspection circular queue, and performing data consistency inspection on strips corresponding to the target strip information; the target stripe information is the preset quantity of stripe information written after writing in the patrol circular queue.
The target stripe information in this step may be a preset number of stripe information that is fetched from the head (i.e. the queue head) of the write-patrol circular queue by the processor during the patrol, i.e. a preset number of stripe information written after the write-patrol circular queue. The specific number of the preset number in this embodiment, that is, the specific number of the stripe information to be checked, which is taken out from the head of the write-patrol circular queue by the processor during each patrol, may be set by the designer, which is not limited in this embodiment.
Correspondingly, the specific process of performing the data consistency check on the stripe corresponding to the target stripe information by the processor in this step may be set by a designer, for example, may be implemented in the same or similar manner as the data consistency check method performed on the stripe in the inspection process in the prior art, which is not limited in this embodiment.
It can be understood that the purpose of this step can be that the processor takes out the preset quantity of strip information (i.e. target strip information) from the head of the write inspection circular queue during inspection, so as to utilize the taken out strip information to carry out inspection, promote the instantaneity of data inspection, and enhance the active detection capability of the storage system. As shown in fig. 2, the processor may run a background task scheduling process to fetch a preset amount of stripe information from the head (i.e., the queue head) of the write patrol loop queue during the patrol, and update the head identifier (iter) of the write patrol loop queue, so that the stripe information with the latest non-fetched write time is updated as the head of the write patrol loop queue.
Specifically, the embodiment is not limited to a specific manner in which the processor obtains the target strip information from the write-patrol circular queue, for example, the processor may obtain the target strip information from the write-patrol circular queue at a preset patrol time interval.
Correspondingly, the inspection method provided by the embodiment can be used in combination with the conventional inspection strategy, so that even if a write request is not executed recently, the disk array can be inspected continuously according to the conventional inspection strategy.
It should be noted that, in order to further enhance the active detection capability of the storage system, for some special stripes (i.e. target stripes) that need to be patrolled, for example, stripes where the disk is temporarily offline when writing data, stripes where the patrolling determines that the data is inconsistent, and repair the stripes that are completed, in this embodiment, the stripe information (i.e. special stripe information) corresponding to the target stripes may also be obtained after the target stripe data is written; controlling a write request sent by a suspension execution client, and writing special stripe information into a write patrol circular queue; that is, the processor can suspend the service IO, and avoid writing new stripe information into the write patrol loop queue, so that the processor can first fetch special stripe information from the write patrol loop queue for patrol. Correspondingly, the processor can control the recovery of the write request sent by the execution client after acquiring the special stripe information from the write patrol loop queue or after carrying out data consistency check on the stripe corresponding to the special stripe information.
Specifically, the special stripe information includes stripe information of a first target stripe, when the first target stripe is a stripe with inconsistent data determined by inspection, the step of obtaining the special stripe information may be that the processor obtains the stripe information of the first target stripe after detecting that the repair is completed and the first target stripe writes data of the write request. The special stripe information includes stripe information of a second target stripe, and when the second target stripe is a stripe of a disk temporarily offline when writing data of a corresponding write request, the step of acquiring the special stripe information may be to detect the second target stripe, and after the first target stripe writes data of the write request, acquire stripe information of the second target stripe.
In the embodiment of the invention, the stripe information which is written into the data is written into the write-patrol circular queue, so that the data which is first-in and first-out is ensured to be the data which is written into the data recently by utilizing the data structure of the write-patrol circular queue, and the instantaneity of data patrol is improved; and by utilizing the circulation characteristic of the write patrol loop queue, old strip information can be circularly covered, and stored strip information is kept up to date, so that the sampling patrol function is realized when the data writing speed is high and the patrol speed is high, the active detection capability of the storage system is further enhanced, and the reliability of the storage system is improved.
Referring to fig. 3, fig. 3 is a block diagram illustrating a patrol device for a redundant array of inexpensive disks according to an embodiment of the present invention. The apparatus may include:
the obtaining module 10 is configured to obtain stripe information corresponding to a write request after the write request sent by the client is executed;
a writing module 20, configured to write stripe information to the write patrol loop queue; the write inspection circular queue is of a last-in first-out data structure, and the write inspection circular queue stores the strip information of the preset quantity at most;
the inspection module 30 is configured to acquire target stripe information from the write inspection circular queue, and perform data consistency inspection on stripes corresponding to the target stripe information; the target stripe information is the preset quantity of stripe information written after writing in the patrol circular queue.
Optionally, the writing module 20 may be specifically configured to write the stripe information into the write patrol loop queue according to the data write completion sequence corresponding to the stripe information; the first strip information is written into the write patrol loop queue before the second strip information, the first strip information is any strip information, and the second strip information is any strip information with the data writing completion time later than that of the first strip information.
Optionally, the writing module 20 may include:
the circulation covering sub-module is used for covering and writing the current strip information into the tail part of the write-patrol circular queue if the write-patrol circular queue stores the preset quantity of strip information, and updating the head mark of the write-patrol circular queue to enable the current strip information to be positioned at the head part of the write-patrol circular queue; the current strip information is any strip information.
Optionally, the apparatus may further include:
the special acquisition module is used for acquiring special strip information;
and the suspension writing module is used for suspending execution of the writing request and writing the special stripe information into the writing patrol circular queue.
Optionally, the apparatus may further include:
and the recovery module is used for recovering the execution of the write request after acquiring the special stripe information from the write patrol circular queue and carrying out data consistency check on the stripe corresponding to the special stripe information.
Alternatively, the special acquisition module may include:
the first detection recovery submodule is used for acquiring the strip information of the first target strip after detecting the repaired first target strip; the special band information comprises band information of a first target band, wherein the first target band is a band with data inconsistency determined by inspection.
Alternatively, the special acquisition module may include:
the second detection recovery submodule is used for acquiring the strip information of the second target strip after detecting the second target strip; the special stripe information comprises stripe information of a second target stripe, wherein the second target stripe is a stripe which is temporarily offline from a disk when data of a corresponding write request is written.
In this embodiment, the writing module 20 writes the stripe information which is written in by the latest data into the write-patrol cyclic queue, and the write-patrol cyclic queue with the data structure being the last-in first-out ensures that the data which is first-patrol is the latest written-in data, so that the instantaneity of data patrol is improved; and by utilizing the circulation characteristic of the write patrol loop queue, old strip information can be circularly covered, and stored strip information is kept up to date, so that the sampling patrol function is realized when the data writing speed is high and the patrol speed is high, the active detection capability of the storage system is further enhanced, and the reliability of the storage system is improved.
Referring to fig. 4, fig. 4 is a schematic structural diagram of an inspection apparatus for a redundant array of inexpensive disks according to an embodiment of the present invention. The device 1 may comprise:
a memory 11 for storing a computer program; the processor 12 is configured to execute the computer program to implement the steps of the inspection method for a redundant array of magnetic disks according to the above embodiment.
The device 1 may be embodied as a server of a storage system and the device 1 may comprise a memory 11, a processor 12 and a bus 13.
The memory 11 includes at least one type of readable storage medium including flash memory, a hard disk, a multimedia card, a card type memory (e.g., SD or DX memory, etc.), a magnetic memory, a magnetic disk, an optical disk, etc. The memory 11 may in some embodiments be an internal storage unit of the device 1. The memory 11 may in other embodiments also be an external storage device of the device 1, such as a plug-in hard disk provided on a server, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash Card (Flash Card) or the like. Further, the memory 11 may also include both an internal storage unit and an external storage device of the device 1. The memory 11 may be used not only for storing application software installed in the device 1 and various types of data, for example: code of a program that performs a patrol method of the redundant array of magnetic disks, or the like, may also be used to temporarily store data that has been output or is to be output.
The processor 12 may in some embodiments be a central processing unit (Central Processing Unit, CPU), controller, microcontroller, microprocessor or other data processing chip for running program code or processing data stored in the memory 11, such as code for executing a program of a patrol method of a redundant array of disks, etc.
The bus 13 may be a peripheral component interconnect standard (peripheral component interconnect, PCI) bus, or an extended industry standard architecture (extended industry standard architecture, EISA) bus, among others. The bus may be classified as an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown in fig. 4, but not only one bus or one type of bus.
Further, the device may also comprise a network interface 14, which network interface 14 may optionally comprise a wired interface and/or a wireless interface (e.g. WI-FI interface, bluetooth interface, etc.), typically used to establish a communication connection between the device 1 and other electronic devices.
Optionally, the device 1 may further comprise a user interface 15, the user interface 15 may comprise a Display, an input unit such as keys, and the optional user interface 15 may further comprise a standard wired interface, a wireless interface. Alternatively, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, an OLED (Organic Light-Emitting Diode) touch, or the like. The display may also be referred to as a display screen or display unit, as appropriate, for displaying information processed in the device 1 and for displaying a visual user interface.
Fig. 4 shows only a device 1 with components 11-15, it being understood by a person skilled in the art that the structure shown in fig. 4 does not constitute a limitation of the device 1, and may comprise fewer or more components than shown, or may combine certain components, or a different arrangement of components.
In addition, the embodiment of the application also discloses a computer readable storage medium, and the computer readable storage medium stores a computer program, and the computer program realizes the steps of the inspection method of the redundant array of magnetic disk provided by the embodiment when being executed by a processor.
Wherein the storage medium may include: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
In the description, each embodiment is described in a progressive manner, and each embodiment is mainly described by the differences from other embodiments, so that the same similar parts among the embodiments are mutually referred. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant points refer to the description of the method section.
The method, the device, the equipment and the computer readable storage medium for inspecting the redundant array of inexpensive disks provided by the invention are described in detail. The principles and embodiments of the present invention have been described herein with reference to specific examples, the description of which is intended only to facilitate an understanding of the method of the present invention and its core ideas. It should be noted that it will be apparent to those skilled in the art that various modifications and adaptations of the invention can be made without departing from the principles of the invention and these modifications and adaptations are intended to be within the scope of the invention as defined in the following claims.

Claims (8)

1. The method for inspecting the redundant array of inexpensive disks is characterized by comprising the following steps of:
after the execution of a write request sent by a client is completed, obtaining stripe information corresponding to the write request;
writing the strip information into a write patrol circular queue; the write patrol circular queue is of a last-in first-out data structure, and the write patrol circular queue stores the preset quantity of strip information at most;
acquiring target strip information from the write inspection circular queue, and performing data consistency inspection on strips corresponding to the target strip information; the target strip information is the preset number of strip information written in the write patrol circular queue;
the writing the stripe information into the write patrol loop queue comprises the following steps:
writing the stripe information into the write patrol circular queue according to the data write completion sequence corresponding to the stripe information; the first stripe information is written into the write patrol circular queue before the second stripe information, wherein the first stripe information is any stripe information, and the second stripe information is any stripe information with the data writing completion time later than that of the first stripe information;
correspondingly, the writing the stripe information into the write patrol loop queue according to the data write completion sequence corresponding to the stripe information includes:
if the write patrol circular queue already stores the preset quantity of the strip information, the current strip information is written into the tail of the write patrol circular queue in a covering mode, and the head mark of the write patrol circular queue is updated, so that the current strip information is located at the head of the write patrol circular queue; the current strip information is any strip information;
the writing the stripe information into the write patrol loop queue comprises the following steps:
sampling and screening the acquired strip information, and writing the screened strip information into the write patrol circular queue.
2. The method for patrol of a redundant array of inexpensive disks according to claim 1, further comprising:
acquiring special band information;
suspending execution of the write request and writing the special stripe information to a write patrol loop queue.
3. The method for patrol of redundant array of disks of claim 2 further comprising:
and after the special stripe information is obtained from the write patrol loop queue and the data consistency check is carried out on the stripe corresponding to the special stripe information, the write request is restored to be executed.
4. The method for inspecting a redundant array of inexpensive disks according to claim 2, wherein the acquiring the special stripe information comprises:
after detecting a repaired first target strip, obtaining strip information of the first target strip; the special band information comprises band information of the first target band, and the first target band is a band with data inconsistency determined by inspection.
5. The method for inspecting a redundant array of inexpensive disks according to claim 2, wherein the acquiring the special stripe information comprises:
after a second target strip is detected, strip information of the second target strip is obtained; the special stripe information comprises stripe information of the second target stripe, and the second target stripe is a stripe which is temporarily offline from a disk when writing data of a corresponding write request.
6. A patrol device for a redundant array of inexpensive disks, comprising:
the acquisition module is used for acquiring the stripe information corresponding to the write request after the write request sent by the client is executed;
the writing module is used for writing the strip information into a write patrol circular queue; the write patrol circular queue is of a last-in first-out data structure, and the write patrol circular queue stores the preset quantity of strip information at most;
the inspection module is used for acquiring target strip information from the write inspection circular queue and carrying out data consistency inspection on strips corresponding to the target strip information; the target strip information is the preset number of strip information written in the write patrol circular queue;
the writing module is specifically configured to write the stripe information into the write inspection circulation queue according to a data writing completion sequence corresponding to the stripe information; the first stripe information is written into the write patrol circular queue before the second stripe information, wherein the first stripe information is any stripe information, and the second stripe information is any stripe information with the data writing completion time later than that of the first stripe information;
correspondingly, the writing module comprises:
the circulation covering sub-module is used for covering and writing the current strip information to the tail of the write patrol circulation queue if the write patrol circulation queue stores the preset quantity of strip information, and updating the head mark of the write patrol circulation queue to enable the current strip information to be located at the head of the write patrol circulation queue; the current strip information is any strip information;
the writing module is specifically configured to sample and screen the acquired stripe information, and write the stripe information obtained after screening into the write inspection circulation queue.
7. A patrol apparatus for a redundant array of inexpensive disks, comprising:
a memory for storing a computer program;
a processor for implementing the steps of the method for patrol of a redundant array of magnetic disk according to any one of claims 1 to 5 when executing the computer program.
8. A computer readable storage medium, wherein a computer program is stored on the computer readable storage medium, and the computer program when executed by a processor implements the steps of the method for inspecting a redundant array of magnetic disks according to any one of claims 1 to 5.
CN202010986784.5A 2020-09-18 2020-09-18 Method, device, equipment and storage medium for inspecting redundant array of inexpensive disks Active CN112148221B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010986784.5A CN112148221B (en) 2020-09-18 2020-09-18 Method, device, equipment and storage medium for inspecting redundant array of inexpensive disks

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010986784.5A CN112148221B (en) 2020-09-18 2020-09-18 Method, device, equipment and storage medium for inspecting redundant array of inexpensive disks

Publications (2)

Publication Number Publication Date
CN112148221A CN112148221A (en) 2020-12-29
CN112148221B true CN112148221B (en) 2024-02-13

Family

ID=73893167

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010986784.5A Active CN112148221B (en) 2020-09-18 2020-09-18 Method, device, equipment and storage medium for inspecting redundant array of inexpensive disks

Country Status (1)

Country Link
CN (1) CN112148221B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113253946B (en) * 2021-07-15 2021-09-17 苏州浪潮智能科技有限公司 RAID array inspection method, device, equipment and storage medium
CN113805799B (en) * 2021-08-08 2023-08-11 苏州浪潮智能科技有限公司 Method, device, equipment and readable medium for RAID array latest write record management
CN115878052B (en) * 2023-03-08 2023-05-23 苏州浪潮智能科技有限公司 RAID array inspection method, inspection device and electronic equipment
CN116126254B (en) * 2023-04-19 2023-07-14 苏州浪潮智能科技有限公司 Disk redundant array inspection method, device, computer equipment and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101566924A (en) * 2008-04-23 2009-10-28 中兴通讯股份有限公司 Data read-write method of disk array
CN103777905A (en) * 2014-02-14 2014-05-07 华中科技大学 Software-defined fusion storage method for solid-state disc
CN104503867A (en) * 2014-12-24 2015-04-08 北京同有飞骥科技股份有限公司 Method for automatic disaster recovery after drop-off and reconnection of extension cabinet
CN109522200A (en) * 2019-01-23 2019-03-26 郑州云海信息技术有限公司 A kind of raising stores the test method of disk array stability, system and terminal more

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9009397B1 (en) * 2013-09-27 2015-04-14 Avalanche Technology, Inc. Storage processor managing solid state disk array

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101566924A (en) * 2008-04-23 2009-10-28 中兴通讯股份有限公司 Data read-write method of disk array
CN103777905A (en) * 2014-02-14 2014-05-07 华中科技大学 Software-defined fusion storage method for solid-state disc
CN104503867A (en) * 2014-12-24 2015-04-08 北京同有飞骥科技股份有限公司 Method for automatic disaster recovery after drop-off and reconnection of extension cabinet
CN109522200A (en) * 2019-01-23 2019-03-26 郑州云海信息技术有限公司 A kind of raising stores the test method of disk array stability, system and terminal more

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
RAID控制器中I/O调度算法研究;姜国松;谢长生;丁红;刘晖;;小型微型计算机系统(04);全文 *

Also Published As

Publication number Publication date
CN112148221A (en) 2020-12-29

Similar Documents

Publication Publication Date Title
CN112148221B (en) Method, device, equipment and storage medium for inspecting redundant array of inexpensive disks
US9298625B2 (en) Read and write requests to partially cached files
US10565075B2 (en) Storage device and block storage method based on the storage device
US8352946B2 (en) Managing migration ready queue associated with each processor based on the migration ready status of the tasks
US11593107B2 (en) Handling an input/output store instruction
CN103488563A (en) Data race detection method and device for parallel programs and multi-core processing system
CN106910528A (en) A kind of optimization method and device of solid state hard disc data routing inspection
CN104461925A (en) Automatic correcting method and device for aligning storage device addresses
CN107632781B (en) Method for rapidly checking consistency of distributed storage multi-copy and storage structure
CN111061690B (en) RAC-based database log file reading method and device
CN112182010A (en) Dirty page refreshing method and device, storage medium and electronic equipment
CN102037448A (en) Device emulation support within a host data processing apparatus
EP0883061A1 (en) Debugging method for a microcomputer system and recording medium on which debug program is recorded
CN111538705B (en) Video thumbnail preview method, control server and medium
CN106843765A (en) A kind of disk management method and device
CN110716923B (en) Data processing method, data processing device, node equipment and storage medium
CN110750587B (en) Method for processing large amount of high-speed logs of debugging equipment
CN113806119A (en) Memory card processing method, device, equipment and storage medium
CN113468105A (en) Data structure of data snapshot, related data processing method, device and system
CN117156172B (en) Video slice reporting method, system, storage medium and computer
JP4562641B2 (en) Computer system, operation state determination program, and operation state determination method
CN110442531A (en) Reading performance method for improving, device and computer equipment based on solid state hard disk
CN116662603B (en) Time shaft control method and system based on kafka, electronic equipment and storage medium
CN111198659B (en) Concurrent I/O stream model identification method and system based on multi-sliding window implementation
CN114116291B (en) Log detection method, log detection device, computer device and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant