Patent Document

CROSS-REFERENCE TO RELATED PATENT APPLICATIONS 
       [0001]    Japan Priority Application 2006-092236, filed Mar. 29, 2006 including the specification, drawings, claims and abstract, is incorporated herein by reference in its entirety. This application is a Continuation of U.S. application Ser. No. 12/702,933, filed Feb. 9, 2010, which is a Continuation of U.S. application Ser. No. 12/453,042, filed Apr. 28, 2009, which is a Continuation of U.S. application Ser. No. 11/439,138, filed May 24, 2006. All of the aforesaid applications are incorporated herein by reference in their entirety as if fully set forth herein. 
     
    
     BACKGROUND OF THE INVENTION 
       [0002]    The present invention is suited for use in a storage apparatus with a virtual/logical volume to which a dynamically variable storage area is allocated, the volume being provided to a host computer. 
         [0003]    In recent years, storage apparatuses providing a host computer with storage areas for storing data have been able to include quite a large number of large-capacity disk drives, and the storage apparatus capacity has been expanding. This type of storage apparatus is operated so that: a disk array configured based on RAID (Redundant Array of Independent Disks) is generated from several disk devices; a plurality of so generated physical storage resources is then collected to make a physical/logical volume; and a storage area of a capacity needed by a host computer is taken out from that physical/logical volume to make a logical volume to be provided to the host computer. 
         [0004]    Furthermore, another type of storage apparatus has recently been proposed where, instead of making a logical volume of a fixed capacity from a physical/logical volume, a host computer is initially provided with a virtually defined logical volume (hereinafter referred to as a virtual/logical volume), and, in response to the host computer&#39;s command, a dynamically variable storage area is allocated from a physical/logical volume (i.e., a physical resource) in particular units to that virtual/logical volume, thereby the storage capacity being dynamically expanded. 
         [0005]    For example, JP Patent Laid-Open Publication No. 2003-015915 discloses a storage apparatus that provides each host computer with a corresponding virtual/logical volume made of a plurality of disk memory devices; obtains the read/write target logical block address from a command from the host computer directed to the virtual/logical volume; and if the virtual/logical volume has no storage area associated with the logical block address that has been specified by the command, allocates a storage area from unused magnetic disk memory devices so that the storage area for the virtual/logical volume is dynamically expanded. 
         [0006]    However, the above storage apparatus disclosed by JP Patent Laid-Open Publication No. 2003-015915 is configured to allocate a storage area to the virtual/logical volume in predetermined fixed units of allocation. So, if the fixed allocation unit size for the storage area for storing data sent from the host computer is large, that large portion of the storage area will be allocated even when a small piece of data is sent from the host computer, resulting in lower storage area operation efficiency. 
         [0007]    On the other hand, in the storage apparatus disclosed by JP Patent Laid-Open Publication No. 2003-015915, the fixed allocation unit size for the storage area for storing data sent from the host computer is small, it is necessary to increase the number of management bits for managing the storage area allocated, and huge memory capacity is required to maintain those management bits. 
       SUMMARY OF THE INVENTION 
       [0008]    Considering the above, the present invention aims at proposing a storage apparatus and a storage area allocation method that can greatly improve storage area operation efficiency. 
         [0009]    In order to solve the above-described problems, the present invention provides a storage apparatus provided with a storage area for storing data sent from a host computer, and a virtual/logical volume to which a dynamically variable storage area is allocated from within the storage area, the volume being provided to the host computer, and the storage apparatus including: a pool area generation unit for generating a plurality of pool areas, each composed from the storage area; a setting unit for setting for each of the plurality of pool areas generated by the pool area generation unit, an allocation unit size for allocating a storage area from within the storage area provided by the pool area to the virtual/logical volume; a selecting unit for selecting, when data to be stored in the storage area is sent from the host computer, a pool area from among the plurality of pool areas having the allocation unit size set by the setting unit, in accordance with the size of the sent data; and an allocation unit for allocating a storage area from within the storage area provided by the pool area selected by the selecting unit to the virtual/logical volume. 
         [0010]    Accordingly, it is possible to effectively prevent storage area(s) from being allocated to data sent from the host computer, in units of allocation too large or too small relative to that data size, and allocate a storage area of an appropriate allocation unit size to that data. 
         [0011]    The present invention also provides a storage area allocation method for a storage apparatus provided with a storage area for storing data sent from a host computer, and a virtual/logical volume to which a dynamically variable storage area is allocated from within the storage area, the volume being provided to the host computer, and the storage area allocation method including: a first step of generating a plurality of pool areas, each composed from the storage area; a second step of setting for each of the plurality of pool areas generated in the first step, an allocation unit size for allocating a storage area from within the storage area provided by the pool area to the virtual/logical volume; a third step of, when data to be stored in the storage area is sent from the host computer, selecting a pool area from among the plurality of pool areas having the allocation unit size set in the second step, in accordance with the size of the sent data; and a fourth step of allocating a storage area from within the storage area provided by the pool area selected in the third step to the virtual/logical volume. 
         [0012]    Accordingly, it is possible to effectively prevent storage area(s) from being allocated to data sent from the host computer, in units of allocation too large or too small relative to that data size, and allocate a storage area of an appropriate allocation unit size to that data. 
         [0013]    According to the present invention, by generating a plurality of pool areas, each composed from a storage area; setting for each of the plurality of pool areas, an allocation unit size for allocating a storage area from within the storage area provided by the pool area to the virtual/logical volume; selecting, when data to be stored in the storage area is sent from the host computer, one pool area from among the plurality of pool areas in accordance with the size of the sent data; and allocating a storage area from within the storage area provided by that selected pool area to the virtual/logical volume, it is possible to effectively prevent storage area(s) from being allocated to data sent from the host computer, in units of allocation too large or too small relative to that data size, and allocate a storage area of an appropriate allocation unit size to that data. As a result, a storage apparatus and a storage area allocation method that can greatly improve storage area operation efficiency can be achieved. 
     
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         [0014]      FIG. 1  briefly shows the storage system configuration according to embodiments of the invention; 
           [0015]      FIG. 2  is a schematic view briefly illustrating the content of allocation processing according to a first embodiment of the invention; 
           [0016]      FIG. 3  is a schematic view for explaining various tables and programs in shared memory; 
           [0017]      FIG. 4  is a schematic view for explaining a mapping table; 
           [0018]      FIG. 5  is a schematic view for explaining a pool area management table; 
           [0019]      FIG. 6  is a schematic view for explaining a virtual/logical volume management table; 
           [0020]      FIG. 7  is a schematic view for explaining a logical volume configuration table; 
           [0021]      FIG. 8  is a schematic view briefly illustrating the storage area allocation status in an unused storage area management bitmap; 
           [0022]      FIG. 9  is a schematic view for explaining the storage area allocation status in an unused storage area management bitmap; 
           [0023]      FIG. 10  is a flowchart for explaining pool area generation processing; 
           [0024]      FIG. 11  is a flowchart for explaining virtual/logical volume generation processing; 
           [0025]      FIG. 12  is a flowchart for explaining command processing for data write; 
           [0026]      FIG. 13  is a schematic view briefly illustrating the content of allocation processing according to a second embodiment; 
           [0027]      FIG. 14  is a schematic view for explaining various tables and programs in shared memory; 
           [0028]      FIG. 15  is a schematic view for explaining a mapping table; 
           [0029]      FIG. 16  is a flowchart for explaining virtual/logical volume generation processing; 
           [0030]      FIG. 17  is a flowchart for explaining command processing for data write; 
           [0031]      FIG. 18  is a schematic view briefly illustrating the content of allocation processing in a mainframe-type computer system; and 
           [0032]      FIG. 19  is a schematic view briefly illustrating the content of allocation processing in an open-type computer system. 
       
    
    
     DETAILED DESCRIPTION OF THE INVENTION 
       [0033]    Embodiments of this invention are described below in detail with reference to the attached drawings. 
       (1) First Embodiment 
     (1-1) Storage System Configuration According to a First Embodiment 
       [0034]      FIG. 1  shows the configuration of a storage system  1  according to a first embodiment. The storage system  1  is configured to include a plurality of host computers  2  connected to a storage apparatus  4  via a network  3 . 
         [0035]    The host computers  2 , each as a host system, are computer devices equipped with a CPU (Central Processing Unit), memory and other information processing resources, and they are configured to be, for example, personal computers, workstations, mainframe computers, or similar. Each host computer  2  has data input devices, such as a keyboard, switch, pointing device, or microphone (not shown in the drawing), and data output devices, such as a monitor display or speaker (not shown in the drawing). 
         [0036]    The network  3  is configured to be, for example, a SAN (Storage Area Network), LAN (Local Area Network), internet, public line, dedicated line, or similar. Communication between the host computers  2  and the storage apparatus  4  via the network  3  is performed in accordance with, for example, Fibre Channel Protocol if the network  3  is a SAN, and TCP/IP (Transmission Control Protocol/Internet Protocol) if the network  3  is a LAN. 
         [0037]    The storage apparatus  4  is configured to have a control unit  10  for controlling data input/output, and a storage device unit  20  constituted by a plurality of disk devices  21  for storing data. 
         [0038]    The control unit  10  is configured to have a plurality of channel adapters  11 , a connecting unit  12 , shared memory  13 , cache memory  14 , a plurality of disk adapters  15  and a management terminal  16 . 
         [0039]    Each channel adapter  11  is configured as a microcomputer system including a microprocessor, memory, a communication interface, etc., and has a port for connection with the network  3 , another storage apparatus, or similar. Each channel adapter  11  interprets various commands sent from the host computers  2  via the network  3  and executes the corresponding processing. The port of each channel adapter  11  is assigned a network address (for example, an IP address or WWN) for identifying themselves, whereby each channel adapter  11  can individually behave as a NAS (Network Attached Storage). 
         [0040]    The connecting unit  12  is connected with each channel adapter  11 , shared memory  13 , cache memory  14  and each disk adapter  15 . Data and commands are transmitted via the connecting unit  12  to and from each channel adapter  11 , shared memory  13 , cache memory  14  and each disk adapter  15 . The connecting unit  12  is configured to be, for example, a switch, such as an ultra-high-speed cross-bus switch that executes data transmission by high-speed switching; a bus; or similar. 
         [0041]    The shared memory  13  and the cache memory  14  are storage memory shared by the channel adapters  11  and the disk adapters  15 . The shared memory  13  is used to store various pieces of system configuration information about the entire configuration of the storage apparatus  4 , and various programs and tables, and it is also used to store various commands including write/read request commands. Various programs and tables stored in the shared memory  13  in this embodiment are explained later. The cache memory  14  is mainly used to temporarily store write/read target data to be input/output to/from the storage apparatus  4 . 
         [0042]    Each disk adapter  15  is configured as a microcomputer system including a microprocessor, memory, etc., and functions as an interface for performing protocol control during communication with the disk devices  21  within the storage device unit  20 . The disk adapters  15  are connected with their corresponding disk devices  21  in the storage device unit  20 , for example, via a Fibre Channel cable, and transmit data to/from those disk devices  21  in accordance with Fibre Channel Protocol. 
         [0043]    The management terminal  16  is a terminal device that controls the overall operation of the storage apparatus  4 , and it is configured to be, for example, a notebook computer. The management terminal  16  is connected with each channel adapter  11  via a LAN  17 , and also connected with each disk adapter  15  via a LAN  18 . An operator can define system configuration information using the management terminal  16 , and can also store the defined system configuration information in the shared memory  13  via the channel adapters  11  or disk adapters  15  and then via the connecting unit  12 . 
         [0044]    A user management terminal  19  is a computer system whereby a user manages the storage apparatus  4  with respect to its status, any change in its configuration, or similar. The user management terminal  19  is connected with the management terminal  16  via a communication network  19 A, and it obtains various information indicating the control status of the storage apparatus  4  through the management terminal  16 , and gives various instructions to the storage apparatus  4  via the management terminal  16 . 
         [0045]    Examples of the disk devices  21  in the storage device unit  20  include expensive disks, such as SCSI (Small Computer System Interface) disks, and inexpensive disks, such as SATA (Serial AT Attachment) disks and optical disks. 
         [0046]    Each disk device  21  in the storage device unit  20  is operated by the control unit  10  based on RAID. In a physical storage area provided by one or more disk devices  21 , one or more logical volumes (hereinafter referred to as physical/logical volume(s)) are established. Data is stored in the physical/logical volume(s) in blocks of a predetermined size (hereinafter referred to as logical block(s)). 
         [0047]    Each logical volume is given its own unique identifier (hereinafter referred to as an LUN (Logical Unit Number)). In this embodiment, an LUN, together with the unique number given to each logical block (LBA: Logical Block Address), constitutes an address, and data input/output is performed designating a specific address of that type. 
       (1-2) Storage Area Allocation Processing in the First Embodiment 
       [0048]    Referring next to  FIGS. 2 through 12 , allocation processing for allocating a storage area to a virtual/logical volume in the storage apparatus  4  in the storage system  1  according to this embodiment will be explained.  FIG. 2  is a schematic view briefly illustrating the content of the allocation processing. 
         [0049]    In this embodiment, the storage apparatus  4  has physical/logical volumes  31  and virtual/logical volumes  33 . Each physical/logical volume  31  is a volume for storing data transmitted from a host computer  2 , and each virtual/logical volume  33  is a volume to which a dynamically variable storage area is allocated from within the storage area provided by the physical/logical volumes  31  with reference to a mapping table  40 , the volume being provided to the host computer  2 . 
         [0050]    The storage apparatus  4  generates a plurality of pool areas  32  for holding physical/logical volumes  31 , and sets, for each pool area  32 , an allocation unit size for allocating a storage area from within the storage area provided by the physical/logical volumes  31  in the pool area  32  to a virtual/logical volume  33 . Also, when data is transmitted from the host computer  2 , the storage apparatus  4  selects, from among the plurality of pool areas  32 , the specific pool area associated with the virtual/logical volume  33 , and allocates a storage area from within that provided by the physical/logical volumes  31  in the selected pool area  32  to that virtual/logical volume  33 . This is one of the features of this embodiment, and further details are explained later. 
         [0051]      FIG. 3  illustrates various programs and tables that are stored in the shared memory  13  and related to the storage area allocation processing according to this embodiment. In this embodiment, the shared memory  13  stores: a mapping table  40 ; pool area management table  50 ; virtual/logical volume management table  60 ; logical volume configuration table  70 ; unused storage area management bitmap  80 ; pool area generation processing program  90 ; virtual/logical volume generation processing program  100 ; and command processing program  110 . Details of the pool area generation processing program  90 , virtual/logical volume generation processing program  100  and command processing  110  are explained later. 
         [0052]      FIG. 4  shows the configuration of the mapping table  40 . The mapping table  40  is generated and managed for each virtual/logical volume  33 , and holds the correlation between that virtual/logical volume  33  and the physical/logical volume(s)  31 . This table is composed of: a virtual/logical volume address field  41 ; physical/logical volume identification number field  42 ; and physical/logical volume address field  43 . 
         [0053]    The virtual/logical volume address field  41  manages the address (e.g. LBA) in the virtual/logical volume  33 . The physical/logical volume identification number field  42  manages the identification number (e.g. LUN) of a physical/logical volume  31  associated with the above virtual/logical volume  33  address. The physical/logical volume address field  43  manages the address (e.g. LBA) in the physical/logical volume  31 , associated with the above virtual/logical volume  33  address. 
         [0054]    In  FIG. 4 , for example, the virtual/logical volume address “0” is associated with the physical/logical volume address “0” in the physical/logical volume  31  having the physical/logical volume identification number “0×0001.” 
         [0055]      FIG. 5  shows the configuration of the pool area management table  50 . The pool area management table  50  is a table for holding the correlation between the pool areas  32  and the physical/logical volumes  31 , and is composed of: a pool area identification number field  51 ; physical/logical volume identification number field  52 ; emulation type field  53 ; physical/logical volume size field  54 ; allocation unit size field  55 ; and unused storage areas field  56 . 
         [0056]    The pool area identification number field  51  manages the identification number of each pool area  32 . The physical/logical volume identification number field  52  manages the identification number of a physical/logical volume  31  held in the pool area  32 . 
         [0057]    The emulation type field  53  manages the type of emulation for the host computer  2  that has sent the data to be stored in the physical/logical volume  31 . Here, “emulation” means executing a software program developed for particular hardware on other hardware with a different configuration. For example, if “OPEN-VP” is stored in the emulation type field  53 , that shows that the storage apparatus  4  has executed “OPEN-V” type software and stored “OPEN-V” emulation type data sent from the host computer  2 . For example, “OPEN-V” and “OPEN- 3 ” are emulation types for a so-called open-type computer system, such as a Windows® system, and the “3390-3” is for a so-called mainframe-type computer system. 
         [0058]    The physical/logical volume size field  54  manages the size of the physical/logical volume  31 . The allocation unit size field  55  manages the allocation unit size for allocating a storage area from within that provided by the physical/logical volume  31  in the pool area  32  to a virtual/logical volume  33 . The unused storage areas field  56  manages the number of unused areas in the storage area, calculated by dividing the size of the physical/logical volume  31  by the allocation unit size for the storage area and then subtracting from the resulting number the used areas. 
         [0059]    As shown in  FIG. 2 , each pool area  32  can hold several physical/logical volumes  31  if data stored in the physical/logical volumes  31  is transmitted from the host computers  2  with the same emulation slot type and if the physical/logical volumes  31  have the same allocation unit size. 
         [0060]    In  FIG. 5 , for example, the pool area  32  having the pool area identification number “0” holds a physical/logical volume  31  having an emulation type of “OPEN-V,” physical/logical volume size of “300G(300 GB)”, “307200” unused storage areas, and physical/logical volume identification number of “0×0001,” and another physical/logical volume  31  having an emulation type of “OPEN-V,” physical/logical volume size of “200G,” “204800” unused storage areas, and physical/logical volume identification number of “0×0002.” Also, a “1M (1 MB)” allocation unit size is established for the above pool area  32 . 
         [0061]      FIG. 6  shows the configuration of the virtual/logical volume management table  60 . The virtual/logical volume management table  60  is a table for holding the correlation between the virtual/logical volumes  33  and the pool areas  32 , and is composed of a virtual/logical volume identification number field  61  and a pool area identification number field  62 . 
         [0062]    The virtual/logical volume identification number field  61  manages the identification number (e.g. LUN) of a virtual/logical volume  33 . The pool area identification number  62  manages the identification number of a pool area  32 , which has been selected by a user and associated with the virtual/logical volume  33  identification number. 
         [0063]    In  FIG. 6 , for example, the virtual/logical volume  33  having the virtual/logical volume identification number “0×0100” is associated with the pool area  32  having the pool area identification number “0.” 
         [0064]      FIG. 7  shows the configuration of the logical volume configuration table  70 . The logical volume configuration table  70  is a table for holding the respective configurations of the physical/logical volumes  31  and virtual/logical volumes  33 , and their correlation with the host computers  2 . This table is composed of: a logical volume identification number field  71 ; emulation type field  72 ; logical volume size field  73 ; and connection port identification number field  74 . 
         [0065]    The logical volume identification number field  71  manages the identification number (e.g. LUN) of a physical/logical volume  31  or virtual/logical volume  33 . The emulation type field  72  manages the type of emulation for the host computer  2  that has sent the data to be stored in the physical/logical volume  31  or virtual/logical volume  33 . The logical volume size field  54  manages the size of the physical/logical volume  31  or virtual/logical volume  33 . The connection port identification number field  74  manages the connection port for connection with the host computer  2 . 
         [0066]    In  FIG. 7 , for example, the virtual/logical volume  33  having the logical volume identification number “0×0100” has the emulation type “OPEN-V”, logical volume size of “500 G,” and connection port “1A.” 
         [0067]      FIG. 8  is a schematic view briefly illustrating the unused storage area management bitmap  80 . An unused storage area management bitmap  80  is prepared for each physical/logical volume  31 , managing whether the physical/logical volume addresses in the physical/logical volume  31  have been allocated to a virtual/logical volume  33  or not. In the unused storage area management bitmap  80  shown in  FIG. 8 , a shaded portion of the storage area shows that the corresponding physical/logical volume address has been allocated to a virtual/logical volume  33 , and a non-shaded portion of the storage area shows that the corresponding physical/logical volume address has not been allocated to any virtual/logical volume  33 . 
         [0068]      FIG. 9  shows the unused storage area management bitmap  80  in actual operation. The unused storage area management bitmap  80 , in actual operation, manages the shaded portions of the storage area in  FIG. 8 , whose corresponding physical/logical volume addresses have been allocated to a virtual/logical volume  33 , as “Bit On (1)” showing being “in-use,” and the non-shaded portions of the storage area in  FIG. 8 , whose corresponding physical/logical volume addresses have not been allocated to a virtual/logical volume  33 , as “Bit Off (0)” showing being “unused.” 
         [0069]    Next, pool area generation processing in the storage system  1  according to the first embodiment will be explained.  FIG. 10  is a flowchart showing the specific procedure executed by the storage apparatus  4  for the pool area generation processing in the storage system  1 . 
         [0070]    Upon system boot-up, a channel adapter  11  in the storage apparatus  4  executes the pool area generation processing program  90  for generating a pool area  32  for holding physical/logical volumes  31 , and, in accordance with the pool area generation procedure RT 1  shown in  FIG. 10 , waits in standby mode to receive a pool area generation command via the management terminal  16  from a user at the user management terminal  19  (S 1 ). 
         [0071]    A pool area generation command, for example, includes information specified by a user, such as the pool area identification number of a pool area  32  to be generated, and the allocation unit size for allocating a storage area from within that provided by the physical/logical volumes  31  in the generated pool area  32  to a virtual/logical volume  33 , and also the configuration information (physical/logical volume identification number, emulation type, and physical/logical volume size) regarding the physical/logical volumes  31  held in the generated pool area  32 , which is obtained and specified by referring in advance to the physical/logical volumes  31  in the logical volume configuration table  70  shown in  FIG. 7 . 
         [0072]    When the channel adapter  11  receives a pool area generation command from the user management terminal  19  via the management terminal  16  ( 51 : YES), it generates and initializes an unused storage area management bitmap  80  (S 2 ). 
         [0073]    More specifically, according to the received pool area generation command, the channel adapter  11  generates an unused storage area management bitmap  80  for every physical/logical volume  31  specified by the user, and updates the unused storage area management bitmap  80  by setting “1” for the management status of a physical/logical volume address whose corresponding storage area already has data stored therein, and setting “0” for the management status of a physical/logical volume address whose corresponding storage area has no data stored therein. 
         [0074]    The channel adapter  11  then generates, or updates, a pool area management table  50 , in accordance with the pool area generation command received from the user management terminal  19  via the management terminal  16  “(S 3 ). 
         [0075]    More specifically, if no pool area management table  50  has yet been generated, the channel adapter  11  generates a pool area management table  50 , and, according to the pool area generation command, stores the configuration information regarding the physical/logical volumes  31 , the pool area identification number and allocation unit size, which have been specified by the user, in the corresponding fields of the pool area management table  50 . Also, based on the physical/logical volume size and the allocation unit size, and the unused storage area management bitmap  80 , the channel adapter  11  calculates the unused storage areas for each physical/logical volume  31 , and stores the resulting value in the corresponding field of the pool area management table  50 . 
         [0076]    If a pool area management table  50  has already been generated, the channel adapter  11  updates the pool area management table  50  by storing, according to the pool area generation command, the configuration information regarding the physical/logical volumes  31 , the pool area identification number and allocation unit size, which have&#39;been specified by the user, in the corresponding fields of the pool area management table  50 , and also by calculating the unused storage areas for each physical/logical volume  31 , based on the physical/logical volume size and the allocation unit size, and the unused storage area management bitmap  80 , and storing the resulting value in the corresponding field of the pool area management table  50 . 
         [0077]    The channel adapter  11  thereafter ends the pool area generation procedure RT 1  shown in  FIG. 10  (S 4 ). 
         [0078]    Next, virtual/logical volume generation processing in the storage system  1  according to the first embodiment will be explained.  FIG. 11  is a flowchart illustrating the specific procedure executed by the storage apparatus  4  for the virtual/logical volume generation processing in this storage system  1 . 
         [0079]    Upon system boot-up, a channel adapter  11  executes the virtual/logical volume generation processing program  100  for generating a virtual/logical volume  33 , and, in accordance with the virtual/logical volume generation procedure RT 2  shown in  FIG. 11 , waits in standby mode to receive a virtual/logical volume generation command via the management terminal  16  from a user at the user management terminal  19  (S 11 ). 
         [0080]    A virtual/logical volume generation command, for example, includes information, such as: the virtual/logical volume identification number of a virtual/logical volume  33  to be generated; the virtual/logical volume size of the virtual/logical volume  33  to be generated; the connection port for connecting the virtual/logical volume  33  to be generated to the host computer  2 ; the pool area identification number of the pool area to be associated with the virtual/logical volume  33  to be generated; and the allocation unit size for when a storage area is to be allocated to the virtual/logical volume  33  to be generated, all specified by a user. 
         [0081]    When the channel adapter  11  receives a virtual/logical volume generation command via the management terminal  16  from a user at the user management terminal  19  (S 11 : YES), the channel adapter  11  checks whether the virtual/logical volume generation command specifies a pool area identification number (S 12 ). 
         [0082]    If the virtual/logical volume generation command does not specify a pool area identification number (S 12 : NO), the channel adapter  11  obtains a pool area identification number with the specified allocation unit size (S 13 ). 
         [0083]    More specifically, for example, if the virtual/logical volume generation command specifies an allocation unit size of “1 M,” the channel adapter  11  refers to the pool area management table  50 , and obtains the pool area identification number “0,” whose corresponding allocation unit size field  55  stores “1 M.” 
         [0084]    Here, if the allocation unit size specified by the virtual/logical volume generation command is not managed in the pool area management table  50 , the channel adapter  11  obtains the pool area identification number having the allocation unit size closest to the specified size. 
         [0085]    Meanwhile, if the virtual/logical volume generation command specifies a pool area identification number (S 12 : YES), or if the channel adapter  11  has obtained a pool area identification number with the specified allocation unit size (S 13 ), the channel adapter  11  generates, or updates, a virtual/logical volume management table  60 , in accordance with the virtual/logical volume generation command received from the host computer  2  (S 14 ). 
         [0086]    More specifically, if no virtual/logical volume management table  60  has yet been generated, the channel adapter  11  generates a virtual/logical volume management table  60 , and, according to the virtual/logical volume generation command, stores the virtual/logical volume identification number specified by the user, and the pool area identification number specified by the user or obtained from the pool area management table, in the corresponding fields of the virtual/logical volume management table  60 . 
         [0087]    If a virtual/logical volume management table  60  has already been generated, the channel adapter  11  updates the virtual/logical volume management table  60  by storing, according to the virtual/logical volume generation command, the virtual/logical volume identification number specified by the user, and the pool area identification number specified by the user or obtained from the pool area management table, in the corresponding fields of the virtual/logical volume management table  60 . 
         [0088]    Accordingly, using the above virtual/logical volume management table  60 , the channel adapter  11  can select, from among a plurality of pool areas  32 , the specific pool area for a virtual/logical volume  33 , the pool area holding a physical/logical volume  31  from which a storage area is to be allocated to the virtual/logical volume  33 . 
         [0089]    The channel adapter  11  then generates a mapping table  40  in accordance with the pool area generation command received from the user management terminal  19  via the management terminal  16  (S 15 ). More specifically, the channel adapter  11  generates a mapping table  40  for each generated virtual/logical volume  33 , and, in accordance with the virtual/logical volume generation command, stores the virtual/logical volume addresses corresponding to the virtual/logical volume size specified by the user, in the corresponding fields of the mapping table  40 . 
         [0090]    Then, the channel adapter  11  updates the logical volume configuration table  70  in accordance with the pool area generation command received from the user management terminal  19  via the management terminal  16  (S 16 ). More specifically, the channel adapter  11  stores, in accordance with the virtual/logical volume generation command, the virtual/logical volume identification number (logical volume identification number), virtual/logical volume size (logical volume size) and connection port, which have been specified by the user, in the corresponding fields of the logical volume configuration table  70 . The channel adapter  11  also refers to the virtual/logical volume management table  60 , finds the pool area identification number associated with the above virtual/logical volume identification number, and then stores the emulation type for that pool area identification number in the corresponding field of the logical volume configuration table  70 . 
         [0091]    The channel adapter  11  thereafter ends the virtual/logical volume generation procedure RT 2  shown in  FIG. 11  (S 17 ). 
         [0092]    Next, command processing in response to a data write request in the storage system  1  according to the first embodiment will be explained.  FIG. 12  is a flowchart describing the specific procedure executed by the storage apparatus  4  for the command processing in response to a data write request in the storage system  1 . 
         [0093]    Upon system boot-up, a channel adapter  11  executes the command processing program  110  for writing data to a storage area in response to a data write request command received from the host computer  2 , and, in accordance with the data write request command procedure RT 3  shown in  FIG. 12 , waits in standby mode to receive a data write request command from a user at the host computer  2  (S 21 ). 
         [0094]    When the channel adapter  11  receives a data write request command from a host computer  2  (S 21 : YES), the channel adapter  11  checks whether a storage area in a physical/logical volume  31  has been allocated to the virtual/logical volume address in the virtual/logical volume  33  (S 22 ). 
         [0095]    More specifically, the channel adapter  11  refers to the mapping table  40 , and checks whether the virtual/logical volume address, to which the write target data included in the received data write request command is to be written, is associated with a physical/logical volume identification number and a physical/logical volume address. 
         [0096]    Then, if no storage area in a physical/logical volume  31  has been allocated to the virtual/logical volume address in the virtual/logical volume  33  (S 22 : NO), the channel adapter  11  checks whether the physical/logical volumes  31  in the pool area  32  associated with that virtual/logical volume  33  have any unused storage areas or not (S 23 ). 
         [0097]    More specifically, the channel adapter  11  refers to the virtual/logical volume management table  60  to obtain the pool area identification number associated with that virtual/logical volume identification number, and then refers to the pool area management table  50  to check whether any unused storage areas are stored in the relevant field associated with the above-obtained pool area identification number. 
         [0098]    If the physical/logical volumes  31  in the pool area  32  associated with the virtual/logical volume  33  have no unused storage area (S 23 : NO), the channel adapter  11  closes the physical/logical volumes  31  in that pool area  32 , and then ends the data write request command procedure RT 3  shown in  FIG. 12  (S 27 ). 
         [0099]    Meanwhile, if the physical/logical volumes  31  in the pool area  32  associated with that virtual/logical volume  33  have any unused storage area (S 23 : YES), the channel adapter  11  updates the mapping table  40  and allocates a storage area from within that provided by the physical/logical volumes  31  in the pool area  32  associated with the virtual/logical volume  33  (S 24 ). 
         [0100]    More specifically, the channel adapter  11  refers to the unused storage area management bitmap  80  to determine the starting physical/logical volume address of a storage area to be allocated, and then refers to the mapping table  40  and updates it by storing the physical/logical volume identification number and the physical/logical volume address of the storage area to be allocated in the physical/logical volume  31 , respectively in the relevant fields associated with the target virtual/logical volume address in the mapping table  40 . 
         [0101]    In the above, the channel adapter  11  is configured to allocate, if several physical/logical volumes have unused storage areas, a storage area from within that provided by the physical/logical volume  31  having the largest unused storage areas. 
         [0102]    The channel adapter  11  next changes the unused storage area management bitmap  80  in connection with the update of the mapping table  40  (S 25 ). More specifically, the channel adapter  11  refers to the mapping table  40 , and changes the unused storage area management bitmap  80  by changing the management status of the physical/logical volume address of the allocated storage area in the physical/logical volume  31  to “1” in the unused storage area management bitmap  80 . 
         [0103]    Meanwhile, if a storage area in a physical/logical volume  31  has already been allocated to the virtual/logical volume address in the virtual/logical volume  33  (S 22 : YES), or if the channel adapter  11  has allocated a storage area to the virtual/logical volume  33 , updated the mapping table  40  and changed the unused storage area management bitmap  80  (S 24 , S 25 ), the channel adapter  11  writes the write target data in the storage area in the physical/logical volume  31 , which is associated with the write target virtual/logical volume address (S 26 ). 
         [0104]    The channel adapter  11  thereafter ends the data write request command procedure RT 3  shown in  FIG. 12  (S 27 ). 
         [0105]    As explained above, in the storage system  1 , a plurality of pool areas  32  is generated for holding physical/logical volumes  31 , and an allocation unit size is set for each pool area  32 , the allocation unit size being used for allocating a storage area from within that provided by the physical/logical volumes  31  in the pool area  32  to a virtual/logical volume  33 . When data is transmitted from the host computer  2 , the specific pool area associated with the virtual/logical volume  33  is selected from among the plurality of pool areas  32 , and a storage area from within that provided by the physical/logical volumes  31  in the selected pool area  32  is allocated to that virtual/logical volume  33 . 
         [0106]    Accordingly, in the storage system  1 , it is possible to effectively prevent storage area(s) from being allocated to data sent from the host computer, in units of allocation too large or too small relative to that data size, and allocate a storage area of an appropriate allocation unit size to that data. As a result, the efficient operation of the physical/logical volume storage area can be achieved. 
       (2) Second Embodiment 
       [0107]    A storage system  120  according to a second embodiment has almost the same configuration as the storage system  1  according to the first embodiment, except that: it has a mapping table  40  with a different configuration; it includes a virtual/logical volume generation processing program  100  and command processing  110  with different content; and it has no virtual/logical volume management table  60 . 
         [0108]    Allocation processing for allocating a storage area to a virtual/logical volume in the storage apparatus  130  in the storage system  120  according to this embodiment will be explained below with reference to  FIGS. 13 to 17 .  FIG. 13  is a schematic view briefly illustrating the content of that allocation processing. 
         [0109]    in this embodiment, the storage apparatus  130  generates a plurality of pool areas  32  for holding physical/logical volumes  31 , and sets, for each pool area  32 , an allocation unit size for allocating a storage area from within the storage area provided by the physical/logical volumes  31  in the pool area  32  to a virtual/logical volume  33 . When data is transmitted from the host computer  2 , the storage apparatus  130  selects one pool area  32  from among the plurality of pool areas  32  according to the size of the transmitted data, and allocates a storage area from within that provided by the physical/logical volumes  31  in the selected pool area  32  to the virtual/logical volume  33 . This is one of the features of this embodiment, and the detailed procedures are explained later. 
         [0110]      FIG. 14  shows various programs and tables that are stored in the shared memory  13  and related to the storage area allocation processing according to this embodiment. In this embodiment, the shared memory  13  stores: a mapping table  140 ; pool area management table  50 ; logical volume configuration table  70 ; unused storage area management bitmap  80 ; pool area generation processing program  90 ; virtual/logical volume generation processing program  150 ; and command processing program  160 . Details of the virtual/logical volume generation processing program  150  and command processing program  160  are explained further below. 
         [0111]      FIG. 15  shows the configuration of the mapping table  140 . The mapping table  140  is prepared and managed for each virtual/logical volume  33 , and holds the correlation between the virtual/logical volume  33  and the physical/logical volume(s)  31 . This table is composed of: a virtual/logical volume address field  141 ; physical/logical volume identification number field  142 ; physical/logical volume address field  143 ; and allocation unit size field  144 . 
         [0112]    The virtual/logical volume address field  41  manages the address (for example, LBA) in the virtual/logical volume  33 . The physical/logical volume identification number field  142  manages the identification number (for example, LUN) of a physical/logical volume  31  that has been associated with the above virtual/logical volume  33  address. The physical/logical volume address field  143  manages the starting address (for example, starting LBA) in the physical/logical volume  31 , associated with the above virtual/logical volume  33  address. The allocation unit size field  144  manages the allocation unit size for allocating a storage area from within that provided by the physical/logical volumes  31  in the pool area  32  to a virtual/logical volume  33 . 
         [0113]    In  FIG. 15 , for example, the virtual/logical volume address “0” is associated with a storage area in the physical/logical volume  31  having a physical/logical volume identification number of “0×0007,” and of an allocation unit size of “1 M” from the physical/logical volume starting address “0.” 
         [0114]    In the storage system  120 , where one virtual/logical volume address area corresponds to, for example, a 256 KB data size, if a 1 MB data write request command is received from the host computer  2 , the 1 MB data write is performed from the allocated physical/logical volume starting address with the allocated physical/logical volume identification number, and that data write is managed in the mapping table  140 . 
         [0115]    In an open-type computer system, data read/write is performed, for example, from the “n”th logical block, for “m” logical blocks (one logical block being 512 KB). So, if the storage system  120  is in an open-type computer system environment, when searching for an unused storage area, the storage system  120  searches for a storage area having a physical/logical volume starting address of “512×n” and an allocation unit size of “512×m,” and then checks whether the physical/logical volume addresses included in that storage area are managed as “unused” or not. 
         [0116]    In a mainframe-type computer system, data read/write is performed, for example, by designating the “m”th disk device  21  in the “n”th cylinder. So, if the storage system  120  is in a mainframe-type computer system environment, when searching for an unused storage area, the storage system  120  determines the target physical/logical volume starting address by aggregating all disk devices  21 . More specifically, the storage system  120  checks whether the addresses following the starting address of “(n×15+m)×emulation-type-based size (48 KB for the 3380-type, and 57 KB for the 3390-type)” are managed as “unused” or not. 
         [0117]    Next, virtual/logical volume generation processing in the storage system  120  according to the second embodiment will be explained.  FIG. 16  is a flowchart showing the specific procedure executed by the storage apparatus  130  for the virtual/logical volume generation processing in the storage system  120 . 
         [0118]    Upon system boot-up, a channel adapter  11  executes the virtual/logical volume generation processing program  150  for generating a virtual/logical volume  33 , and, in accordance with the virtual/logical volume generation procedure RT 4  shown in  FIG. 16 , waits in standby mode to receive a virtual/logical volume generation command via the management terminal  16  from a user at the user management terminal  19  (S 31 ). 
         [0119]    A virtual/logical volume generation command, for example, includes information such as: the virtual/logical volume identification number of a virtual/logical volume  33  to be generated; the virtual/logical volume size of the virtual/logical volume  33  to be generated; the connection port for connecting the virtual/logical volume  33  to be generated to the host computer  2 ; and the emulation type of the host computer  2  sending data to be stored in the virtual/logical volume  33  to be generated, all specified by a user. 
         [0120]    When the channel adapter  11  receives a virtual/logical volume generation command via the management terminal  16  from a user at the user management terminal  19  (S 31 : YES), the channel adapter  11  generates a mapping table  40  in accordance with the pool area generation command received from the user management terminal  19  via the management terminal  16  (S 32 ). More specifically, the channel adapter  11  generates a mapping table  140  for each generated virtual/logical volume  33 , and in accordance with the virtual/logical volume generation command, stores the virtual/logical volume addresses corresponding to the virtual/logical volume size specified by the user, in the corresponding fields of the mapping table  140 . 
         [0121]    The channel adapter  11  then updates the logical volume configuration table  70  in accordance with the pool area generation command received from the user management terminal  19  via the management terminal  16  (S 33 ). More specifically, in accordance with the virtual/logical volume generation command, the channel adapter  11  stores the virtual/logical volume identification number (logical volume identification number), virtual/logical volume size (logical volume size), connection port and emulation type, which have been specified by the user, in the corresponding fields of the logical volume configuration table  70 . 
         [0122]    The channel adapter  11  thereafter ends the virtual/logical volume generation procedure RT 4  shown in  FIG. 16  (S 34 ). 
         [0123]    Next, command processing in response to a data write request in the storage system  120  according to the second embodiment will be explained.  FIG. 17  is a flowchart showing the specific procedure executed by the storage apparatus  130  for the command processing in response to a data write request in the storage system  120 . 
         [0124]    Upon system boot-up, a channel adapter  11  executes the command processing program  160  for writing data to a storage area in response to a data write request from the host computer  2 , and in accordance with the data write request command procedure RT 5  shown in  FIG. 17 , waits in standby mode to receive a data write request command from a user at the host computer  2  (S 41 ). 
         [0125]    When the channel adapter  11  receives a data write request command form a host computer  2  (S 41 : YES), the channel adapter  11  checks whether a storage area in a physical/logical volume  31  has been allocated to the virtual/logical volume address in the virtual/logical volume  33  (S 42 ). 
         [0126]    If no storage area in a physical/logical volume  31  has been allocated to the virtual/logical volume address in the virtual/logical volume  33  (S 42 : NO), the channel adapter  11  refers to the pool area management table  50  to obtain the pool area identification number that has the same emulation type as that of the virtual/logical volume  33  and also has the allocation unit size closest to the size of the write target data included in the data write request command (S 43 ). 
         [0127]    Accordingly, by using the pool area management table  50 , the channel adapter  11  can select, from among the pool areas  32 , one pool area holding a physical/logical volume  31  from which a storage area is to be allocated to the virtual/logical volume  33 . 
         [0128]    The channel adapter  11  then checks whether the physical/logical volumes  31  in the pool area  32  associated with the virtual/logical volume  33  have any unused storage areas or not (S 44 ). 
         [0129]    More specifically, the channel adapter  11  refers to the pool area management table  50 , and checks whether any unused storage areas are stored in the relevant field associated with the above pool area&#39;s identification number. 
         [0130]    If the physical/logical volumes  31  in the pool area  32  associated with the virtual/logical volume  33  have no unused storage area (S 44 : NO), the channel adapter  11  closes the physical/logical volumes  31  in that pool area  32 , and then ends the data write request command procedure RT 5  shown in  FIG. 17  (S 48 ). 
         [0131]    Meanwhile, if the physical/logical volumes  31  in the pool area  32  associated with the virtual/logical volume  33  have any unused storage area (S 44 : YES), the Channel adapter  11  updates the mapping table  140  and allocates a storage area from within that provided by the physical/logical volumes  31  n the pool area  32  associated with the virtual/logical volume  33  (S 45 ). 
         [0132]    More specifically, the channel adapter  11  refers to the unused storage area management bitmap  80  to determine the physical/logical volume starting address of a storage area to be allocated, and then refers to the mapping table  140  and updates it by storing the physical/logical volume identification number, the physical/logical volume starting address, and the allocation unit size of the storage area to be allocated in the physical/logical volume  31 , respectively in the relevant fields associated with the target virtual/logical volume address in the mapping table  140 . 
         [0133]    In the above, the channel adapter  11  is configured to allocate, if several physical/logical volumes have unused storage areas, a storage area from within that provided by the physical/logical volume  31  having the largest unused storage areas. 
         [0134]    The channel adapter  11  next changes the unused storage area management bitmap  80  in connection with the update of the mapping table  140  (S 46 ). More specifically, the channel adapter  11  refers to the mapping table  140 , and changes the unused storage area management bitmap  80  by changing the management status of the physical/logical volume address of the allocated storage area in the physical/logical volume  31  to “1” in the unused storage area management bitmap  80 . 
         [0135]    Meanwhile, if a storage area in a physical/logical volume  31  has already been allocated to the virtual/logical volume address in the virtual/logical volume  33  (S 42 : YES), or if the channel adapter  11  has allocated a storage area to the virtual/logical volume  33 , updated the mapping table  140  and changed the unused storage area management bitmap  80  (S 43  through S 46 ), the channel adapter  11  writes the write target data in the storage area in the physical/logical volume  31 , which is associated with the write target virtual/logical volume address (S 47 ). 
         [0136]    The channel adapter  11  thereafter ends the data write request command procedure RT 5  shown in  FIG. 17  (S 48 ). 
         [0137]    As explained above, in the storage system  120 , a plurality of pool areas  32  is generated for holding physical/logical volumes  31 , and an allocation unit size is set for each pool area  32 , the allocation unit size being used for allocating a storage area from within that provided by the physical/logical volumes  31  in the pool area  32  to a virtual/logical volume  33 . When data is transmitted from the host computer  2 , one pool area  32  is selected from among the plurality of pool areas  32  according to the transmitted data size, and a storage area from within that provided by the physical/logical volumes  31  in the selected pool area  32  is allocated to the virtual/logical volume  33 . 
         [0138]    Accordingly, in the storage system  120 , since one pool area  32  is selected from among the plurality of pool areas  32  according to the size of data sent from the host computer  2 , a storage area of an appropriate allocation unit size can be allocated to each piece of the data, and as a result, more efficient operation of the physical/logical volume storage area can be achieved. 
         [0139]    If the above-described embodiments are in a mainframe-type computer system environment, logical volumes are used in order from the top logical volume address to the end address (i.e., sequentially, (1)→(3)), as shown in  FIG. 18 . So, by setting a relatively large allocation unit size, for example, about 1 GB, the storage area in the physical/logical volumes can be more efficiently operated. 
         [0140]    Also, if the above-described embodiments are in an open-type computer system environment, logical volumes is used by intentionally creating an unused storage area between used areas (i.e., randomly, (1)→(3)), as shown in  FIG. 19 . So, by setting a relatively small allocation unit size, for example, around 1-10 MB, the storage area in the physical/logical volumes can be more efficiently operated. 
         [0141]    Moreover, the above-described embodiments may be modified so that, instead of (the allocation unit size) being specified by a user, the storage apparatus automatically determines, based on a command sent from the host computer  2 , whether the host computer  2  is a mainframe-type computer system or an open-type computer system, and if it is a mainframe-type computer system, automatically sets a relatively large allocation unit size, and if it is an open-type computer system, automatically sets a relatively small allocation unit size, enabling the storage area in the physical/logical volumes to be more efficiently operated. 
         [0142]    Also, in the above-described embodiments, if SATA disks are used for disk drives  21  for backup purposes, the storage area in the physical/logical volumes can be more efficiently operated by setting a relatively large allocation unit size. 
         [0143]    Furthermore, in the above-described embodiments, pool area generation commands and virtual/logical volume generation commands are sent via the management terminal  16  from a user at the user management terminal  19 . However, this invention is not limited to that, and pool area generation commands and virtual/logical volume generation commands may be configured to be sent from the management terminal  16 , or various other connection devices. 
         [0144]    The present invention can be applied to various systems with a virtual/logical volume to which a dynamically variable storage area is allocated, the volume being provided to a host computer.

Technology Category: g