JP4347265B2 - RAID control apparatus and RAID control method - Google Patents

RAID control apparatus and RAID control method Download PDF

Info

Publication number
JP4347265B2
JP4347265B2 JP2005158776A JP2005158776A JP4347265B2 JP 4347265 B2 JP4347265 B2 JP 4347265B2 JP 2005158776 A JP2005158776 A JP 2005158776A JP 2005158776 A JP2005158776 A JP 2005158776A JP 4347265 B2 JP4347265 B2 JP 4347265B2
Authority
JP
Japan
Prior art keywords
area
raid
file
raid type
information
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
JP2005158776A
Other languages
Japanese (ja)
Other versions
JP2006338091A (en
Inventor
和也 白石
Original Assignee
Necシステムテクノロジー株式会社
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 Necシステムテクノロジー株式会社 filed Critical Necシステムテクノロジー株式会社
Priority to JP2005158776A priority Critical patent/JP4347265B2/en
Publication of JP2006338091A publication Critical patent/JP2006338091A/en
Application granted granted Critical
Publication of JP4347265B2 publication Critical patent/JP4347265B2/en
Application status is Active legal-status Critical
Anticipated expiration legal-status Critical

Links

Images

Description

  The present invention relates to a RAID control apparatus and a RAID control method that store files in a distributed manner on a plurality of hard disk drives.

  RAID (Redundant Arrays of Independent (Inexpensive) Disks) is a technique for improving the reliability and performance of a hard disk array composed of a plurality of hard disks and a plurality of hard disk drives. A hard disk array or hard disk drive that stores information using a RAID method is called a RAID device.

  There are RAID 0 to RAID 5 methods (hereinafter, RAID methods are referred to as RAID types). The user sets a RAID type for each logical volume when constructing a logical volume (logical area) on each hard disk.

  In the conventional technique, when a RAID type is set when a logical volume is constructed, all files stored in the logical volume must be the RAID type of the logical volume. For this reason, when it is expected that a plurality of types of RAID will be used, for example, a RAID 5 logical volume that emphasizes reliability and a RAID 0 logical volume that emphasizes capacity efficiency need to be created separately in advance. . It is necessary to determine the capacity of each logical volume by predicting the future used capacity or storage capacity when the RAID device is introduced.

  Specifically, when storing an important file that is unique and should not lose data, RAID 5 is selected even if extra storage capacity is used for redundancy. When storing a file that may be lost when the hard disk drive fails, such as when there is another master file, RAID 0 is selected so as to use as little storage capacity as possible. Then, the file is stored in the logical volume corresponding to the selected RAID type.

  However, if the capacity actually used differs from the predicted capacity for storing each RAID type file, the capacity of the logical volume must be changed or reconstructed.

  In addition, RAID5 was selected because it was important when the file was obtained. However, since the importance was lowered after that, it may be changed to RAID0 in order to reduce the storage capacity. Furthermore, since it was not important when the file was obtained, RAID 0 was selected. However, since it became important after that, it may be changed to RAID 5.

  Patent Document 1 describes a system that can set a RAID type for each file stored in a RAID device, but does not describe a method for changing the RAID type of a file.

  Patent Document 2 describes an apparatus that can add redundancy to a file and change a RAID type.

JP 2000-99282 A (paragraphs 0015 to 0030, FIG. 1) JP 2004-213064 A (paragraphs 0037 to 0074, FIG. 1)

  However, when changing the RAID type of a file in the apparatus described in Patent Document 2, the process of temporarily reading the file and storing it in the cache memory of the RAID apparatus and storing it in another logical volume with another RAID type It takes time and effort.

  Accordingly, it is an object of the present invention to provide a RAID control apparatus and a RAID control method capable of setting a RAID type for each file and easily changing the set RAID type.

A RAID control apparatus according to the present invention is a RAID control apparatus that is connected to a host computer and a plurality of hard disk devices and stores files in a distributed manner on the plurality of hard disk devices. The RAID control device uses a first RAID using parity information from the host computer. When an instruction to store a file by type is input, an area composed of a plurality of blocks allocated across a plurality of hard disk devices is secured, and information indicating the first RAID type is associated with the area, First storage control means for generating parity information of the file, storing file data and the generated parity information in an area corresponding to information indicating the first RAID type, and using the parity information from the host computer Finger to store the file with the second RAID type Is input, an area having a plurality of blocks allocated across a plurality of hard disk devices and having the same capacity as the area secured by the first storage control means is secured, and The information indicating the RAID type 2 is associated, the file data is stored in some blocks in the area corresponding to the information indicating the second RAID type, and the information indicating the second RAID type is associated. File data and generation when a second storage control means for setting other blocks in the area to an unused state and an instruction to change the first RAID type to the second RAID type are input from the host computer The information corresponding to the area where the parity information is stored indicates the second RAID type from the information indicating the first RAID type. The host computer receives first type changing means for setting the block in which parity information is stored to an unused state and an instruction for changing the second RAID type to the first RAID type. The information corresponding to the area where the file data is stored is changed from the information indicating the second RAID type to the information indicating the first RAID type, and the parity information of the file is generated, If the block set in the unused state by the second storage control unit in the area is still in the unused state, the generated parity information is stored in the block, and the second storage control unit in the area is set in the unused state. When other data is stored in the set block, the second type for storing the parity information generated in the other block. And the first storage control means and the second storage control means include the block set in the unused state by the second storage control means in the area to be secured. .

The second storage control unit sets the block to an unused state by setting information indicating the unused state in the control table, and the first storage control unit stores the information indicating the unused state in the control table. When is a predetermined number set in the block corresponding to the information, it may be to store the data and parity information file.

The first storage control means and the second storage control unit, the control table, and region, and information indicating the RAID type of file that is stored in the area may be associated.

A RAID control method according to the present invention is a RAID control method executed by a RAID control device that stores files in a distributed manner on a plurality of hard disk devices in accordance with an instruction from the host computer , and uses a parity information from the host computer. When an instruction to store a file with one RAID type is input, information indicating the first RAID type for the area is secured by securing an area composed of a plurality of blocks allocated over a plurality of hard disk devices. A first storage control process for generating the parity information of the file, storing the file data and the generated parity information in an area corresponding to the information indicating the first RAID type, and generating a parity from the host computer Finger to store the file with the second RAID type that does not use information Is input, an area composed of a plurality of blocks allocated over a plurality of hard disk devices and having the same capacity as the area secured in the first storage control process is secured, and The information indicating the second RAID type is associated, the file data is stored in some blocks in the area corresponding to the information indicating the second RAID type, and the information indicating the second RAID type is associated. When the host computer inputs a second storage control process for setting other blocks in the reserved area to an unused state and an instruction to change the first RAID type to the second RAID type, The information corresponding to the area where the generated parity information is stored is changed from the information indicating the first RAID type to the second RAID type. The host computer inputs a first type change process for setting a block in which parity information is stored to an unused state and an instruction for changing the second RAID type to the first RAID type. The information corresponding to the area where the file data is stored is changed from the information indicating the second RAID type to the information indicating the first RAID type, and the parity information of the file is generated, If the block set to the unused state in the second storage control process in the area is still unused, the generated parity information is stored in the block, and is not used in the second storage control process in the area When other data is stored in the block set to the state, the parity information generated in the other block is stored. The type change process is executed, and the block set to the unused state in the second storage control process is included in the area to be secured in the first storage control process and the second storage control process. And

  According to the present invention, a RAID type can be set for each file, and the set RAID type can be easily changed.

In addition , the utilization efficiency of the storage capacity of the hard disk device can be improved.

  Embodiments of the present invention will be described with reference to the drawings. FIG. 1 is a block diagram showing a configuration example of an embodiment of a file management system using a RAID control device according to the present invention.

  The file management system shown in FIG. 1 is a hard disk device (HDD: hard disk drive) 30, 31, 32, 33 having a hard disk for storing files and a data read / write function for the hard disk, files stored in each HDD, and each HDD. A host computer 10 that inputs an instruction indicating processing to be performed, and a RAID controller (RAID control device) 20 that stores a file in each HDD based on the instruction input to the host computer 10 are included.

  The host computer 10 includes a RAID type designating unit 12 that specifies which RAID type the input file is stored in each HDD, and the input file and information indicating the RAID type designated by the RAID type designating unit 12 An IO issuing unit 11 that transmits to the RAID controller 20 is included.

  The RAID type designation unit 12 designates the RAID type of the file according to the importance level of the file input via an input means (not shown) such as a keyboard. Specifically, the RAID type designating unit 12 designates RAID 5 when, for example, an important file and importance is placed on the reliability is input to the input unit. In addition, if it is input that the HDD utilization efficiency is more important than reliability, RAID 0 is designated. The RAID type designation unit 12 may designate the input RAID type when the RAID type is input to the input unit.

  The IO issuing unit 11 transmits to the RAID controller 20 the RAID type designated by the RAID type designation unit 12 and a file and a write command instructing storage of the file. In addition, the host computer 10 is equipped with a file management program for managing files stored in each HDD. When the file management program designates a logical address indicating a block of an area for storing a file in each HDD, the IO issue unit 11 transmits the designated logical address to the RAID controller 20.

  Specifically, for example, if the host computer 10 and the RAID controller 20 are connected by a SCSI (Small Computer System Interface), a RAID in an unused area of a CDB (Command Descriptor Block) of a write command instructing file storage is used. A flag indicating the type and logical address is provided. Further, a unique page designating a RAID type or a logical address may be defined in the mode select command, and the mode select command may be transmitted before transmitting the write command.

  The RAID controller 20 includes an IO control unit 21 that receives information from the IO issue unit 11, a RAID type analysis unit 23 that recognizes the RAID type transmitted by the IO issue unit 11, a control table 25 that indicates the usage status of each HDD, and a control table. 25, an allocation control unit (allocation control means) 24 that determines the RAID type of the file, a RAID type change control unit 22 that changes the RAID type of the file in accordance with the control of the allocation control unit 24, and an allocation control unit 24. A parity information generation unit (parity information generation means) 26 that generates parity information to be added to the file according to the control of the file, a copy control unit 27 that generates a copy of the file according to the control of the allocation control unit 24, and the file Includes an HDD control unit (hard disk device control means) 28 for transmitting and storing the information to each HDD.

  FIG. 2 is an explanatory diagram showing files stored in each HDD. FIG. 2 exemplifies that each HDD stores files 41, 42, and 43 in a distributed manner using RAID 5 with emphasis on reliability. In addition, it is exemplified that each HDD stores the files 51, 52, and 53 in a distributed manner using RAID 0 with an emphasis on the HDD capacity utilization efficiency.

  Here, a case will be described as an example where each HDD stores the file 41 in a distributed manner with RAID 5 having a stripe size (the size of each block divided to store the file) of 128 KB. Each HDD is divided in parallel into an area having a predetermined storage capacity, and an area for storing one file is distributed among the HDDs.

  Here, that each HDD is divided into regions of a predetermined storage capacity in parallel means that each HDD is divided into regions so as to have the same storage capacity. Specifically, for example, the HDDs 30, 31, 32, and 33 are divided so that each has an area of a storage capacity of 0.5 MB. In general, each HDD is divided so as to have a plurality of areas. That is, the HDDs 30, 31, 32, and 33 are each divided so as to have 8 areas each having a storage capacity of 0.5 MB. The RAID controller 20 stores information associating the first area in the HDD 30, the first area in the HDD 31, the first area in the HDD 32, and the first area in the HDD 33. Similarly, the RAID controller 20 stores information for associating the second area to the eighth area in each HDD.

  Each area divided in each HDD is divided so that a block for storing the file itself and a block for storing parity information added to the file are provided. Then, a logical address indicating each block is set in the block storing the file itself.

  The HDD control unit 28 sets logical addresses by dividing each HDD into areas and blocks. At this time, the HDD control unit 28 divides areas and blocks and sets logical addresses in accordance with instructions from the host computer 10 on which the file management program is installed. The HDD control unit 28 notifies the host computer 10 of a list of set logical addresses via the IO control unit 21. A storage unit (not shown) of the host computer 10 stores a list of notified logical addresses.

  FIG. 1 illustrates that the file management system includes four HDDs 30, 31, 32, and 33. Therefore, in order to be able to repair a file stored in RAID5 even if any one of each HDD fails, one area in each HDD has four blocks (one is a A block for storing parity information). Then, 4 units × 4 units = 16, so the area for storing one file includes 16 blocks.

  Specifically, since the stripe size is 128 KB, 128 KB × 16 = 2 MB, so each HDD has a physical capacity of one file storage area (total of areas distributed to each HDD) is 2 MB. Are divided in parallel so that Since 2 MB ÷ 4 units = 0.5 MB, the physical capacity of one HDD in an area for storing one file is 0.5 MB, and each HDD is divided into areas every 0.5 MB. Of the 16 blocks, 4 store parity information, so the logical capacity of an area for storing one distributed file is (16-4 pieces) × 128 KB = 1.5 MB, so 1 .5MB.

  Each HDD stores a RAID 5 file or a RAID 0 file in the area divided as described above. When a RAID 0 file is stored, a block for storing parity information of each area of each HDD is not used. Therefore, the HDD control unit 28 extracts unused blocks in the area where the RAID 0 file is stored, collects the extracted blocks, generates a virtual area, and stores other files and parity information in the virtual area. Remember.

  Next, a case where the RAID type is changed will be described. FIG. 3 is an explanatory diagram showing a case where the RAID type of a file stored in each HDD is changed. In FIG. 3, the file 43 is exemplified as being changed from RAID5 to RAID0.

  When changing the file 43 from RAID 5 to RAID 0, the HDD control unit 28 erases the parity information of the file 43 from each HDD.

  When the file 53 is changed from RAID 0 to RAID 5, the allocation control unit 24 refers to the usage status of each HDD with reference to the control table 25, and stores the parity information of the area in which the file 53 is stored. It is determined whether the block provided in is used for another file as a virtual area.

  When used as a virtual area, the allocation control unit 24 causes the HDD control unit 28 to store information stored in the virtual area in another area and to store parity information. Are deleted from each HDD.

  The allocation control unit 24 causes the HDD control unit 28 to read the file 53 from each HDD, and causes the parity information generation unit 26 to generate the parity information of the file 53. At this time, the copy control unit 27 may copy the information stored in the virtual area and output it to the HDD control unit 28. The HDD control unit 28 stores the parity information generated by the parity information generation unit 26 in a block provided for storing the parity information.

  FIG. 4 is an explanatory diagram showing the control table 25. The control table 25 stores a logical address table 60 (FIG. 4A) indicating which area each block to which a logical address is set is included, and the state, physical position, and parity information of each area. 4 includes a state table 61 (FIG. 4B) indicating the state of the blocks provided in FIG. 4, and a block table 62 (FIG. 4C) indicating blocks in which logical addresses included in the respective physical positions are set.

  The assignment control unit 24 assigns an area to the logical address, and sets the area number in the column corresponding to the logical address to which the area is assigned in the logical address table 60.

  The allocation control unit 24 sets the state of each area of the state table 61, the physical position, and the state of blocks provided for storing parity information according to the state of each HDD. Specifically, in the status column of each area, whether the area is unused, unallocated, used in RAID0, or used in RAID5 is set. . In the physical position column, whether the area is composed of a group of blocks (referred to as direct in FIG. 4B) or whether it is composed of a set of a plurality of dispersed blocks ( In FIG. 4B, it is referred to as a set) and the physical position of the area in the HDD is set.

  The physical position is information that indicates a representative sector or the like in each HDD in the area, or that can be derived by a simple calculation. Although it is conceivable that the physical position of the area differs depending on each HDD, it is indicated by a number for simplicity of explanation.

  Further, in the column of the block state provided for storing the parity information (in FIG. 4B, the column indicated as the parity state), the block provided for storing the parity information in the region is the virtual state. When another file is stored as an area, a number indicating the virtual area is set.

  Note that the number indicating the area is a physical position indicating the area when the area is configured by a group of blocks, and is predetermined when the area is configured by a set of a plurality of dispersed blocks. A number indicating the virtual area is set. In FIG. 4B, if the area number is 100 or more, a virtual area is shown, and if it is less than 100, the physical position of an area constituted by a group of blocks is shown. Is illustrated. The physical position of the area used as the virtual area is set in the physical position column of the virtual area. In FIG. 4C, what is the case where the physical position of the area used as the virtual area is not set? It is shown in

  The block table 62 indicates a block at each physical position where a logical address is set for each HDD. In FIG. 4C, the blocks included in each HDD are shown vertically for each physical position.

  Next, changes in the control table 25 when a file is stored in each HDD or the RAID type of a file stored in each HDD is changed will be described.

  A case where a RAID 5 file is stored in the blocks of logical addresses 0 to 11 of the HDDs in the state illustrated in FIG. 4 will be described. FIG. 5 is an explanatory diagram showing the control table 25 when a file is stored in RAID5.

  Referring to FIG. 4 showing the initial state of the control table 25, no area is assigned to the logical addresses 0 to 11 (the area column is blank). When the host computer 10 instructs to store the files at the logical addresses 0 to 11, the allocation control unit 24 allocates the area 0 to the logical addresses 0 to 11, and the rows of the logical addresses 0 to 11 in the logical address table 60 are displayed. Is set to 0. Then, the status column corresponding to the area 0 of the status table 61 is set to RAID5. Further, in the column corresponding to the physical position 0 shown in the block table 62, the logical address of each block storing the file with RAID 5 and information indicating the parity information (denoted as P in FIG. 5) are set. Then, the control table 25 is changed to the state illustrated in FIG.

Next, a case where a RAID 0 file is stored in the block of the logical addresses 24 to 35 of each HDD in the state illustrated in FIG. 4 will be described. FIG. 6 is an explanatory diagram showing the control table 25 when a file is stored in RAID0.

  When the host computer 10 instructs to store the files at the logical addresses 24 to 35, the assignment control unit 24 assigns the area 1 to the logical addresses 24 to 35 and the rows of the logical addresses 24 to 35 of the logical address table 60. Is set to 1. Then, the status column corresponding to the area 1 of the status table 61 is set to RAID0. Further, when storing a file with RAID 0 in each HDD, no parity information is added to the file, and therefore, a block provided for storing the parity information of the area is unused. Therefore, the allocation control unit 24 allocates the block to the area 100, which is a virtual area, and sets the area 100 in the parity allocation column.

  Then, the allocation control unit 24 sets the physical position column corresponding to the area 100 of the state table 61 to 1 which is the physical position where the file is stored in RAID0. Then, a block that is not used because parity information is not added can be made available.

  Note that, as illustrated in FIG. 6, the allocation control unit 24 uses the used physical address even when it is instructed to store the file at a logical address that is not continuous with the used logical address. The file is stored in a physical position continuous to the position. Specifically, even when logical addresses 0 to 11 are used and an instruction to store a file at logical addresses 24 to 35 is given, the allocation control unit 24 uses the physical location 0 used. The file is stored in the physical position 1 that is continuous to the.

  Next, a case where a RAID 0 file stored in each HDD in the state illustrated in FIG. 6 is changed to RAID 5 will be described. FIG. 7 is an explanatory diagram showing the control table 25 when a file stored in RAID0 is changed to RAID5.

  The allocation control unit 24 sets the status of the row of the area 1 in the status table 61 to RAID 5 and deletes the area number set in the parity allocation column. Then, the physical position 1 in the physical position column corresponding to the area 100 is erased. Then, the block that has been made available as the area 100 can be returned to the area 1, and the parity information of the RAID5 file can be stored in the block. The allocation control unit 24 refers to the block table 62, causes the HDD control unit 28 to read the file stored in the block included in the physical position 1 of the area 1, and sends the parity information to the parity information generation unit 26. Generate. The HDD control unit 28 stores the generated parity information in a block for storing the parity information at the physical position 1.

  Next, a case where the RAID 5 file stored in the area 0 in each HDD in the state illustrated in FIG. 7 is changed to RAID 0 will be described. FIG. 8 is an explanatory diagram showing the control table 25 when a file stored in RAID5 is changed to RAID0.

  The allocation control unit 24 sets the row state of the area 0 in the state table 61 to RAID 0 and sets the parity allocation to the area 100. Then, the physical position 0 is added to the physical position in the row of the area 100. Further, the allocation control unit 24 refers to the block table 62 and erases the parity information at the physical position 0 in the HDD control unit 28. Then, since parity information is not added to the file stored in RAID 0, a block for storing parity information at physical position 0 can be used.

  Next, a case where a plurality of files are stored in RAID 0 in each HDD illustrated in FIG. 8 will be described. FIG. 9 is an explanatory diagram showing the control table 25 when a plurality of RAID0 files are stored.

  An example will be described in which three files are stored in RAID 0 in each HDD in the state illustrated in FIG. Referring to FIG. 8, no area is assigned to logical addresses 36-71. When the host computer 10 instructs to store three files at the logical addresses 36 to 71, areas 2, 3, and 4 are allocated to the logical addresses 36 to 47, 48 to 59, and 60 to 71, respectively. It is understood that it is only necessary to store the files in each. Therefore, the allocation control unit 24 sets the areas of the respective rows of the logical addresses 36 to 47, 48 to 59, and 60 to 71 of the logical address table 60 to 2, 3, and 4.

  Then, the allocation control unit 24 sets the status of each row in the areas 2, 3, and 4 of the status table 61 to RAID 0 and sets the parity allocation to the area 100. Further, the physical positions 2, 3, and 4 are added to the physical position of the row of the area 100 of the state table 61, and the state is set to unused. Then, the allocation control unit 24 causes the HDD control unit 28 to store the file in the physical positions 2, 3, and 4 with RAID 0.

  Next, a case where a file is stored with RAID 5 in the virtual area of each HDD in the state illustrated in FIG. 9 will be described. FIG. 10 is an explanatory diagram showing the control table 25 in the case where a file is stored in a virtual area with RAID5.

  Referring to FIG. 9, no area is assigned to logical addresses 84-95. When the host computer 10 instructs to store the files at the logical addresses 84 to 95, the allocation control unit 24 allocates the unused virtual area 100 to the logical addresses 84 to 95, and stores the logical address table 60 in the logical address table 60. The area of the row of logical addresses 84 to 95 is set to 100. Then, the state of the row in the area 100 of the state table 61 is set to RAID5.

  Since the physical position column in the row of the area 100 of the state table 61 is the physical positions 0, 2, 3, and 4, the allocation control unit 24 sends the parity information at the physical positions 0, 2, 3, and 4 to the HDD control unit 28. The file is stored in RAID5 in the block for storing.

  Although the case where a file having the same size as the area is stored in each HDD has been described, the same processing can be performed even when a file having a size different from the area is stored in each HDD.

  For example, when the size of the file is smaller than the area, some blocks in the area store the file. When the file size is larger than the table area, the allocation control unit 24 stores the file using a plurality of areas.

  Further, when a file smaller than that area is stored (overwritten) in RAID 5 in the area assigned to RAID 0, the parity information of the file stored in that area is generated, and the generated parity information and file Are stored in the block of the area. When a file smaller than that area is stored in RAID 0 in the area assigned to RAID 5 (overwritten), parity information is stored in a block that is not overwritten (that is, a block provided for storing parity information). Since there is a possibility that the file exists, the contents stored in the control table 25 are not changed (that is, the state column of the state table 61 is set to RAID5), and the file is stored in the area.

  Next, the operation of the file management system according to the embodiment of this invention will be described with reference to the drawings. FIG. 11 is a flowchart illustrating an operation when the file management system stores a file.

  When a file is input to the host computer 10 and the RAID type designation unit 12 designates a RAID type for storing the file, the file management program installed in the host computer 10 displays a list of logical addresses stored in the storage means. Specifies the logical address of the area where the read and input files are stored. Then, the IO issuing unit 11 transmits the input file, information indicating the RAID type specified by the RAID type specifying unit 12 and information indicating the specified logical address to the RAID controller 20.

  When the IO control unit 21 of the RAID controller 20 receives a file, information indicating the RAID type, and information indicating the logical address from the IO issuing unit 11, the IO control unit 21 outputs the file to the HDD control unit 28, and indicates the RAID type. Is output to the RAID type analysis unit 23, and the file and information indicating the logical address are output to the allocation control unit 24.

  The RAID type analysis unit 23 analyzes which RAID type the file is stored in each HDD based on the information indicating the input RAID type. The analyzed result is output to the IO control unit 21. The IO control unit 21 outputs the result analyzed by the RAID type analysis unit 23 to the allocation control unit 24.

  When the information indicating the designated logical address is input, the allocation control unit 24 refers to the control table 25 to determine whether or not the logical address indicated by the information indicating the designated logical address has already been assigned to the area. Is determined (step S101).

  If the allocation control unit 24 determines that the designated logical address is not allocated to an area, the allocation control unit 24 searches the control table 25 and extracts an area number of an unused area (step S102).

  The allocation control unit 24 selects one from the extracted area numbers, and sets the selected area number in the column corresponding to the logical address of the logical address table 60 of the control table 25 (step S103).

  In addition, when the result analyzed by the RAID type analysis unit 23 is input, the allocation control unit 24 determines whether the host computer 10 specifies RAID 0 (step S104).

  If the allocation control unit 24 determines that RAID 0 is designated, it sets the status column corresponding to the selected area number in the status table 61 of the control table 25 to RAID 0 (step S105).

  Then, the allocation control unit 24 refers to the state table 61 of the control table 25, searches for and extracts the area number of the unallocated area, and selects one area number (step S106). Then, the area number selected in step S106 is set in the parity allocation field corresponding to the area number of the area selected in step S103, and the physical position field corresponding to the area number selected in step S106 is set. A physical position corresponding to the area number selected in step S103 is set (step S107).

  The allocation control unit 24 sets physical positions in all blocks in the unallocated area selected in step S106 (that is, physical positions are set in all blocks as virtual areas) (step S108). Then, the state of the unallocated area selected in step S106 in the state table 61 of the control table 25 is changed from unallocated to unused (step S109).

  Then, the allocation control unit 24 refers to the control table 25, divides the file into area block sizes, and outputs the divided file and the selected area number to the parity information generation unit 26.

  The parity information generation unit 26 outputs the input divided file and the selected area number to the HDD control unit 28.

  If the allocation control unit 24 determines in step S104 that the host computer 10 does not specify RAID0, the allocation control unit 24 sets the status column corresponding to the selected area number in the status table 61 of the control table 25 to RAID5. (Step S110).

  The allocation control unit 24 refers to the control table 25, divides the file into area block sizes, and outputs the divided file and the selected area number to the parity information generation unit 26.

  When the file divided into blocks is input, the parity information generation unit 26 generates parity information (step S111).

  The parity information generation unit 26 outputs the generated parity information, the file divided into blocks, and the selected area number to the HDD control unit 28.

  If the allocation control unit 24 determines in step S101 that the specified logical address has already been allocated to the area, the allocation control unit 24 refers to the control table 25 and confirms the RAID type of the allocated area (step S101). S112).

  If the allocation control unit 24 determines that the RAID type of the allocated area does not match the designated RAID type (step S113), the allocation control unit 24 executes a process of changing the RAID type of the allocated area (step S113). S114). A process for changing the RAID type of the allocated area will be described later.

  When the allocation control unit 24 determines that the RAID type of the allocated area matches the specified RAID type (step S113), or executes the process of changing the RAID type of the allocated area, It is determined whether or not the RAID type set is RAID 5 (step S115).

  When determining that the designated RAID type is RAID 5, the allocation control unit 24 divides the file into block sizes of the area, outputs the divided file to the parity information generation unit 26, and performs the processing after step S111. The parity information generation unit 26 is caused to execute.

  If the allocation control unit 24 determines that the designated RAID type is not RAID 5, the allocation control unit 24 causes the HDD control unit 28 to execute the processing from step S116.

  The HDD control unit 28 stores a file or the like in each HDD (step S116). When the parity information generation unit 26 generates parity information, the HDD control unit 28 stores the parity information in a predetermined block of each HDD.

  Next, the operation when the file management system according to the embodiment of this invention changes the RAID type of the file stored in each HDD will be described.

  When the file management system according to the embodiment of the present invention changes the RAID type of a file stored in each HDD, there are two cases.

  The first is a case where the host computer 10 is instructed to specify a logical address and change the RAID type.

  The second is an operation when storing the above-described file, where the RAID type of the allocated area does not match the designated RAID type (N in step S113).

  Different operations will be described in the first case and the second case. First, the operation in the first case will be described. The host computer 10 designates a logical address and transmits a command indicating the RAID type after the change to the RAID controller 20.

  For example, if the host computer 10 and the RAID controller 20 are connected via the SCSI interface, the unique page of the mode select command is defined so that the RAID type can be changed. The IO issuing unit 11 of the host computer 10 executes an operation such as the host computer 10 transmitting a mode select command to the RAID controller 20 at an arbitrary timing after the file is stored in each HDD.

  When receiving the mode select command, the IO controller 21 of the RAID controller 20 outputs it to the RAID type change controller 22. When the mode select command is input, the RAID type change control unit 22 outputs the RAID type after change indicated by the unique page of the mode select command and the logical address for changing the RAID type to the assignment control unit 24.

  In the second case, the same operation as that up to step S113 in the operation for storing the file is performed.

  The operation of the RAID controller 20 common to the first case and the second case will be described with reference to the drawings. FIG. 12 is a flowchart for explaining the operation of the RAID controller 20 when changing the RAID type of a file stored in each HDD.

  The allocation control unit 24 changes the RAID type from RAID 5 according to an instruction from the host computer 10 (first case described above) or referring to the control table 25 (second case described above). It is determined whether or not the change is to RAID0 (step S201).

  If the allocation control unit 24 determines that the change of the RAID type is a change from RAID 5 to RAID 0, the assignment control unit 24 changes the status column corresponding to the area to change the RAID type of the status table 61 of the control table 25 to RAID 0 and sets it. (Step S202).

  Then, the allocation control unit 24 refers to the status table 61 of the control table 25, searches for and extracts an unallocated area, and selects one (step S203). Then, the area number of the selected area is set in the parity allocation column corresponding to the area whose RAID type is to be changed. Then, the physical position corresponding to the area whose RAID type is to be changed is set in the physical position column corresponding to the selected area (step S204).

  When the physical position is set in all the blocks of the selected unallocated area (step S205), the allocation control unit 24 sets the selected area number in the status table 61 of the control table 25 to the unallocated area. The state is changed from unassigned to unused (step S206).

  Further, a case will be described in which the allocation control unit 24 determines in step S201 that the RAID type change is not a change from RAID 5 to RAID 0. Hereinafter, for the sake of simplicity of explanation, each region and each physical position is given an alphabet.

  The allocation control unit 24 changes the status column corresponding to the area C in the status table 61 of the control table 25 to be changed to RAID 5 and sets it (step S207).

  Then, the allocation control unit 24 reads the region number D set in the parity allocation corresponding to the region C whose RAID type is to be changed in the state table 61 of the control table 25 (step S208). Then, the physical position C corresponding to the area C whose RAID type is to be changed is erased from the physical position column of the read area number D, and the parity allocation corresponding to the area whose RAID type is to be changed in the state table 61 of the control table 25. D is deleted (step S209).

  The allocation control unit 24 refers to the state table 61 of the control table 25 and determines whether or not the state of the region D that is the region of the region number D read in step S208 is in use (step S210).

  If the allocation control unit 24 is in use, the allocation control unit 24 refers to the status table 61 of the control table 25, and the status is unused or unallocated, the physical position is a set, and one or more physical positions are set. The selected region is extracted, and one (region E) is selected from the extracted regions (step S211). Then, the allocation control unit 24 selects one (physical position F) from the physical positions set in the physical position column of the area E selected in step S211 in the state table 61 of the control table 25 (step S212). .

  The allocation control unit 24 deletes the physical position F selected in step S212 from the physical position column of the area E selected in step S211 in the state table 61 of the control table 25 (step S213).

  The allocation control unit 24 sets the status column corresponding to the area E extracted in step S211 to unallocated in the status table 61 of the control table 25 (step S214).

