Serial connection small computer system interface extender and data forwarding method
By connecting the small computer system interface expander in serial, the number of hard disk expansion cabinets connected to the storage device is increased, and data forwarding is performed through the processor, which solves the problem of difficulty in improving fault tolerance in the prior art and achieves efficient storage expansion and fault tolerance.
Patent Information
- Application Number
- CN202510553421.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-29
- Publication Date
- 2025-05-30
- Estimated Expiration
- 2045-04-29
AI Technical Summary
The prior art is difficult to increase the number of hard disk expansion cabinets connected to the storage device as much as possible while increasing the connection between the storage device and the hard disk expansion cabinet to improve the tolerance for failures of the interface line of the serial connection of the small computer system.
It provides a serially connected small computer system interface extender, including multiple serially connected small computer system interfaces, processors, memory and debug serial ports, performs data forwarding through the processor, increases the number of hard disk expansion cabinets connected to the storage device, and reduces the impact of serially connected small computer system interface line failure on the connection.
It effectively increases the number of hard disk expansion cabinets that can be connected to the storage device, expands the storage capacity, and increases tolerance for serially connected small computer system interface failures, reducing the impact of failure on the connection between the storage device and the hard disk expansion cabinet.
Smart Images

Figure CN120067025A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technologies, and particularly to a Serial Attached SCSI (SAS) expander and a data forwarding method. Background Art
[0002] A storage device increases the number of hard disks by connecting to a hard disk expansion enclosure, thereby expanding the storage capacity. In related technologies, the hard disk expansion enclosure and the storage device can be connected in parallel or in series through a Serial Attached SCSI (SAS) cable. Here, SCSI is the Small Computer System Interface. If the hard disk expansion enclosure and the storage device are connected in parallel, since the number of SAS interfaces of the storage device is limited, the number of hard disk expansion enclosures connected to the storage device will be restricted. If the hard disk expansion enclosure and the storage device are connected in series, in the case of a failure of the SAS cable, the hard disk expansion enclosure connected to the faulty SAS cable and the subsequent serially connected hard disk expansion enclosures will all be degraded or lost. Neither serial connection nor parallel connection can increase the number of hard disk expansion enclosures connected to the storage device as much as possible to expand the storage capacity while improving the tolerance of the connection between the storage device and the hard disk expansion enclosure to the failure of the SAS cable. Summary of the Invention
[0003] This application provides a Serial Attached SCSI (SAS) expander and a data forwarding method, which can at least solve the problem in related technologies that it is difficult to increase the number of hard disk expansion enclosures connected to a storage device as much as possible while improving the tolerance of the connection between the storage device and the hard disk expansion enclosure to the failure of the SAS cable.
[0004] This application provides a Serial Attached SCSI (SAS) expander, including: N Serial Attached SCSI (SAS) interfaces, configured to connect at least one storage device and at least one hard disk expansion enclosure managed by the storage device, where one SAS interface connects to one device, and N is a positive integer greater than 1; A processor, configured to run a program to perform: data forwarding between the storage device and the hard disk expansion enclosure managed by the storage device, and / or data forwarding between different hard disk expansion enclosures managed by the storage device; A memory, configured to store the program and relevant information of the N Serial Attached SCSI (SAS) interfaces; A debug serial port, configured to implement the configuration of the N Serial Attached SCSI (SAS) interfaces.
[0005] The present application also provides a storage system, including at least one of any of the above serial attached small computer system interface (SAS) expanders, at least one storage device, and at least one hard disk expander cabinet for storage device management. Each storage device is connected to one or more SAS expanders through a SAS cable. Each hard disk expander cabinet is connected to a SAS expander through a SAS cable.
[0006] The present application also provides a data forwarding method based on any of the above SAS expanders, including: Performing data forwarding between a storage device and a hard disk expander cabinet for storage device management, and / or between different hard disk expander cabinets for storage device management.
[0007] Through the SAS expander provided by the present application, a storage device and a hard disk expander cabinet for storage device management can be connected, and data forwarding between the storage device and the hard disk expander cabinet for storage device management, and / or between different hard disk expander cabinets for storage device management can be performed. In the case where a storage device needs to add a connected hard disk expander cabinet to expand the storage space, the number of hard disk expander cabinets connected to the storage device can be effectively increased through the SAS expander, and the impact of the failure of the SAS cable on the connection between the storage device and the hard disk expander cabinet can be reduced. Therefore, the technical effect of improving the tolerance of the connection between the storage device and the hard disk expander cabinet to the failure of the SAS cable while increasing the number of hard disk expander cabinets connected to the storage device as much as possible can be achieved. BRIEF DESCRIPTION OF THE DRAWINGS
[0008] To more clearly illustrate the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0009] Figure 1 Schematic diagram of series connection of hard disk expander cabinets provided by the related art; Figure 2 Schematic diagram of the structure of a serial attached small computer system interface (SAS) expander provided by some embodiments of the present application; Figure 3 Schematic diagram of the structure of a serial attached small computer system interface (SAS) expander provided by some embodiments of the present application; Figure 4 One of the usage scenario diagrams of the Serial Attached SCSI (SAS) expander provided by some embodiments of the present application; Figure 5 Another usage scenario diagram of the Serial Attached SCSI (SAS) expander provided by some embodiments of the present application; Figure 6 One of the schematic structural diagrams of the Serial Attached SCSI (SAS) expander provided by some embodiments of the present application; Figure 7 Another schematic structural diagram of the Serial Attached SCSI (SAS) expander provided by some embodiments of the present application; Figure 8 Schematic structural diagram of the storage system provided by some embodiments of the present application; Figure 9 Schematic flow diagram of the data forwarding method provided by some embodiments of the present application.
[0010] Description of reference numerals: 100: Serial Attached SCSI (SAS) expander; 101: Serial Attached SCSI (SAS) interface; 102: Processor; 103: Memory; 104: Debug serial port; 105: Motherboard; 106: Heat dissipation module; 107: Power supply module; 200: Storage device; 300: Hard disk expansion enclosure. Detailed implementation manners
[0011] Next, the technical solutions in the embodiments of the present application will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present application.
[0012] It should be noted that in the description of the present application, the terms "include", "comprise" or any other variation thereof are intended to cover a non-exclusive inclusion, such that a process, method, article or device including a series of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article or device. The terms "first", "second", etc. in the present application are used to distinguish similar objects and are not used to describe a specific order or sequence.
[0013] The hard disk expansion enclosure consists of components such as a main board, a backplane, a Serial Attached SCSI (SAS) card, and a power supply. It can usually support 12 3.5-inch hard disks or 25 2.5-inch hard disks. The hard disk expansion enclosure has no Central Processing Unit (CPU) and needs to be connected to the Serial Attached SCSI card of the storage device through a Serial Attached SCSI cable (simply referred to as a Serial Attached SCSI line in the solution of this application) to establish a hardware link with the main board of the storage device. The hard disk expansion enclosure relies on the storage device to manage and use the hard disks. The Serial Attached SCSI can also be called the Serial Attached SCSI interface, where SCSI is the Small Computer System Interface (SCSI).
[0014] The hard disk expansion enclosure can be connected to the Serial Attached SCSI card of the storage device in two ways: parallel or serial. Parallel connection means that multiple hard disk expansion enclosures are independently connected to the Serial Attached SCSI card of the storage device through Serial Attached SCSI cables. However, the number of Serial Attached SCSI cards of the storage device and the number of Serial Attached SCSI interfaces in the Serial Attached SCSI card are limited, which also limits the number of hard disk expansion enclosures connected to the storage device in parallel. If more hard disks need to be managed, the serial connection method is usually adopted. Figure 1 Schematic diagram of the serial connection of the hard disk expansion enclosure provided for the related technology. As Figure 1 shown, after the storage device is connected to the first hard disk expansion enclosure, the second hard disk expansion enclosure is connected to the remaining Serial Attached SCSI interfaces of the first hard disk expansion enclosure through a Serial Attached SCSI cable. Through the above serial connection method, the number of connected hard disk expansion enclosures can reach more than 40, which can meet the common large-scale data storage requirements. However, the serial connection method has a low tolerance for Serial Attached SCSI cable failures (that is, the failure of the Serial Attached SCSI cable has a great impact on the connection between the storage device and the hard disk expansion enclosure). In the case of a failure of the Serial Attached SCSI cable, the hard disk expansion enclosures connected by this Serial Attached SCSI cable and the subsequent serially connected hard disk expansion enclosures will all be degraded or lost. Taking Figure 1 as an example, if the Serial Attached SCSI cable connecting the storage device and the first hard disk expansion enclosure fails, the connection between the storage device and the second hard disk expansion enclosure will also be affected.
[0015] The Serial Attached SCSI (SAS) cable itself contains multiple sub-cables inside. It is thick and not easy to bend, making it inconvenient to cut and reconnect. During the process of connecting or disconnecting storage devices and hard disk expansion enclosures to change the connection relationship, situations such as irregular layout caused by manually deploying the SAS cable and accidental contact between SAS cables are likely to occur.
[0016] The solution of this application solves or partially solves the problems raised above. To enable those skilled in the art of this technology to better understand the solution of this application, the following further detailed description of this application will be given in conjunction with the drawings and specific implementation manners.
[0017] Figure 2 It is one of the structural schematic diagrams of the Serial Attached SCSI (SAS) expander provided for some embodiments of this application. As Figure 2 shown, the Serial Attached SCSI (SAS) expander 100 includes: N Serial Attached SCSI (SAS) interfaces 101, which are used to connect at least one storage device and at least one hard disk expansion enclosure managed by the storage device. Among them, one Serial Attached SCSI (SAS) interface 101 connects to one device, and N is a positive integer greater than 1; A processor 102, which is used to run a program to execute: data forwarding between the storage device and the hard disk expansion enclosure managed by the storage device, and / or data forwarding between different hard disk expansion enclosures managed by the storage device; A memory 103, which is used to store programs and relevant information of the N Serial Attached SCSI (SAS) interfaces 101; A debug serial port 104, which is used to implement the configuration of the N Serial Attached SCSI (SAS) interfaces 101.
[0018] A hard disk expansion enclosure usually includes multiple hard disk slots, and the storage capacity can be expanded by inserting additional hard disks. A common hard disk expansion enclosure such as a Just a Bunch of Disks (JBOD) forms a larger logical storage unit by combining multiple independent hard disks.
[0019] A storage device (which can be simply referred to as storage) refers to a device used to store and manage data, providing functions such as data storage, writing, and reading. Components such as a storage controller and a Serial Attached SCSI (SAS) interface card are included in the storage device. It is connected to the hard disk expansion enclosure through the Serial Attached SCSI (SAS) interface in the Serial Attached SCSI (SAS) interface card, and data forwarding (data forwarding between the storage device and the hard disk expansion enclosure, and / or data forwarding between different hard disk expansion enclosures connected to the storage device) can be performed through the storage controller to manage the hard disk expansion enclosure and achieve the expansion of the storage capacity. The specific type or technical implementation manner of the storage device in the embodiments of this application is not specifically limited.
[0020] The relevant information of the Serial Attached SCSI 101 includes the hardware connection information of the Serial Attached SCSI, the configuration information of the Serial Attached SCSI, and the routing mapping address table of the Serial Attached SCSI, etc. In some embodiments, the processor 102 may perform data forwarding between the devices connected to each Serial Attached SCSI 101 according to the relevant information of each Serial Attached SCSI 101.
[0021] The debug serial port 104 is used to configure the N Serial Attached SCSI 101. In some embodiments, the user is allowed to write a configuration file or configuration information through the debug serial port 104, so as to implement the configuration of each Serial Attached SCSI. The configuration file or configuration information may specifically include the serial number of the Serial Attached SCSI, the active state of the Serial Attached SCSI, the type of the Serial Attached SCSI, the data label of the Serial Attached SCSI, and the rate of the Serial Attached SCSI, etc. Each Serial Attached SCSI 101 is configured through the debug serial port 104, so that the Serial Attached SCSI expander 100 can be applied to different service scenarios.
[0022] In the related art, the storage device and the hard disk expansion cabinet are directly connected in series or in parallel, and the storage device directly manages the connected hard disk expansion cabinet. In the embodiments of the present application, the Serial Attached SCSI expander 100 can be understood as an intermediate node for connecting the storage device and the hard disk expander. Specifically, the storage device and the hard disk expander are respectively connected to different Serial Attached SCSI 101 of the Serial Attached SCSI expander 100, and the processor 102 in the Serial Attached SCSI expander 100 performs data forwarding between the storage device and the hard disk expansion cabinet, and / or when the storage device manages multiple hard disk expansion cabinets, performs data forwarding between different hard disk expansion cabinets. It can be understood that the processor 102 performs the data forwarding service (task) originally performed by the storage device, so that the data forwarding between the hard disk expansion cabinets hardly occupies the processing resources of the storage device, has the advantage of decentralization, reduces the occupation of the processing resources of the storage device by data forwarding, and can effectively improve the service processing efficiency of the storage device.
[0023] Figure 3 This is the second structural schematic diagram of the Serial Attached SCSI expander provided by some embodiments of the present application. In Figure 3Among them, the Serial Attached SCSI 101, processor 102, memory 103, and debug serial port 104 mentioned above are all provided on the main board 105 of the Serial Attached SCSI expander.
[0024] The Serial Attached SCSI expander 100 includes N Serial Attached SCSI interfaces 101, where N is a positive integer greater than 1. Usually, N is a value greater than the number of Serial Attached SCSI interfaces provided by the storage device itself, so that the number of disk expansion enclosures connected and managed by the storage device can be increased as much as possible through the Serial Attached SCSI expander 100. For example, in some embodiments, the value of N is 48.
[0025] In some embodiments, the Serial Attached SCSI interfaces 101 of the Serial Attached SCSI expander 100 are simultaneously connected to multiple storage devices and multiple disk expansion enclosures. Each storage device manages different disk expansion enclosures. It can be considered that a storage device and all the disk enclosures managed by the storage are a group. The specific group division is usually specified by the user, for example, written in advance by the user in the relevant information of the Serial Attached SCSI stored in the memory 103. The processor 102 can implement data isolation between different groups, data forwarding within the same group, etc. (specifically, it can be achieved by adding data tags to the data packets entering each Serial Attached SCSI interface).
[0026] In some embodiments, the Serial Attached SCSI interfaces 101 of the Serial Attached SCSI expander 100 are also connected to other Serial Attached SCSI expanders. The other Serial Attached SCSI expanders can also be connected to more storage devices or hardware expansion enclosures, further increasing the number of disk expansion enclosures connected and managed by the storage device.
[0027] The Serial Attached SCSI (SAS) 101 is connected to each device through an SAS cable. In the embodiment of the present application, if an SAS cable fails, it usually only affects one storage device or one hard disk expansion enclosure connected to the faulty SAS cable, and does not affect the storage devices or hard disk expansion enclosures connected to other SAS 101s of the SAS expander 100. Even if the other end of the faulty SAS cable is connected to another SAS expander, resulting in the loss of the storage devices or hardware expansion enclosures connected to the other SAS expander, compared with the prior art where the failure spreads due to series connection (all subsequent hard disk expansion enclosures of the faulty SAS cable are degraded or lost), the impact of the SAS cable failure on the connection between the storage device and the hard disk expansion enclosure is still reduced. Through the SAS expander 100 provided in the embodiment of the present application, the tolerance of the connection between the storage device and the hard disk expansion enclosure to the SAS cable failure is effectively improved.
[0028] The Serial Attached SCSI (SAS) expander includes N SAS interfaces for connecting at least one storage device and at least one hard disk expander for storage device management. The data forwarding between the storage device, the hard disk expander, and different hard disk expanders is performed by the processor of the SAS expander, where N is a positive integer greater than 1. In the case where N is relatively large, through the SAS expander, the storage device can be connected to and managed by as many hard disk expanders as possible, effectively increasing the number of hard disk expanders that the storage device can connect to and expanding the storage capacity. Although directly connecting the storage device and the hard disk expander in series can also effectively expand the storage capacity, it cannot solve the problem of being greatly affected by the failure of the SAS interface cable. In the above technical solution, each SAS interface of the SAS expander is respectively connected to the storage device and the hard disk expander for storage device management. That is, even if the SAS interface cable used for connection fails, usually only one storage device or hard disk expander connected to the faulty SAS interface cable will be affected, effectively reducing the impact caused by the failure of the SAS interface cable, that is, improving the tolerance to the failure of the SAS interface cable. In summary, through the SAS expander provided by the embodiments of the present application, it is possible to increase the number of hard disk expanders connected to the storage device as much as possible to expand the storage capacity, while improving the tolerance of the connection between the storage device and the hard disk expander to the failure of the SAS interface cable.
[0029] In some embodiments of the present application, the relevant information of the N SAS interfaces 101 includes the hardware connection information of each SAS interface 101. The processor 102 is further configured to: Determine the SAS interfaces 101 with physical connections according to the hardware connection information of each SAS interface 101; Send a session message to the peer device connected to the SAS interfaces 101 with physical connections, and receive the session response message sent by the peer device; Determine the type of the peer device according to the session response message; Add a type tag to each SAS interface 101 with a physical connection according to the type of the peer device. The type tag is used to identify the device type connected to the source SAS interface during the data forwarding process.
[0030] The hardware connection information of each Serial Attached SCSI (SAS) 101 indicates the physical connection status of each SAS 101. In the embodiments of the present application, the hardware connection information of each SAS 101 indicates whether each SAS 101 is physically connected to a peer device through a SAS cable.
[0031] Send a session message to the peer device connected to the SAS 101 with a physical connection. After receiving the session message, the peer device returns session response information. The processor 102 parses and determines the type of the peer device according to the received session response message.
[0032] As in the foregoing embodiments, the peer device connected to the SAS 101 may be a storage device, a hard disk expander, or other SAS expander. Optionally, according to the type of the peer device, add a type label to each SAS 101 with a physical connection. For example, if the peer device connected to the SAS 101 is a storage device, the type label of this SAS 101 is storage; if the peer device connected to the SAS 101 is a hard disk expander, the type label of this SAS 101 is expander; if the peer device connected to the SAS 101 is a SAS expander 100, the type label of this SAS 101 is SAS expander.
[0033] It can be understood that since the types of peer devices connected to each SAS 101 are different and there are multiple application scenarios, each SAS 101 may act as a source SAS in the data forwarding process or as a destination SAS. When the SAS 101 acts as a source SAS, the added type label can be used to accurately identify the type of the peer device connected to the source SAS in the data forwarding process, without having to identify the type of the device connected to the source SAS during data forwarding, and also avoiding problems such as data errors caused by misidentifying the type of the peer device during data forwarding, which helps to improve the reliability and efficiency of the processor 102 in performing data forwarding.
[0034] The relevant information of the Serial Attached SCSI (SAS) provided by the embodiments of the present application includes the hardware connection information of each SAS. The hardware connection information of each SAS can be used to determine the SAS with a physical connection, and then the type of the peer device connected to the SAS with a physical connection can be determined by sending a session message to the peer device, so as to add a type label to each SAS with a physical connection. During the data forwarding process, when a type label is added to the SAS acting as the source SAS, the device type connected to the source SAS can be more effectively identified, which helps to improve the reliability and efficiency of data forwarding.
[0035] In some embodiments of the present application, the relevant information of the N Serial Attached SCSI (SAS) interfaces 101 further includes the first configuration information of the N SAS interfaces 101. The processor 102 is further configured to: According to the first configuration information of the N SAS interfaces 101, determine the data label corresponding to the data packet entering each SAS with a physical connection. The data label is used to identify the storage device to which the data forwarding process belongs.
[0036] The Serial Attached SCSI (SAS) expander 100 includes N SAS interfaces 101, which can be used to connect to storage devices, hardware expansion cabinets for storage device management, or other SAS expanders. Therefore, it is possible that the peer devices connected to multiple SAS interfaces 101 are all storage devices. However, usually, data is not forwarded between a storage device and a hard disk expander not managed by the storage device, or between different hard disk expanders managed by different storage devices. Therefore, before performing data forwarding, the processor 102 needs to determine the data label corresponding to the data packet entering each (physically connected) SAS according to the first configuration information of the N SAS interfaces. These data labels represent the storage device to which the data forwarding process belongs. The processor 102 can then perform data forwarding according to the data label, avoiding the data (data packet) being misforwarded to a storage device or a hard disk expansion cabinet not belonging to the current forwarding process.
[0037] Figure 4 This is one of the usage scenario diagrams of the Serial Attached SCSI (SAS) expander provided by some embodiments of the present application. Figure 4The partial Serial Attached SCSI 101 of the Serial Attached SCSI extender 100 is used to connect the storage device 200 and the hard disk expansion enclosure 300 for storage device management.
[0038] As Figure 4 shown, the first storage device manages the first hard disk expansion enclosure and the second hard disk expansion enclosure. The storage device to which the data forwarding process among the first storage device, the first hard disk expansion enclosure, and the second hard disk expansion enclosure belongs is the first storage device, and the corresponding data label is 1001; The second storage device manages the third hard disk expansion enclosure and the fourth hard disk expansion enclosure. The storage device to which the data forwarding process among the second storage device, the third hard disk expansion enclosure, and the fourth hard disk expansion enclosure belongs is the second storage device, and the corresponding data label is 1002.
[0039] According to the first configuration information of N Serial Attached SCSI 101s, the data label corresponding to the data packet entering each Serial Attached SCSI can be determined. Specifically, still taking Figure 4 as an example, the peer devices connected to Serial Attached SCSI 1 and Serial Attached SCSI 2 are the first storage device, the peer devices connected to Serial Attached SCSI 3 and Serial Attached SCSI 4 are the first hard disk expansion enclosure, and the peer devices connected to Serial Attached SCSI 5 and Serial Attached SCSI 6 are the second hard disk expansion enclosure. Since the first storage device manages the first hard disk expansion enclosure and the second hard disk expansion enclosure, the first configuration information of N Serial Attached SCSI 101s indicates that the data labels corresponding to Serial Attached SCSI 1, Serial Attached SCSI 2, Serial Attached SCSI 3, Serial Attached SCSI 4, Serial Attached SCSI 5, and Serial Attached SCSI 6 are 1001. Furthermore, the processor 102 can determine that the data label corresponding to the data packet entering the above Serial Attached SCSI is 1001 according to the first configuration information.
[0040] Similarly, the first configuration information of the Serial Attached SCSI indicates that the data labels corresponding to Serial Attached SCSI 7, Serial Attached SCSI 8, Serial Attached SCSI 9, Serial Attached SCSI 10, Serial Attached SCSI 11, and Serial Attached SCSI 12 are 1002. Furthermore, the processor 102 can determine that the data label corresponding to the data packet entering the above Serial Attached SCSI is 1002 according to the first configuration information.
[0041] The first configuration information can be configured by the user through the debug serial port 104. After the user determines the connection relationship between the storage devices connected by each Serial Attached SCSI (SAS) 101 and the hard disk expansion enclosures, the user determines the first configuration information and writes it through the debug serial port 104, so that the processor 102 can obtain the first configuration information. In the first configuration information, the data tags corresponding to the SAS 101 to which the same group of devices (a storage device and the hard disk expansion enclosure managed by the storage device are a group) are connected are the same.
[0042] In other words, if the data tags corresponding to different SASs in the first configuration information are the same, it can be recognized that the devices connected to these SASs are the same group of devices. Therefore, by modifying the first configuration information of the SAS, the configuration of the connection relationship between each storage device connected to the SAS and the hard disk expansion enclosure can be realized. Still taking the Figure 4 application scenario shown as an example, if it is currently necessary to also assign the third hard disk expansion enclosure and the fourth hard disk expansion enclosure to be managed by the first storage device (the first storage device manages the first hard disk expansion enclosure, the second hard disk expansion enclosure, the third hard disk expansion enclosure, and the fourth hard disk expansion enclosure), it can be achieved by modifying the data tags corresponding to the SAS 9, SAS 10, SAS 11, and SAS 12 indicated in the first configuration information on the existing basis. The processor 102 can determine that the data tags of the data packets entering these SASs are 1001 according to the first configuration information. Compared with connecting or disconnecting the storage device and the hard disk expansion enclosure to change the connection relationship, modifying the first configuration information avoids the situation of irregular layout and accidental collision between SAS cables caused by manually deploying the SAS cables, and improves the operation and maintenance support ability of the SAS expander. (The above "1", "2", "first", "second", etc. are used to distinguish similar objects, rather than to describe a specific order or sequence).
[0043] In the embodiment of the present application, according to the first configuration information of N SASs, the data tags corresponding to the data packets entering each physically connected SAS are determined. The data tags are used to identify the storage device to which the data forwarding process belongs. The processor can perform data forwarding under the storage device to which the data forwarding process belongs according to the data tags, avoiding the incorrect forwarding of the data in the current data forwarding process to other storage devices or hard disk expansion enclosures managed by other storage devices that do not belong to the current data forwarding process, and realizing the isolation of the data forwarding processes under different storage devices.
[0044] In some embodiments, the processor 102 is configured to perform data forwarding between a storage device and an enclosure for managing the storage device according to a data tag, and / or perform data forwarding between different enclosures for managing the storage device.
[0045] Optionally, the processor 102 performs data forwarding between a storage device and an enclosure for managing the storage device according to a data tag. By using the data tag, it is possible to avoid forwarding data to a storage device identified by a different data tag from this data tag, and it is also possible to avoid forwarding data to an enclosure for managing the storage device identified by a different data tag from this data tag, enabling the serial-attached SCSI expander to isolate the data forwarding process between multiple storage devices and multiple enclosures managed by each storage device, that is, different groups of data isolation is achieved.
[0046] Optionally, the processor 102 performs data forwarding between different enclosures for managing the storage device according to a data tag. By using the data tag, data forwarding between different enclosures under the same data tag is allowed, enabling the serial-attached SCSI expander to achieve data forwarding between multiple enclosures managed by multiple storage devices, that is, data transfer within the same group is achieved.
[0047] Optionally, the processor 102 performs data forwarding between a storage device and an enclosure for managing the storage device according to a data tag, and performs data forwarding between different enclosures for managing the storage device according to a data tag. By using the data tag, the serial-attached SCSI expander can isolate different data forwarding processes.
[0048] In the embodiments of the present application, data forwarding between a storage device and an enclosure for managing the storage device, and / or data forwarding between different enclosures for managing the storage device is performed according to a data tag, enabling the serial-attached SCSI expander to achieve data transfer within the same group and data isolation between different groups. Thus, the serial-attached SCSI expander can connect multiple storage devices and multiple enclosures and can ensure normal data transfer between the storage device and the enclosure.
[0049] In some embodiments, the processor 102 is specifically configured to: Add a data tag to a data packet entering each serial-attached SCSI 101 with a physical connection; Before forwarding the data packet to the destination serial-attached SCSI corresponding to the data packet, delete the data tag in the data packet.
[0050] When the processor performs data forwarding between a storage device and a hard disk expander for storage device management, and / or data forwarding between different hard disk expanders for storage device management, it adds a data label to the data packet entering each Serial Attached SCSI (SAS) with a physical connection (adding a data label can be simply referred to as tagging). The data label identifies the storage device to which the data forwarding process belongs, and can isolate different data forwarding processes. The data packet with the added data label is forwarded to the corresponding destination SAS. Before forwarding, the data label in the data packet is deleted, so that the data packet entering the destination SAS is the original data packet. Thus, the data packet with the added data label is only transmitted inside the SAS expander, without increasing the processing complexity of the devices connected to the destination SAS, and without changing the code of the devices connected to the destination SAS.
[0051] In the embodiments of the present application, a data label is added to the data packet entering each SAS with a physical connection, and the data label in the data packet is deleted before forwarding the data packet to the corresponding destination SAS, so as to avoid the influence of the data label on the recognition of the data packet by the peer device connected to the destination SAS. Through the above method, data forwarding under the storage device to which the current data forwarding process belongs is realized.
[0052] In some embodiments of the present application, the relevant information of the N SASs 101 further includes the routing mapping address table of the N SASs 101, and the processor 102 is further configured to: Obtain the serial number of the destination SAS corresponding to the data packet entering each SAS 101 with a physical connection; Generate a routing mapping address table according to the serial number of the SAS expander 100, the type label, the data label, the serial number of the SAS 101 with a physical connection, and the serial number of the destination SAS.
[0053] When the data packet enters the SAS 101 with a physical connection, the processor 102 needs to obtain the serial number of the destination SAS corresponding to the data packet, which can usually be realized by parsing the data packet. The present application does not specifically limit how to obtain the serial number of the destination SAS.
[0054] The serial number of the Serial Attached SCSI (SAS) expander 100 can be used to identify the SAS expander when a storage device is connected to multiple SAS expanders 100. The type tag is used to identify the type of device connected to the source SAS interface during the data forwarding process, and the data tag is used to identify the storage device to which the data forwarding process belongs. For the explanations of the type tag and the data tag, please refer to the foregoing embodiments, which will not be elaborated herein.
[0055] The data packet enters through the physically connected SAS interface 101. At this time, the physically connected SAS interface 101 serves as the source SAS interface, and the serial number of the physically connected SAS interface 101 is the serial number of the source SAS interface. This serial number can be confirmed according to the configuration information of the physically connected SAS interface 101.
[0056] Table 1 is the routing mapping address table of the SAS interface generated according to the Figure 4 usage scenario of the SAS expander as shown. Table 1 shows the data forwarding process that occurs between the first storage device, the first hard disk expansion cabinet, and the second hard disk expansion cabinet. The data tag for this data forwarding process is 1001 (the data forwarding process that occurs between the second storage device, the third hard disk expansion cabinet, and the fourth hard disk expansion cabinet is not shown).
[0057] Table 1 Routing Mapping Address Table
[0058] In the embodiment of the present application, after obtaining the serial number of the destination SAS interface corresponding to the data packet, the processor generates a routing mapping address table according to the serial number of the SAS expander, the type tag, the data tag, the serial number of the physically connected SAS interface, and the serial number of the destination SAS interface. The routing mapping address table records the path for forwarding the data packet entering through the physically connected SAS interface (from the source SAS interface to the destination SAS interface). The routing mapping address table also includes the data tag and the type tag. If the processor performs data forwarding according to the routing mapping address table, it helps to ensure that the data packet is only transmitted between the storage device to which the data forwarding process belongs and the hard disk expansion cabinets it manages, and / or between different hard disk expansion cabinets it manages.
[0059] In some embodiments of the present application, some of the N Serial Attached SCSI (SAS) interfaces 101 are used to connect to other SAS interface expanders. The processor 102 is further configured to: Obtain second configuration information of a plurality of SAS interfaces corresponding to other SAS interface expanders; Determine, according to the second configuration information, data tags corresponding to data packets of each physically connected SAS interface entering the other SAS interface expander; Execute at least one of the following according to the data tags corresponding to the data packets of each physically connected SAS interface entering the other SAS interface expander: data forwarding across the SAS interface expander, data forwarding between a storage device connected to the other SAS interface expander and a hard disk expander managed by a storage device management, and data forwarding between different hard disk expanders managed by a storage device connected to the other SAS interface expander.
[0060] It can be understood that although the number of SAS interfaces 101 included in the SAS interface expander 100 is generally greater than the number of SAS interfaces 101 provided by the storage device itself, the number of hard disk expanders connected to the storage device can be increased through the SAS interface expander 100 to expand the storage capacity. However, it is still possible that the storage requirements of the storage device cannot be met by a single SAS interface expander. In the above case, the SAS interface expanders are usually cascaded to enable the storage device to connect to more hard disk expanders.
[0061] Exemplarily, the cabinet (the device for loading the storage device and the hard disk expander) is 42U, a storage device is 2 - 4U, and a hard disk expander is 2U. That is, one SAS interface expander in a cabinet can meet the usage of 1 storage device and 10 hard disk expanders. If the current storage device needs to connect to more hard disk expanders, cascading the SAS interface expanders is required. Here, U is the Rack Unit, which represents the vertical height occupied by the device in the rack.
[0062] For example, Figure 5 This is the second usage scenario diagram of the SAS interface expander provided by some embodiments of the present application. As Figure 5 shown, The first Serial Attached SCSI (SAS) expander includes SAS interface 1 to SAS interface N, and the second SAS expander includes SAS interface N to SAS interface 2N. The SAS interface 1 in the first SAS expander is connected to the SAS interface N+1 in the second expander, and the SAS interface 2 in the first SAS expander is connected to the SAS interface N+2 in the second expander.
[0063] Optionally, the second configuration information is configured by the user through the debug serial port of the second SAS expander. After the user determines the relationship between the storage devices and the hard disk expansion enclosures connected to the respective SAS interfaces of the second SAS expander, the second configuration information is determined. The second SAS expander synchronizes this second configuration information to the first expander, so that the processor of the first SAS expander can obtain the second configuration information, and then can obtain the data tags corresponding to the respective SAS interfaces on the second SAS expander. In the second configuration information, the data tags corresponding to the SAS interfaces to which a group of devices (a storage device and the hard disk expansion enclosure managed by the storage device are a group) are connected are the same.
[0064] The processor of the first SAS expander determines the data tags corresponding to the data packets of the respective physically connected SAS interfaces entering the second SAS expander according to the second configuration information of the multiple SAS interfaces of the second SAS expander.
[0065] It can be understood that, since the cascaded SAS expander is adopted (some of the N SAS interfaces in the first SAS expander are used to connect the second SAS expander), it is possible that the devices connected to the SAS interfaces of different SAS expanders are the same group of devices. In other words, the devices configured as the same group by the user may be connected to the SAS interfaces of different SAS expanders, and different SAS expanders are cascaded.
[0066] Thus, among the data tags corresponding to the data packets of each physically connected Serial Attached SCSI (SAS) interface that enter the second SAS interface extender as determined by the processor of the first SAS interface extender according to the second configuration information, there are data tags that are the same as the data tags corresponding to the data packets of each physically connected SAS interface that enter (the first SAS interface extender) according to the first configuration information. In this case, it is necessary for the processor of the first SAS interface extender to perform data forwarding across the SAS interface extenders.
[0067] Optionally, the processor of the first SAS interface extender performs data forwarding across the SAS interface extenders according to the data tags corresponding to the data packets of each physically connected SAS interface that enter the second SAS interface extender. Through the data tags, it can be avoided that the data packets forwarded across the SAS interface extenders are wrongly forwarded to other storage devices or the hard disk expansion enclosures managed by other storage devices that do not belong to the current data forwarding process after entering other SAS interface extenders, realizing data transfer within the same group and data isolation between different groups in the case of crossing SAS interface extenders.
[0068] The processor of the first SAS interface extender can also be used to perform data forwarding between the storage device connected to the second SAS interface extender and the hard disk expansion enclosure managed by the storage device, or data forwarding between different hard disk expansion enclosures managed by the storage device connected to the second SAS interface extender. Compared with the data forwarding across the SAS interface extenders, both of these cases can be understood as data forwarding within (or local to) the second SAS interface extender.
[0069] Optionally, the processor of the first SAS interface extender performs data forwarding between the storage device connected to the second SAS interface extender and the hard disk expansion enclosure managed by the storage device according to the data tags corresponding to the data packets of each physically connected SAS interface that enter the second SAS interface extender. Through the data tags, the SAS interface extender can isolate the data forwarding processes between multiple storage devices connected to the second SAS interface extender and the multiple hard disk expansion enclosures managed by each storage device, that is, realize data isolation between different groups of devices connected to the second SAS interface extender.
[0070] Optionally, the processor of the first Serial Attached SCSI (SAS) expander performs data forwarding between different hard disk expansion enclosures for managing storage devices connected to the second SAS expander according to the data tags of the data packets of each physically connected SAS interface that enters the second SAS expander. Through the data tags, the first SAS expander can achieve data forwarding between multiple hard disk expansion enclosures managed by multiple storage devices connected to the second SAS expander, that is, it realizes data transfer between devices in the same group connected to the second SAS expander.
[0071] In Figure 5 In the usage scenario of the SAS expander shown, the SAS interfaces in the first SAS expander and the SAS interfaces in the second SAS expander can also be connected to other SAS expanders, and the number can be one or more.
[0072] In some embodiments, the processor 102 is specifically configured to: Add data tags to the data packets that enter each physically connected SAS interface 101; Before forwarding the data packet to the destination SAS interface corresponding to the data packet, if the type of the peer device connected to the destination SAS interface is a SAS expander, do not delete the data tag in the data packet; or, if the type of the peer device connected to the destination SAS interface is a storage device or a hard disk expansion enclosure, delete the data tag in the data packet.
[0073] As in the foregoing embodiments, adding data tags to the data packets that enter each physically connected SAS interface, where the data tags identify the storage device to which the data forwarding process belongs, can achieve isolation of different data forwarding processes.
[0074] If the type of the peer device connected to the destination SAS interface is a storage device or a hard disk expansion enclosure, deleting the data tag in the data packet enables the data packet to be recognized by the peer device connected to the destination SAS interface, does not increase the processing complexity of the data packet for the device connected to the destination SAS interface, and does not require changing the code of the device connected to the destination SAS interface.
[0075] If the type of the peer device connected to the target Serial Attached SCSI (SAS) interface is a SAS expander, the data tags in the data packet are not deleted. Because when the type of the peer device connected to the target SAS interface is a SAS expander, when the data packet reaches the target SAS interface, the processor 102 still needs to perform data forwarding across the SAS expander. This can ensure that the data tags of the same group are consistent, so as to ensure the normal forwarding of services. If the data tags of the data packet are deleted at this time, the processor 102 will not be able to implement data forwarding across the SAS expander.
[0076] In the embodiments of the present application, it is determined whether to delete the data tags in the data packet according to the type of the peer device connected to the target SAS interface. When the type of the peer device connected to the target SAS interface is a storage device or a hard disk expansion cabinet, the data tags in the data packet are deleted, so that the data packet can be recognized by the peer device connected to the target SAS interface. When the type of the peer device connected to the target SAS interface is a SAS expander, the data tags of the data packet are not deleted, avoiding the problem that data forwarding cannot be performed according to the data tags due to crossing the SAS expander.
[0077] In some embodiments, when some of the N SAS interfaces 101 are used to connect other SAS expanders, there is a SAS expander as the master node, which is used to add data tags to the data packets across the SAS expanders. A single SAS expander needs to handle the tagging and forwarding of local data. When the SAS expander acting as the master node fails, a corresponding SAS expander is selected as the master node according to the priorities of the other SAS expanders. The priorities can be configured by the user through the debug serial port 104.
[0078] In the embodiments of the present application, data forwarding across Serial Attached SCSI (SAS) expanders is performed according to data tags, or data forwarding between storage devices connected to other SAS expanders and a hard disk expander for storage device management, or data forwarding between different hard disk expanders for storage device management connected to other SAS expanders. In this way, when a part of the SAS interfaces in the SAS expander is used to connect other SAS expanders, the processor can still normally perform data forwarding. In this case, cascading of the SAS expanders is achieved, and other SAS expanders can also be connected to more storage devices or hardware expanders, further increasing the number of hard disk expanders for storage device connection and management.
[0079] In some embodiments, the debug serial port 104 is also used to implement connection configuration between the SAS expander 100 and other SAS expanders.
[0080] It can be understood that the user can configure the connection relationship between the SAS expander 100 and other SAS expanders through the debug serial port 104. For example, the user can configure the priorities of multiple SAS expanders through the debug serial port 104.
[0081] In some embodiments of the present application, the relevant information of the N SAS interfaces 101 further includes the data traffic values of each SAS interface 101, and the processor 102 is further configured to: Execute rate limiting control logic according to the data traffic value.
[0082] It can be understood that the target data traffic of the SAS interface 101 is usually determined according to the requirements of the storage device or the hard disk expander. Therefore, when the data traffic value of the SAS interface is greater than the target data traffic, the processor 102 executes rate limiting control logic to limit the speed of the SAS interface, which can improve the adaptability of the SAS expander to complex application scenarios. The performances of different storage devices and hard disk expanders are not exactly the same, and executing rate limiting control logic can also make the loads of the storage devices and hard disk expanders more balanced.
[0083] In some embodiments, the processor 102 is specifically configured to: When it is determined to limit the speed of the target expander according to the data traffic value, identify the target SAS interface connected to the target expander; Set a preset number of tokens for the target Serial Attached SCSI (SAS). Control the speed of adding data tags to the data packets entering the target Serial Attached SCSI by means of cyclic number fetching.
[0084] The target expansion cabinet, i.e., the hard disk expansion cabinet that needs speed limiting, after identifying the Serial Attached SCSI in the Serial Attached SCSI expander that is connected to the hard disk expansion cabinet that needs speed limiting, sets a preset number of tokens for the target Serial Attached SCSI. The preset number is set according to actual requirements. Control the speed of adding data tags to the data packets entering the target Serial Attached SCSI by means of cyclic number fetching. Specifically, taking the setting of 1000 tokens as an example, when a data packet enters the target Serial Attached SCSI, it needs to obtain a token to add a data tag. If there is an available token currently, after successfully obtaining the token, the processor 102 can add a data tag to the data packet. If all 1000 tokens are occupied currently, it needs to wait until a data packet completes the addition of the data tag and releases the token, and then it can obtain the released token to add a data tag to the data packet.
[0085] In the embodiment of the present application, data forwarding between the storage device and the hard disk expansion cabinet managed by the storage device management, and / or data forwarding between different hard disk expansion cabinets managed by the storage device management is performed according to the data tag. Therefore, after the data packet entering the target Serial Attached SCSI adds a data tag to determine the storage device to which the data forwarding process belongs, it is then forwarded. By controlling the speed of adding data tags to the data packet by means of cyclic number fetching, the speed of the data packet forwarded into the target Serial Attached SCSI can be limited, thereby realizing speed limiting for the target expansion cabinet connected to the target Serial Attached SCSI.
[0086] In the embodiment of the present application, in the case where speed limiting is required for the target expansion cabinet, determine the target Serial Attached SCSI connected to the target expansion cabinet, set a preset number of tokens for the target Serial Attached SCSI, and control the speed of adding data tags to the data packets entering the target Serial Attached SCSI by means of cyclic number fetching. The data packet needs to add a data tag to determine the storage device to which the data forwarding process belongs before being forwarded. Therefore, by controlling the speed of adding data tags to the data packet by means of cyclic number fetching, the speed of the data packet forwarded into the target Serial Attached SCSI can be limited, effectively realizing speed limiting for the target expansion cabinet.
[0087] In some embodiments, the processor 102 is specifically configured to: When determining the speed limit for a target group based on the data traffic value, identify all target Serial Attached SCSI (SAS) interfaces connected to the target group; Set a total number of tokens for all target Serial Attached SCSI interfaces; Control the speed of adding data tags to the data packets entering the target group by means of circular numbering; Among them, the target group includes a storage device and all hard disk expansion enclosures managed by the storage device.
[0088] In addition to limiting the speed of a single target expansion enclosure, the embodiments of this application can also limit the speed of a group of devices (a storage device and all hard disk expansion enclosures managed by the storage device), that is, limit the speed of all devices within the target group.
[0089] After identifying all target Serial Attached SCSI interfaces connected to the target group in the Serial Attached SCSI expander, set a total number of tokens for all target Serial Attached SCSI interfaces, and the total number of tokens is set according to actual requirements. Specifically, taking the setting of 1000 tokens as an example, when a data packet enters each target Serial Attached SCSI interface, it needs to obtain a token to add a data tag. If there are available tokens currently, after successfully obtaining a token, the data tag can be added to the data packet. If all 1000 tokens are occupied currently, it is necessary to wait until a data packet completes the addition of the data tag and releases a token, and then obtain the released token to add a data tag to the data packet.
[0090] The data packets entering all target Serial Attached SCSI interfaces need to add data tags to determine the storage device to which the data forwarding process belongs and then be forwarded. Therefore, by controlling the speed of adding data tags to the data packets by means of circular numbering, the speed of the data packets forwarded into all target Serial Attached SCSI interfaces can be limited, thereby realizing the speed limit for the target group connected to all target Serial Attached SCSI interfaces.
[0091] When it is necessary to limit the speed of the target group, determine all target Serial Attached SCSI interfaces connected to the target group, set a total number of tokens for all target Serial Attached SCSI interfaces, and control the speed of adding data tags to the data packets entering all target Serial Attached SCSI interfaces by means of circular numbering. The data packets need to add data tags to determine the storage device to which the data forwarding process belongs and then be forwarded. Therefore, by controlling the speed of adding data tags to the data packets by means of circular numbering, the speed of the data packets forwarded into all target Serial Attached SCSI interfaces can be limited, effectively realizing the speed limit for the target group.
[0092] In the embodiments of the present application, the speed of adding data tags to data packets entering the Serial Attached SCSI is controlled by setting the number of tokens and the way of cyclic number fetching, realizing the speed limit for the target expansion cabinet or target group (including one storage device and all hard disk expansion cabinets managed by the storage device), that is, realizing the speed limit processing in the scenario of single Serial Attached SCSI or multiple Serial Attached SCSI, and improving the ability of the Serial Attached SCSI expander to adapt to complex application scenarios.
[0093] Figure 6 FIG. 4 is a schematic structural diagram of a Serial Attached SCSI expander provided by some embodiments of the present application. As Figure 6 shown, in some embodiments of the present application, the Serial Attached SCSI expander 100 further includes a heat dissipation module 106 for dissipating heat from the Serial Attached SCSI expander 100; The processor 102 is further configured to: Obtain the temperature of the Serial Attached SCSI expander 100; According to the temperature, control the operating parameters of the heat dissipation module 106 so that the temperature of the Serial Attached SCSI expander 100 is within the normal temperature range.
[0094] The heat dissipation module 106 can dissipate heat from the Serial Attached SCSI expander 100 through heat dissipation components such as fans and heat pipes inside it.
[0095] In some embodiments, the heat dissipation module 106 includes a fan, and the processor 102 is configured to control the rotation speed of the fan so that the temperature of the Serial Attached SCSI expander 100 is within the normal temperature range.
[0096] The Serial Attached SCSI expander provided by the embodiments of the present application further includes a heat dissipation module, and the processor can be used to control the operating parameters of the heat dissipation module according to the temperature of the Serial Attached SCSI expander, so that the temperature of the Serial Attached SCSI expander is within the normal temperature range, reducing the risk of failures caused by overheating of the Serial Attached SCSI expander, and improving the stability and reliability of the Serial Attached SCSI expander.
[0097] Figure 7 FIG. 5 is a schematic structural diagram of a Serial Attached SCSI expander provided by some embodiments of the present application. As Figure 7 shown, in some embodiments of the present application, the Serial Attached SCSI expander 100 further includes a power module 107 for providing a DC voltage for the Serial Attached SCSI expander 100.
[0098] It can be understood that the DC voltage required for the serial-attached small computer system interface expander usually does not match the voltage of the external application scenario, so the power supply module 107 is needed for conversion. For example, in some embodiments, the power supply module 107 is used to convert 220V AC into 12V DC to provide power for the power supply module 107.
[0099] In the above technical solution, the serial-attached small computer system interface expander further includes a power supply module, and the power supply module is used to provide a DC voltage for the serial-attached small computer system interface expander so that the serial-attached small computer system interface expander can work properly.
[0100] In some embodiments, the serial-attached small computer system interface expander 100 includes both a heat dissipation module 106 and a power supply module 107 at the same time.
[0101] Figure 8 The structural schematic diagram of the storage system provided by some embodiments of the present application is shown as Figure 8 As shown, the embodiments of the present application provide a storage system, including at least one serial-attached small computer system interface expander 100 provided by any one of the above serial-attached small computer system interface expander embodiments, at least one storage device 200, and at least one hard disk expander cabinet 300 managed by the storage device 200. Each storage device 200 is connected to one or more serial-attached small computer system interface expanders 100 through a serial-attached small computer system interface line; Each hard disk expander cabinet 300 is connected to a serial-attached small computer system interface expander 100 through a serial-attached small computer system interface line.
[0102] The serial-attached small computer system interface expander is used to perform data forwarding between the storage device and the hard disk expander cabinet managed by the storage device, and / or data forwarding between different hard disk expander cabinets managed by the storage device.
[0103] The storage device can also be connected to multiple serial-attached small computer system interface expanders 100, and each serial-attached small computer system interface expander 100 can be connected to at least one storage device 200 and at least one hard disk expander cabinet 300 managed by the storage device 200 through a serial-attached small computer system interface line, further increasing the number of hard disk expander cabinets 300 connected and managed by the storage device 200.
[0104] The Serial Attached SCSI (SAS) expander provided by the embodiment of the present application is used to perform data forwarding between a storage device and a hard disk expander for storage device management, and / or data forwarding between different hard disk expanders for storage device management. By using the SAS expander, while increasing the number of hard disk expanders connected to the storage device to expand the storage capacity, the tolerance of the connection between the storage device and the hard disk expander to the failure of the SAS cable is improved.
[0105] The embodiment of the present application provides a data forwarding method. The method will be described in detail in combination with the execution process of the data forwarding method.
[0106] Specifically, Figure 9 is a schematic flowchart of the data forwarding method provided by some embodiments of the present application. As Figure 9 shown, the data forwarding method is applied to a SAS expander. The SAS expander includes: N SAS interfaces, which are used to connect at least one storage device and at least one hard disk expander for storage device management. Among them, one SAS interface connects one device, and N is a positive integer greater than 1; A processor, which is used to run a program to perform: data forwarding between a storage device and a hard disk expander for storage device management, and / or data forwarding between different hard disk expanders for storage device management; A memory, which is used to store the program and the relevant information of the N SAS interfaces; A debug serial port, which is used to configure the N SAS interfaces; The data forwarding method includes: step 910.
[0107] Step 910: Perform data forwarding between a storage device and a hard disk expander for storage device management, and / or data forwarding between different hard disk expanders for storage device management.
[0108] Optionally, the relevant information of the N SAS interfaces includes the hardware connection information of each SAS interface. The method further includes: Determine the SAS interfaces with physical connections according to the hardware connection information of each SAS interface; Send a session message to the peer device connected to the SAS interface with a physical connection, and receive the session response message sent by the peer device; Determine the type of the peer device according to the session response message; According to the type of the peer device, add type tags to each of the Serial Attached SCSI (SAS) interfaces with physical connections, where the type tags are used to identify the type of the device connected to the source SAS interface during the data forwarding process.
[0109] Optionally, the related information of the N SAS interfaces further includes the first configuration information of the N SAS interfaces, and the method further includes: Determine the data tags corresponding to the data packets entering each of the SAS interfaces with physical connections according to the first configuration information of the N SAS interfaces, where the data tags are used to identify the storage device to which the data forwarding process belongs.
[0110] Optionally, performing data forwarding between a storage device and an enclosure for storage device management, and / or between different enclosures for storage device management, includes: Perform data forwarding between a storage device and an enclosure for storage device management, and / or between different enclosures for storage device management according to the data tags.
[0111] Optionally, performing data forwarding between a storage device and an enclosure for storage device management, and / or between different enclosures for storage device management according to the data tags, includes: Add data tags to the data packets entering each of the SAS interfaces with physical connections; Before forwarding the data packet to the destination SAS interface corresponding to the data packet, delete the data tag in the data packet.
[0112] Optionally, the related information of the N SAS interfaces further includes the routing mapping address table of the N SAS interfaces, and the method further includes: Obtain the serial number of the destination SAS interface corresponding to the data packet entering each of the SAS interfaces with physical connections; Generate the routing mapping address table according to the serial number of the SAS interface expander, the type tag, the data tag, the serial number of the SAS interface with physical connection, and the serial number of the destination SAS interface.
[0113] Optionally, some of the N SAS interfaces are used to connect to other SAS interface expanders, and the method further includes: Obtain the second configuration information of multiple Serial Attached SCSI (SAS) interfaces corresponding to other SAS expander; Determine the data labels corresponding to the data packets of each physically connected SAS interface entering the other SAS expander according to the second configuration information; Execute at least one of the following according to the data labels corresponding to the data packets of each physically connected SAS interface entering the other SAS expander: data forwarding across the SAS expander, data forwarding between the storage device connected to the other SAS expander and the hard disk expander managed by the storage device management, data forwarding between different hard disk expanders managed by the storage device connected to the other SAS expander.
[0114] Optionally, execute at least one of the following according to the data labels corresponding to the data packets of each physically connected SAS interface entering the other SAS expander: data forwarding across the SAS expander, data forwarding between the storage device connected to the other SAS expander and the hard disk expander managed by the storage device management, data forwarding between different hard disk expanders managed by the storage device connected to the other SAS expander, including: Add data labels to the data packets of each physically connected SAS interface; Before forwarding the data packet to the destination SAS interface corresponding to the data packet, if the type of the peer device connected to the destination SAS interface is a SAS expander, do not delete the data label in the data packet; or, if the type of the peer device connected to the destination SAS interface is a storage device or a hard disk expander, delete the data label in the data packet.
[0115] Optionally, the relevant information of the N SAS interfaces further includes the data traffic value of each SAS interface, and the method further includes: Execute the rate limiting control logic according to the data traffic value.
[0116] Optionally, executing the rate limiting control logic according to the data traffic value includes: When it is determined to limit the speed of the target expander according to the data traffic value, identify the target SAS interface connected to the target expander; Set a preset number of tokens for the target SAS interface; Control the speed of adding data tags to the data packets entering the target Serial Attached SCSI (SAS) by means of circular numbering.
[0117] Optionally, according to the data traffic value, execute the speed limit control logic, including: When it is determined to limit the speed of a target group according to the data traffic value, identify all the target Serial Attached SCSI interfaces connected to the target group; Set a total number of tokens for all the target Serial Attached SCSI interfaces; Control the speed of adding data tags to the data packets entering the target group by means of circular numbering; Wherein, the target group includes a storage device and all the hard disk expansion enclosures managed by the storage device.
[0118] Optionally, the Serial Attached SCSI interface expander further includes a heat dissipation module for dissipating heat from the Serial Attached SCSI interface expander, and the method further includes: Obtain the temperature of the Serial Attached SCSI interface expander; According to the temperature, control the operating parameters of the heat dissipation module so that the temperature of the Serial Attached SCSI interface expander is within the normal temperature range.
[0119] Through the description of the above embodiments, those skilled in the art can clearly understand that the method according to the above embodiments can be implemented by means of software plus a necessary general hardware platform. Of course, it can also be implemented by hardware, but in many cases the former is a better implementation.
[0120] For the description of the features in the corresponding embodiments of the data forwarding method, reference can be made to the relevant descriptions in the corresponding embodiments of the Serial Attached SCSI interface expander, which will not be elaborated here one by one.
[0121] An embodiment of the present application also provides an electronic device, including a memory and a processor. A computer program is stored in the memory, and the processor is configured to run the computer program to execute the steps in any one of the above embodiments of the data forwarding method.
[0122] An embodiment of the present application also provides a computer-readable storage medium, in which a computer program is stored. Wherein, the computer program is configured to execute the steps in any one of the above embodiments of the data forwarding method when running.
[0123] In an exemplary embodiment, the computer-readable storage medium may include, but is not limited to, various media capable of storing computer programs, such as USB flash drives, read-only memory (ROM), random access memory (RAM), external hard drives, magnetic disks, or optical discs.
[0124] An embodiment of the present application also provides a computer program product. The computer program product includes a computer program, and when the computer program is executed by a processor, the steps in any of the above-described embodiments of the data forwarding method are implemented.
[0125] Another embodiment of the present application also provides a computer program product, including a non-volatile computer-readable storage medium. The non-volatile computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps in any of the above-described embodiments of the data forwarding method are implemented.
[0126] Those skilled in the art can further realize that the units and algorithm steps of each example described in combination with the embodiments disclosed herein can be implemented by electronic hardware, computer software, or a combination of the two. To clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described according to functions in the above description. Whether these functions are executed in a hardware or software manner depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present application.
[0127] The above has provided a detailed introduction to a serial-attached small computer system interface expander and a data forwarding method provided by the present application. Specific examples are used herein to elaborate on the principle and implementation manner of the present application. The description of the above embodiments is only used to help understand the method and its core idea of the present application. It should be noted that for those of ordinary skill in the art in the technical field, without departing from the principle of the present application, several improvements and modifications can be made to the present application, and these improvements and modifications also fall within the protection scope of the claims of the present application.
Claims
1. A serial connection small computer system interface expander, characterized in that: include: N serial connection small computer system interfaces, used to connect at least one storage device and at least one hard disk expansion cabinet managed by the storage device, wherein one serial connection small computer system interface is connected to one device, and N is a positive integer greater than 1; A processor, configured to run a program to execute: data forwarding between the storage device and a hard disk expansion cabinet managed by the storage device, and / or data forwarding between different hard disk expansion cabinets managed by the storage device; A memory, used for storing the program and the related information of the N serial connection small computer system interfaces; The debugging serial port is used to configure the N serial connection small computer system interfaces.
2. The Serial Attached Small Computer System Interface (SAS) expander according to claim 1, characterized in that: The relevant information of the N serial connection small computer system interfaces includes hardware connection information of each of the serial connection small computer system interfaces, and the processor is further used for: Determining a physically connected Serial Small Computer System Interface according to the hardware connection information of each Serial Small Computer System Interface; Sending a session message to a peer device connected to the Serial Small Computer System Interface having a physical connection, and receiving a session response message sent by the peer device; Determining the type of the opposite device according to the session response message; According to the type of the opposite-end device, a type tag is added to each of the physically connected Serial Small Computer System Interfaces, wherein the type tag is used to identify the type of device connected to the source Serial Small Computer System Interface during data forwarding.
3. The Serial Attached Small Computer System Interface (SAS) expander according to claim 2, characterized in that: The related information of the N serial connection small computer system interfaces also includes first configuration information of the N serial connection small computer system interfaces, and the processor is further configured to: According to the first configuration information of the N serial connection small computer system interfaces, a data tag corresponding to a data packet entering each of the physically connected serial connection small computer system interfaces is determined, wherein the data tag is used to identify a storage device to which a data forwarding process belongs.
4. The Serial Attached Small Computer System Interface (SAS) expander according to claim 3, characterized in that: The processor is used to perform data forwarding between the storage device and the hard disk expansion cabinet managed by the storage device according to the data tag, and / or data forwarding between different hard disk expansion cabinets managed by the storage device.
5. The Serial Attached Small Computer System Interface (SAS) expander according to claim 4, characterized in that: The processor is specifically used for: Adding the data tag to the data packets entering each of the SAS interfaces with physical connections; Before forwarding the data packet to a destination Serial Attached Small Computer System Interface corresponding to the data packet, the data tag in the data packet is deleted.
6. The Serial Attached Small Computer System Interface (SAS) expander according to claim 5, characterized in that: The related information of the N serial connection small computer system interfaces also includes a routing mapping address table of the N serial connection small computer system interfaces, and the processor is further used for: Obtaining the sequence number of the destination Serial Attached Small Computer System Interface corresponding to the data packets entering each of the Serial Attached Small Computer System Interfaces with physical connection; The routing mapping address table is generated according to the serial number of the Serial Attached Small Computer System Interface expander, the type tag, the data tag, the serial number of the Serial Attached Small Computer System Interface with a physical connection and the serial number of the destination Serial Attached Small Computer System Interface.
7. The Serial Attached Small Computer System Interface (SAS) expander according to claim 1, characterized in that: Some of the N Serial Attached Small Computer System Interfaces are used to connect to other Serial Attached Small Computer System Interface expanders. The processor is further configured to: Acquire second configuration information of a plurality of serial connection small computer system interfaces corresponding to the other serial connection small computer system interface expanders; Determine, according to the second configuration information, data tags corresponding to data packets entering each physically connected Serial Attached Small Computer System Interface of the other Serial Attached Small Computer System Interface expander; According to the data tags corresponding to the data packets entering the other serially connected small computer system interface expanders with each physically connected serially connected small computer system interface, at least one of the following is performed: data forwarding across serially connected small computer system interface expanders, data forwarding between a storage device connected to the other serially connected small computer system interface expander and a hard disk expansion cabinet managed by the storage device, and data forwarding between different hard disk expansion cabinets managed by the storage device connected to the other serially connected small computer system interface expander.
8. The Serial Attached Small Computer System Interface (SAS) expander according to claim 7, characterized in that: The processor is specifically used for: Adding the data tag to the data packets entering each of the SAS interfaces with physical connections; Before forwarding the data packet to the destination serial connection small computer system interface corresponding to the data packet, if the type of the opposite device connected to the destination serial connection small computer system interface is a serial connection small computer system interface expander, the data label in the data packet is not deleted; or, if the type of the opposite device connected to the destination serial connection small computer system interface is a storage device or a hard disk expansion cabinet, the data label in the data packet is deleted.
9. The Serial Attached Small Computer System Interface (SAS) expander according to claim 7 or 8, characterized in that: The debugging serial port is also used to implement the connection configuration between the Serial Connection Small Computer System Interface expander and the other Serial Connection Small Computer System Interface expanders.
10. The Serial Attached Small Computer System Interface (SAS) expander according to any one of claims 1 to 8, characterized in that: The relevant information of the N serial connection small computer system interfaces also includes a data flow value of each of the serial connection small computer system interfaces, and the processor is further used for: According to the data flow value, a rate limit control logic is executed.
11. The Serial Attached Small Computer System Interface (SAS) expander according to claim 10, characterized in that: The processor is specifically used for: In the case where it is determined according to the data flow value that the speed of the target expansion cabinet is limited, identifying a target serial small computer system interface to which the target expansion cabinet is connected; Setting a preset number of tokens for the target Serial Async SCSI; The speed of adding data labels to the data packets entering the target Serial Small Computer System Interface is controlled by means of cyclic numbering.
12. The Serial Attached Small Computer System Interface (SAS) expander according to claim 10, characterized in that: The processor is specifically used for: In the case of determining to limit the speed of the target group according to the data flow value, identifying all target serially-attached small computer system interfaces connected to the target group; Setting a total number of tokens for all target Serial Attached Small Computer System Interfaces; Controlling the speed of adding data labels to data packets entering the target group by means of cyclic numbering; The target group includes a storage device and all hard disk expansion cabinets managed by the storage device.
13. The Serial Attached Small Computer System Interface (SAS) expander according to claim 1, characterized in that: Also included is a heat dissipation module for dissipating heat for the Serial Small Computer System Interface expander; The processor is further configured to: Acquiring the temperature of the Serial ATA expander; According to the temperature, the operating parameters of the heat dissipation module are controlled so that the temperature of the Serial ATA expander is within a normal temperature range.
14. The Serial Attached Small Computer System Interface (SAS) expander according to claim 1, wherein: A power supply module is also included, which is used to provide a direct current voltage to the Serial Attached Small Computer System Interface expander.
15. A storage system, characterized in that: The method comprises at least one SAS expander according to any one of claims 1 to 14, at least one storage device, and at least one hard disk expansion cabinet managed by the storage device. Each of the storage devices is connected to one or more of the Serial Attached Small Computer System Interface (SASI) expanders via a SAS line; Each of the hard disk expansion cabinets is connected to a serial connection small computer system interface expander via a serial connection small computer system interface line.
16. A data forwarding method, characterized in that: Based on the Serial Attached Small Computer System Interface expander according to any one of claims 1 to 14, the method comprises: Execute data forwarding between the storage device and the hard disk expansion cabinet managed by the storage device, and / or execute data forwarding between different hard disk expansion cabinets managed by the storage device.
17. The method according to claim 16, characterized in that The method further comprises: Determining a physically connected Serial Small Computer System Interface according to the hardware connection information of each Serial Small Computer System Interface; Sending a session message to a peer device connected to the Serial Small Computer System Interface having a physical connection, and receiving a session response message sent by the peer device; Determining the type of the opposite device according to the session response message; According to the type of the opposite-end device, a type tag is added to each of the physically connected Serial Small Computer System Interfaces, wherein the type tag is used to identify the type of device connected to the source Serial Small Computer System Interface during data forwarding.
18. The method according to claim 17, characterized in that The method further comprises: According to the first configuration information of the N serial connection small computer system interfaces, a data tag corresponding to a data packet entering each of the physically connected serial connection small computer system interfaces is determined, wherein the data tag is used to identify a storage device to which a data forwarding process belongs.
19. The method according to claim 18, characterized in that The executing of data forwarding between the storage device and a hard disk expansion cabinet managed by the storage device, and / or data forwarding between different hard disk expansion cabinets managed by the storage device, includes: According to the data tag, data forwarding is performed between the storage device and the hard disk expansion cabinet managed by the storage device, and / or data forwarding is performed between different hard disk expansion cabinets managed by the storage device.
20. The method according to claim 19, characterized in that The performing of data forwarding between the storage device and a hard disk expansion cabinet managed by the storage device and / or data forwarding between different hard disk expansion cabinets managed by the storage device according to the data tag includes: Adding the data tag to the data packets entering each of the SAS interfaces with physical connections; Before forwarding the data packet to a destination Serial Attached Small Computer System Interface corresponding to the data packet, the data tag in the data packet is deleted.
21. The method according to claim 16, characterized in that Some of the N Serial Attached Small Computer System Interfaces are used to connect to other Serial Attached Small Computer System Interface expanders, and the method further includes: Acquire second configuration information of a plurality of serial connection small computer system interfaces corresponding to the other serial connection small computer system interface expanders; Determine, according to the second configuration information, data tags corresponding to data packets entering each physically connected Serial Attached Small Computer System Interface of the other Serial Attached Small Computer System Interface expander; According to the data tags corresponding to the data packets entering the other serially connected small computer system interface expanders with each physically connected serially connected small computer system interface, at least one of the following is performed: data forwarding across serially connected small computer system interface expanders, data forwarding between a storage device connected to the other serially connected small computer system interface expander and a hard disk expansion cabinet managed by the storage device, and data forwarding between different hard disk expansion cabinets managed by the storage device connected to the other serially connected small computer system interface expander.
Citation Information
Patent Citations
Interface expansion device and serial attached SCSI expander
CN104123246A
Converge infrastructure based memory module frame system used for eight-path server
CN105912278A
A data processing method and related equipment
CN109597582A
Hard disk protection device, method and system
CN110674539A
Storage resource processing device and method
CN113625937A