This application is related to and claims priority to Japanese patent application no. 2007-224722 filed on Aug. 30, 2007 in the Japan Patent Office, the entire contents of which are incorporated by reference herein.
1. Field
An aspect of the present invention relates to a relay device, a relay method and a relay control program. The present invention relates to a relay device, a relay method and a relay control program with which a higher level device is capable of handling a configuration information update process of a storage medium even when the status of the storage medium changes at frequent intervals.
2. Description of the Related Art
Storage devices have recently, employed Serial Attached SCSI (SAS) or Serial Advanced Technology Attachment (SATA) as connection standards for storage media including hard disks (refer to Japanese Laid-open Patent Publication 2006-072636). For some of the storage devices, configuration information is updated automatically by a control unit, such as a higher level device. The control unit stores connector architecture of the storage medium as the configuration information. When the storage medium is removed or mounted or an error occurs in which data cannot be written on the storage medium, the status of the storage medium changes.
The relay device for relaying data between the higher level device and the storage medium is provided in the storage device. The relay device has a physical port with SAS standard or SATA standard. When a status of a storage medium connected with the physical port changes, the relay device notifies the status change to the higher level device by broadcasting. After receiving the notification, the higher level device obtains the statuses of the storage media via each physical port in the relay device. The higher level device also updates the configuration information according to the obtained information. Thus, the higher level device updates the configuration information stored therein automatically.
However, with the prior art described above, the higher level device cannot complete the configuration information update when the relay device issues the notifications continuously before a preceding configuration information update is completed.
For example, if the higher level device processes a configuration information update once per second and the relay device issues two notifications per second, the higher level device continues to update the configuration information.
As the case described above, when a frequency of the status change of the storage medium is too high, the higher level device is incapable of handling the configuration information updates. Thus, the higher level device always lags behind the latest information of the status change while the status of the storage medium changes. Under the circumstances, a write command may be issued to an unwritable storage medium, resulting in an error.
In accordance with an aspect of the present embodiment, a relay device has a plurality of physical ports connected to a storage medium and relaying data between a higher level device storing configuration information of a storage device and the storage medium, the relay device including a notification unit for issuing a status change notification reporting that a status of the storage medium connected with said physical port changes to said higher level device when the status change of the storage medium is detected, a monitor of status change notification frequency for monitoring whether the frequency of the status change notification informed via said physical port exceeds a specific threshold, and an invalidation unit for invalidating a function of said physical port when said monitor of status change notification frequency detects that the frequency of the status change notification informed via said physical port exceeds the specific threshold.
The above-described embodiments of the present invention are intended as examples, and all embodiments of the present invention are not limited to including the features described above.
Reference may now be made in detail to embodiments of the present invention, examples of which are illustrated in the accompanying drawings, wherein like reference numerals refer to like elements throughout.
Referring to accompanying drawings, a preferred embodiment of the relay device, relay method and relay control program will be described. Accordingly, an embodiment of the invention, as set forth herein, is intended to be illustrative, not limiting.
First, a structure of the storage device having physical ports with SAS or SATA standard and a configuration information update process of the storage device will be disclosed.
As shown in
Controller 200a connects with hard disk drives (HDDs) 31 through 33 and 41 through 43, having interface (I/F) 210 a and RAID-on-chip (hereinafter called RoC) 220a and relay device 300a. Similarly, controller 200b connects with HDDs 31 through 33 and 41 through 43, having I/F 210b and RoC 220b and relay device 300b.
HDDs 31 through 33 and 41 through 43 comply with SAS or SATA. Storage media connected with relay devices 300a and 300b are not limited to the HDDs. Optical disks are also available. I/Fs 210a and 210b transmit data between server 400 and the corresponding RoCs.
RoCs 220a and 220b receive commands issued by server 400 via I/Fs 210a and 210b and execute the commands. For instance, RoCs 220a and 220b obtain data from HDDs 31 through 33 or 41 through 43 via relay devices 300a or 300b on receiving a command to obtain data issued by server 400. Then the RoCs 220a or 220b transmit the obtained data to server 400 via I/Fs 210a and 210b.
RoC 220a stores connector architecture of all storage media included in storage device 100 as the configuration information. With reference to
Relay device 300a relays data between RoC 220a and HDDs 31 through 33 and 41 through 43, and is connected to physical layers (Phys) 11 through 18 and control unit 310a. Similarly, relay device 300b relays data between RoC 220b and HDDs 31 through 33 and 41 through 43, and is connected to Phys 21 through 28 and control unit 310b. Relay devices 300a and 300b are called expanders.
Phys 11 through 18 are physical ports with SAS or SATA, connecting relay device 300a and other devices on a bus. More particularly, Phys 11 through 16 connect with relay device 300a and one of HDDs 31 through 33 and 41 through 43 respectively. Phy 17 connects with relay device 300a and RoC 220a. Phy 18 connects with relay devices 300a and 300b.
Similarly, Phys 21 through 28 are physical ports with SAS or SATA. Phys 21 through 26 connects with relay device 300b and one of HDDs 31 through 33 and 41 through 43. Phy 27 connects with relay device 300b and RoC 220b. Phy 28 connects with relay devices 300b and 300a.
Control unit 310a controls relay device 300a entirely, having notification unit 311a. Notification unit 311a monitors the HDDs via corresponding Phys 11 through 16. When any of HDDs 31 through 33 or 41 through 43 are removed or mounted, or an error such that any of the HDDs 31 through 33 or 41 through 43 become unwritable occurs, notification unit 311a notifies the change of the HDD's status to RoC 220a via Phy 17 by a broadcasting. Hereinafter the case when the storage medium is removed or mounted, or when the storage medium becomes unwritable is referred to as a status change. Notification unit 311a also notifies the status changes to RoC 220b via Phys 18 and 28, control unit 310b and Phy 27. The notification reporting a status change of a storage medium is called a status change notification hereinafter.
In the status change notification, information informing which HDD changes its status is not included. Consequently, RoCs 220a and 220b cannot identify the HDD which changes its status with the status change notification.
Similarly, control unit 310b controls relay device 300b entirely, having notification unit 311b. Notification unit 311b monitors the HDDs via corresponding Phys 21 through 26. When any of the HDDs changes its status, notification unit 311b notifies the status change to RoC 220b via Phy 27 by broadcasting. Notification unit 311b also notifies the status changes to RoC 220a via Phys 28 and 18, control unit 310a and Phy 17.
Referring to
After receiving the status change notification from notification unit 311a, RoC 220a obtains information informing which HDD's status changes via Phy 17, control unit 310a and Phys 11 through 16. At the same time, RoC 220a obtains information informing which HDD's status changes via Phy 17, control unit 310a, Phy 18, Phy 28, control unit 310b and Phys 21 through 26. Then RoC 220a updates the configuration information stored therein according to the information obtained via Phys 11 through 16 and 21 through 26.
After receiving the status change notification from notification unit 311a, RoC 220b obtains information informing which HDD's status changes via Phy 27, control unit 310b and Phys 21 through 26. At the same time, RoC 220b obtains information informing which HDD's status changes via Phy 27, control unit 310b, Phys 28, Phy 18, control unit 310a and Phys 11 through 16. Then RoC 220b updates the configuration information stored therein according to the obtained information. In
Similarly, notification unit 311b monitors HDDs 31 through 33 or 41 through 43 via corresponding Phys 21 through 26. When the status of the HDDs changes, notification unit 311b obtains the information on the change via Phys 21 through 26, and notifies the status change to RoC 220b via Phy 27 concurrently with reporting the change to RoC 220a via Phy 28. As described above, RoCs 220a and 220b update the configuration information on receiving the status change notification according to the information obtained via Phys 11 through 16 and 21 through 26.
In the conventional way, notification units 311a and 311b notify the status change to RoCs 220a and 220b when status of any of the HDDs changes. On receiving the status change notification, RoCs 220a and 220b obtain the information informing which HDD's status changes via Phys 11 through 16 and 21 through 26, updating the configuration information according to the obtained information.
However, for storage device 100 employing the configuration information update process, the higher level device cannot complete the updates when the relay device issues the notifications of status changes continuously before a preceding configuration information update is completed. That is, the information stored in RoCs 220a and 220b lag behind the latest information of the status change while the status of the storage medium is changing. Under the circumstances, a write command may be issued to an unwritable storage medium, resulting in an error.
Next, a brief description of the relay device according to this embodiment will be made.
As shown in
Memory unit 610 stores the frequency of status change notification per unit time for each Phy. Control unit 620 monitors HDDs 31 through 33 via corresponding Phys 11 through 13. When the status of any of the HDDs changes in operation S1, control unit 620 notifies the status change to RoC 220 in operation S2 and updates the frequency of the status change notification stored in memory unit 610 corresponding to the Phy through which the status change is notified in operation S3.
Control unit 620 monitors whether the frequency of the status change notification for each Phy exceeds the predetermined threshold in operation S4. When the frequency of status change notification informed via any of the Phys exceeds the predetermined threshold, the Phy in which the frequency of status change exceeded the predetermined threshold is disabled in operation S5.
The threshold is defined so as to allow RoC 220 to complete the configuration information update process in good time. Disabling a Phy means the Phy's function is invalidated logically. The disabled Phy cannot recognize the storage media connected thereto. Consequently, even if the storage medium status changes control unit 620 cannot detect the status change, and does not notify the status change.
Accordingly, relay device 600 disables the Phy's function if the frequency of the status change notification notified via the Phy exceeds the threshold that is defined so as to allow RoC 220 to complete the configuration information update process in good time. Thus, RoC 220 can catch up with the frequency of the status change of HDDs 31 through 33. Hence, RoC 220 can complete the configuration information update even the statuses of HDDs 31 through 33 change frequently, allowed to keep the configuration information up-to-date. Allowing the RoC 220 to complete the configuration information update helps to avoid issuing a write command to an unwritable storage medium.
Then the structure of the storage device according to this embodiment will be disclosed.
Relay device 600a has memory unit 610a and control unit 620a. Memory unit 610a is a memory device including random access memory (RAM), having status change notification frequency table 611a and threshold table 612a. Similarly, relay device 600b has memory unit 610b and control unit 620b. Memory unit 610b has status change notification frequency table 611b and threshold table 612b.
Status change notification frequency table 611a and threshold table 611b provide information related to the frequency of the status change notifications per unit time notified via each Phy. In
The frequency of the status change notification stored in tables of status change notification frequency 611a and 611b will be reset to zero by corresponding control units 620a or 620b on every unit time. When the unit time of the frequency of status change notification stored in the tables of status change notification frequency 611a and 611b is defined as five seconds, the frequency of status change notification will be reset to zero every five seconds.
Tables of threshold 612a and 612b store the frequency of the status change notification for each Phy. Threshold table 612a shown in
Control unit 620a controls relay device 600a entirely, having notification unit 621a, monitor of status change notification frequency 622a and invalidation unit 623a. Similarly, control unit 620b controls relay device 600b entirely, having notification unit 621b, monitor of status change notification frequency 622b and invalidation unit 623b.
Notification unit 621a monitors HDDs 31 through 33 or 41 through 43 via corresponding Phys 11 through 16. When the status of any of the HDDs changes, the status change is notified to RoC 220a via Phy 17 by broadcasting. Further, notification unit 621a notifies the status change to RoC 220b via Phys 18, 28, 27 and control unit 620b.
After reporting the status change, notification unit 621a updates the frequency of the status change notification stored in status change notification frequency table 611a. For instance, when notification unit 621a detects status changes of HDD 43 five times via Phy 11 in three seconds, notification unit 621a issues status change notifications five times in three seconds. In other words, notification unit 621a updates the frequency of the status change notification informed via Phy 11 stored in status change notification frequency table 611a as 1, 2 . . . 5. As described above, the frequency of status change notification stored in status change notification frequency table 611a is reset to zero on every unit time by control unit 620a. After resetting the frequency of status change notification, notification unit 621a updates the frequency of status change notification corresponding to Phy 11 from zero.
Similarly, notification unit 621b monitors HDDs 31 through 33 or 41 through 43 via corresponding Phys 21 through 26. When the status of any of the HDDs changes, the status change is notified to RoC 220b via Phy 27 by broadcasting. At the same time, notification unit 621b issues the status change notification to RoC 220a via Phys 28, 18, 17 and control unit 620a. After reporting the status change, notification unit 621b updates the frequency of the status change notification stored in status change notification frequency table 611b, corresponding to the Phy through which the status change notification is informed.
Monitor of status change notification frequency 622a monitors whether the frequency of status change notification informed via any of Phys 11 through 16 exceeds the threshold. More specifically, monitor of status change notification frequency 622a compares the frequency of status change notification informed via any of the Phys that is stored in status change notification frequency table 611a with the threshold stored in threshold table 612a. When the frequency of status change notification informed via the Phy exceeds the threshold, monitor of status change notification frequency 622a sends a disablement request of the Phy including the identification number identifying Phy to be disabled to invalidation unit 623a. The identification number may be any value that can identify the Phys uniquely.
Referring to
Meanwhile, the frequency of status change notification “11” informed via Phy 12 exceeds the threshold “10”, therefore monitor of status change notification frequency 622a issues a disablement request of Phy 12 including the identification number of Phy 12 to invalidation unit 623a.
Similarly, monitor of status change notification frequency 622b compares the frequencies of status change notification informed via each of Phys 21 through 26 with the threshold stored in threshold table 612b. When any of the frequencies exceeds the threshold, monitor of status change notification frequency 622b issues a disablement request of the Phy to invalidation unit 623b.
Monitors of status change notification frequency 622a or 622b may monitor tables of status change notification frequency 611a and 611b before notification units 621a or 621b issue a status change notification or after issuing the notification or otherwise at any arbitrarily specified timing, e.g., per second.
When receiving the Phy disablement request from monitor of status change notification frequency 622a, invalidation unit 623a disables the Phy.
In
Similarly, invalidation unit 623b disables a Phy specified with a Phy disablement request on receiving the disablement request issued from monitor of status change notification frequency 622b.
A Phy disablement process executed by relay device 600a will be disclosed.
As shown in
Monitor of status change notification frequency 622a compares the frequencies of status change notification of each of Phys 11 through 16 stored in status change notification frequency table 611a with the threshold stored in threshold table 612a in operation S702.
When the frequency of status change notification corresponding to any Phy exceeds the threshold (operation S703, Yes), monitor of status change notification frequency 622a issues a Phy disablement request including the identification number of the Phy that the frequency of status change notification exceed the thresholds to invalidation unit 623a.
Invalidation unit 623a disables the Phy on receiving the Phy disablement request in operation S704.
In the embodiment describe above, notification units 621a and 621b issue the status change notifications and updates the frequency of status change notification stored in status change notification frequency table 611a or 611b. Monitors of status change notification frequency 622a and 622b compare the frequency of status change notification with the threshold. When the frequency of status change notification exceeds the threshold, a disablement request including the corresponding Phy's identification number is sent to invalidation unit 623a or 623b. Then invalidation units 623a or 623b disables the Phy on receiving the request. Therefore, RoCs 220a and 220b complete the configuration information update if the statuses of HDDs 31 through 33 or 41 through 43 change at very close intervals. Thus, the configuration information is updated to the latest information and issuing a write command to an unwritable storage medium can be avoided.
In the embodiment described above, all Phys has a common threshold. However, this invention is not limited to this embodiment. A threshold may be configured for each Phy. Configuring the threshold for each Phy is effective, specifically, when reliabilities of storage media connected to the Phys differ respectively. Generally, storage media with SATA have lower reliabilities compared with storage media with SAS. Therefore, a status of the storage medium with SATA may change more frequently than the storage medium with SAS. In the consideration of each storage medium's reliability, a threshold of the Phy connected with the storage medium with SATA may set higher compared with the storage medium with SAS.
In this embodiment, when a frequency of status change notification informed via a certain Phy exceeds a specific threshold, the Phy is disabled. However, this invention is not limited to the embodiment described above. A Phy may be disabled when a mean value of frequencies of status change notification informed via each Phy exceeds a threshold.
In examples shown in
8=(5+11+8+8+8+8)/6
which does not exceed the threshold “10” shown in
In the embodiment described above, a Phy is disabled if a frequency of status change notification informed via the Phy exceeds a threshold. However, this invention is not limited to the embodiment. For example, when storage media connected with a Phy constructs RAID and the same data can be obtained from the other storage medium, the Phy is disabled.
For instance, HDDs 42 and 43 shown in
When HDDs 41 through 43 shown in
When determining which Phy will be disabled based on the storage media configuration in RAID as described above, the relay device may obtain configuration information of the storage media in RAID from the configuration information stored in the RoC. Otherwise, the configuration information on RAID may be stored in the memory unit of the relay device.
In the embodiment described above, the frequency of status change notification stored in status change notification frequency table 611a or 611b is reset to zero per unit time. However, the present invention is not limited to the embodiment. Tables of status change notification frequency 611a and 611b may be in any forms in so far as the table provides frequencies of status change notification per unit time.
Referring to
For a configuration of Relay devices 600a and 600b shown in
As shown in
ROM 1030 stores relay control program 1031 serving as control unit 620a and threshold data 1032 serving as threshold table 612a. RAM 1020 stores relay control process 1021 fetched from relay control program 1031 stored in ROM 1030 by CPU 1010 and data of status change notification frequency 1022 serving as status change notification frequency table 611a shown in
Relay control process 1021 loads information read out from threshold data 1032 to RAM 1020 as appropriate and executes various data processes according to the data loaded.
According to the embodiments of the present invention, a higher level device is capable of handling frequently changing status of a storage medium in updating configuration information.
Although a few preferred embodiments of the present invention have been shown and described, it would be appreciated by those skilled in the art that changes may be made in these embodiments without departing from the principles and spirit of the invention, the scope of which is defined in the claims and their equivalents.
Number | Date | Country | Kind |
---|---|---|---|
2007-224722 | Aug 2007 | JP | national |