In the status table 61 of the control table 25, the allocation control unit 24 puts the physical position F selected in step S212 in the physical position column corresponding to the area D read in step S208.
Is added (step S215).

  Then, the allocation control unit 24 sets the area number D read in step S208 in the parity allocation column corresponding to the physical position F selected in step S212 in the state table 61 of the control table 25 (step S216).

  In the block table 62 of the control table 25, the allocation control unit 24 deletes the display indicating the presence of parity information among the blocks in the area C whose RAID type is to be changed, and among the blocks at the physical position F selected in step S212. The block provided for storing the parity information is changed to a display indicating that the parity information is stored.

  Further, the HDD control unit 28 reads the parity information from the area C whose RAID type is to be changed, and stores the read parity information in the block provided for storing the parity information in the physical position F selected in step S212. Store (step S217).

  The allocation control unit 24 refers to the block table 62, causes the HDD control unit 28 to read the file stored in the area C whose RAID type is to be changed, and causes the parity information generation unit 26 to generate parity information. (Step S218). The HDD control unit 28 stores the generated parity information in the block for storing the parity information of the area C (step S219).

  As described above, according to this embodiment, a RAID type can be set for each file, and the set RAID type can be easily changed.

  Also, the storage capacity of the hard disk drive is used to store the divided file and the parity information of the divided file by using the blocks in the area where the file is stored and not storing the parity information. The utilization efficiency can be improved.

  In the embodiment described above, the cases of RAID 0 and RAID 5 have been described, but the present invention can also be applied to other RAID types.

  For example, in the case of RAID1, two areas divided for a logical address may be allocated and used for mirroring, and each area may be managed by the same management method as RAID0.

  Further, for example, in the case of RAID3, although the management method is the same as RAID5, it can be realized by reducing the stripe size when writing a file and distributing one file to four HDDs. At this time, since the HDD for storing the parity information moves in the same way as RAID 5, it is different from general RAID 3, but one file which is the original purpose of RAID 3 is distributed to a plurality of HDDs, and The condition of having redundant parity is satisfied.

  In the embodiment of the present invention, not only the system configuration of the host computer 10 and the RAID controller 20, but also a RAID board mounted on a server and a NAS (Network Attached Storage) device such as a HDD and a RAID mechanism are provided. Applicable to all devices used.

  The present invention can be applied to a system that distributes video information, such as a VOD (Video On Demand) server or a broadcasting system. Further, the present invention can be applied to a system in the medical field that records and reproduces image data such as X-rays and CT scans. Furthermore, the present invention can be applied to a device that handles a large amount of data in a general household, such as a home server or an HDD-equipped home appliance.

  Specifically, for example, in a home server, the only thing that emphasizes reliability is data such as data created by a user using a computer, image data or video data shot with a digital camera or digital video camera, etc. Then, the data is stored in the HDD with RAID5. Also, television broadcast programs, movies, and the like are stored in the HDD with RAID 0 with an emphasis on capacity efficiency. If the free space of the HDD becomes small later, the captured image data can be changed to RAID 0 to increase the free space. Also, if you want to keep your favorite movie, you can change it to RAID5.

It is a block diagram which shows one structural example of embodiment of the file management system using the RAID control apparatus by this invention. It is explanatory drawing which shows the file which each HDD memorize | stores. It is explanatory drawing which shows the case where the RAID type of the file which each HDD has stored is changed. It is explanatory drawing which shows a control table. It is explanatory drawing which shows the control table at the time of storing a file by RAID5. It is explanatory drawing which shows the control table at the time of storing a file by RAID0. It is explanatory drawing which shows the control table in the case of changing the file memorize | stored by RAID0 to RAID5. It is explanatory drawing which shows the control table in the case of changing the file memorize | stored by RAID5 to RAID0. It is explanatory drawing which shows the control table at the time of storing several RAID0 files. It is explanatory drawing which shows the control table in the case of storing a file by RAID5 in a virtual area. It is a flowchart explaining operation | movement when a file management system memorize | stores a file. It is a flowchart explaining operation | movement of a RAID controller at the time of changing the RAID type of the file which each HDD memorize | stores.

Explanation of symbols

DESCRIPTION OF SYMBOLS 10 Host computer 11 IO issuing part 12 RAID type designation | designated part 20 RAID controller 21 IO control part 22 RAID type change control part 23 RAID type analysis part 24 Allocation control part 25 Control table 26 Parity information generation part 27 Copy control part 28 HDD control part 30, 31, 32, 33 HDD
60 Logical address table 61 Status table 62 Block table

Claims (4)

  1. In a RAID control device that is connected to a host computer and a plurality of hard disk devices and stores files in a distributed manner on the plurality of hard disk devices,
    When an instruction to store a file of the first RAID type using parity information is input from the host computer, an area composed of a plurality of blocks allocated across a plurality of hard disk devices is secured and the area is First, information indicating the first RAID type is associated to generate parity information of the file, and the file data and the generated parity information are stored in an area corresponding to the information indicating the first RAID type. Memory control means,
    When the host computer inputs an instruction to store a file of the second RAID type that does not use parity information, the first storage is an area composed of a plurality of blocks allocated over a plurality of hard disk devices. An area having the same capacity as the area secured by the control means is secured, information indicating the second RAID type is associated with the area, and some blocks in the area associated with the information indicating the second RAID type A second storage control means for storing the data of the file and setting other blocks in the area corresponding to the information indicating the second RAID type to an unused state;
    When an instruction to change the first RAID type to the second RAID type is input from the host computer, the information corresponding to the area where the file data and the generated parity information are stored is the first RAID. Changing the information indicating the type to the information indicating the second RAID type, and setting the block in which the parity information is stored to an unused state;
    When an instruction to change the second RAID type to the first RAID type is input from the host computer, the information corresponding to the area in which the file data is stored is changed from the information indicating the second RAID type to the first RAID type. The information is changed to the information indicating the RAID type of 1 and the parity information of the file is generated, and if the block set in the unused state by the second storage control means in the area is still in the unused state, the block A second storage unit that stores the generated parity information, and stores the generated parity information in another block when other data is stored in the block set in the unused state by the second storage control unit in the area. And a type change means
    The RAID control apparatus, wherein the first storage control unit and the second storage control unit include a block set in an unused state by the second storage control unit in an area to be secured .
  2. The second storage control means sets the block to the unused state by setting information indicating the unused state in the control table,
    First storage control means, in the control table, the information indicating the unused state is a predetermined number set in the block corresponding to the information, causes storing the data and parity information files The RAID control device according to claim 1 .
  3. The RAID control apparatus according to claim 2 , wherein the first storage control unit and the second storage control unit associate a region with information indicating a RAID type of a file stored in the region in a control table.
  4. A RAID control method executed by the RAID controller to store the files distributed across multiple hard disk apparatus in response to an instruction of the host computer,
    When an instruction to store a file of the first RAID type using parity information is input from the host computer, an area composed of a plurality of blocks allocated across a plurality of hard disk devices is secured and the area is First, information indicating the first RAID type is associated to generate parity information of the file, and the file data and the generated parity information are stored in an area corresponding to the information indicating the first RAID type. Storage control processing of
    When the host computer inputs an instruction to store a file of the second RAID type that does not use parity information, the first storage is an area composed of a plurality of blocks allocated over a plurality of hard disk devices. An area having the same capacity as the area secured by the control process is secured, information indicating the second RAID type is associated with the area, and a part of the area associated with the information indicating the second RAID type is associated with the area. A second storage control process for storing file data in a block and setting other blocks in an area corresponding to information indicating a second RAID type to an unused state;
    When an instruction to change the first RAID type to the second RAID type is input from the host computer, the information corresponding to the area where the file data and the generated parity information are stored is the first RAID. Changing the information indicating the type to the information indicating the second RAID type, and setting the block in which the parity information is stored to an unused state;
    When an instruction to change the second RAID type to the first RAID type is input from the host computer, the information corresponding to the area in which the file data is stored is changed from the information indicating the second RAID type to the first RAID type. The information is changed to the information indicating the RAID type of 1 and the parity information of the file is generated. If the block set to the unused state in the second storage control process in the area is still in the unused state, Parity information generated in a block is stored, and when other data is stored in a block set to an unused state in the second storage control process in the area, the generated parity information is stored in another block. Execute a second type change process,
    A RAID control method characterized in that, in the first storage control process and the second storage control process, a block set in an unused state by the second storage control process is included in an area to be secured .
JP2005158776A 2005-05-31 2005-05-31 RAID control apparatus and RAID control method Active JP4347265B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2005158776A JP4347265B2 (en) 2005-05-31 2005-05-31 RAID control apparatus and RAID control method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2005158776A JP4347265B2 (en) 2005-05-31 2005-05-31 RAID control apparatus and RAID control method

Publications (2)

Publication Number Publication Date
JP2006338091A JP2006338091A (en) 2006-12-14
JP4347265B2 true JP4347265B2 (en) 2009-10-21

Family

ID=37558624

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2005158776A Active JP4347265B2 (en) 2005-05-31 2005-05-31 RAID control apparatus and RAID control method

Country Status (1)

Country Link
JP (1) JP4347265B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8775868B2 (en) * 2010-09-28 2014-07-08 Pure Storage, Inc. Adaptive RAID for an SSD environment
JP5319723B2 (en) * 2011-03-24 2013-10-16 株式会社東芝 Memory system and program

Also Published As

Publication number Publication date
JP2006338091A (en) 2006-12-14

Similar Documents

Publication Publication Date Title
Chang et al. Efficient management for large-scale flash-memory storage systems with resource conservation
US6718436B2 (en) Method for managing logical volume in order to support dynamic online resizing and software raid and to minimize metadata and computer readable medium storing the same
JP3753259B2 (en) Method and data storage system for providing storage space
KR100899462B1 (en) Distributed storage architecture based on block map caching and vfs stackable file system modules
JP4862006B2 (en) Computer system
JP5827662B2 (en) Hybrid media storage system architecture
JP5427927B2 (en) System and method for RAID management, reallocation, and restriping
US6952794B2 (en) Method, system and apparatus for scanning newly added disk drives and automatically updating RAID configuration and rebuilding RAID data
US8607016B2 (en) FAT analysis for optimized sequential cluster management
US7124247B2 (en) Quantification of a virtual disk allocation pattern in a virtualized storage pool
JP4438457B2 (en) Storage area allocation method, system, and virtualization apparatus
JP5320678B2 (en) Data distribution storage system, data distribution method, apparatus used therefor, and program thereof
JP4437650B2 (en) Storage system
JP6109293B2 (en) Method, system, and computer program for maintaining data redundancy in a data deduplication system in a computing environment
KR100771519B1 (en) Memory system including flash memory and merge method of thereof
KR101769883B1 (en) Apparatus, system, and method for allocating storage
JP3715000B2 (en) Method for selecting data in a data storage device
US7051155B2 (en) Method and system for striping data to accommodate integrity metadata
US9547459B1 (en) Techniques for data relocation based on access patterns
JP6326378B2 (en) Hybrid storage aggregate block tracking
JP4890160B2 (en) Storage system and backup / recovery method
US5881311A (en) Data storage subsystem with block based data management
US6098119A (en) Apparatus and method that automatically scans for and configures previously non-configured disk drives in accordance with a particular raid level based on the needed raid level
US7594075B2 (en) Metadata for a grid based data storage system
JP2010211681A (en) Storage device and virtual device

Legal Events

Date Code Title Description
A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20090414

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20090615

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20090707

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20090715

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120724

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120724

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130724

Year of fee payment: 4

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313111

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313111

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350