WO2022052953A1 - 一种故障链路的切换方法、系统及相关设备 - Google Patents

一种故障链路的切换方法、系统及相关设备 Download PDF

Info

Publication number
WO2022052953A1
WO2022052953A1 PCT/CN2021/117211 CN2021117211W WO2022052953A1 WO 2022052953 A1 WO2022052953 A1 WO 2022052953A1 CN 2021117211 W CN2021117211 W CN 2021117211W WO 2022052953 A1 WO2022052953 A1 WO 2022052953A1
Authority
WO
WIPO (PCT)
Prior art keywords
host
link
storage device
faulty link
faulty
Prior art date
Application number
PCT/CN2021/117211
Other languages
English (en)
French (fr)
Inventor
程继科
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to EP21866006.6A priority Critical patent/EP4210280A4/en
Publication of WO2022052953A1 publication Critical patent/WO2022052953A1/zh
Priority to US18/181,158 priority patent/US20230205654A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/16Error detection or correction of the data by redundancy in hardware
    • G06F11/20Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements
    • G06F11/2053Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements where persistent mass storage functionality or persistent mass storage control functionality is redundant
    • G06F11/2089Redundant storage control functionality
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/28Routing or path finding of packets in data switching networks using route fault recovery
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/0703Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
    • G06F11/0706Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment
    • G06F11/0727Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment in a storage system, e.g. in a DASD or network based storage system
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/16Error detection or correction of the data by redundancy in hardware
    • G06F11/20Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements
    • G06F11/2002Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements where interconnections or communication control functionality are redundant
    • G06F11/2005Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements where interconnections or communication control functionality are redundant using redundant communication controllers
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/16Error detection or correction of the data by redundancy in hardware
    • G06F11/20Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements
    • G06F11/2002Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements where interconnections or communication control functionality are redundant
    • G06F11/2007Error detection or correction of the data by redundancy in hardware using active fault-masking, e.g. by switching out faulty elements or by switching in spare elements where interconnections or communication control functionality are redundant using redundant communication media
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/24Multipath

Definitions

  • the present invention relates to the technical field of storage, and in particular, to a method, system and related equipment for switching a faulty link.
  • Small computer system interface (SCSI) protocol and network-based non-volatile storage standard are commonly used network storage transmission standard protocols.
  • SCSI networking and NVMe-oF networking by using Fibre Channel (FC) switches to connect storage devices and server hosts, a storage area network (SAN) dedicated to data storage is established.
  • FC Fibre Channel
  • SAN storage area network
  • service switching time is an important parameter to measure the overall reliability of the system. Generally speaking, the shorter the service switching time, the higher the reliability of the system. During the service switching process, the HBA driver senses that the link disconnection time has a great influence on the service switching time.
  • the driver of the host bus adapter is manually configured to sense the link disconnection time. If the HBA driver does not receive the feedback information of the completion of the I/O execution within the configured time, the HBA confirms the link. A multi-path fault is detected and an error code is sent to the host, so that the multi-path performs service switching. In order to reduce the service switching time, you can set the drive sensing link disconnection time to be relatively small, but if the setting is too small, the flash may be misjudged as a link failure.
  • the embodiment of the invention discloses a method, system and related equipment for switching a faulty link, which can quickly sense the faulty link and complete the link switching, shorten service switching time and improve system reliability.
  • the present application provides a system for switching a faulty link
  • the system includes a host and a storage device, at least two links exist between the host and the storage device, wherein: the storage device uses to monitor the at least two links, and send link failure information to the host when a link failure is detected; the host is configured to receive the faulty link information sent by the storage device, and according to the The faulty link information switches the service on the faulty link corresponding to the faulty link information to a normal link among the at least two links.
  • the storage device monitors the link and sends the faulty link information to the host, so that the host can quickly perceive the faulty link and complete the link switching according to the faulty link information, which can shorten the service switching time. Improve system reliability.
  • the host is further configured to send a query request for querying the faulty link information to the storage device; the storage device is further configured to The faulty link information is carried in the feedback information of the query request, and the feedback information is sent to the host.
  • the host sends a query request to enable the storage device to carry the monitored faulty link information in the feedback information of the query request and return it to the host, which can prevent the host from actively sensing the faulty link. It can effectively shorten the time for the host to perceive the faulty link.
  • the host is further configured to disconnect the faulty link according to the faulty link information.
  • the host after receiving the faulty link information returned by the storage device, the host actively disconnects the faulty link, which effectively shortens the service switching time.
  • the host can determine a link mark matching the faulty link information, and then delete the link mark to disconnect the faulty link; or, the host can mark the status of the faulty link. Unavailable to disconnect the failed link.
  • the host switches, according to the faulty link information, services on the faulty link corresponding to the faulty link information to the at least two
  • the host bus adapter HBA card driver of the host sends an error code to the multipath software of the host, and the multipath software of the host puts the faulty link on the link. services are switched to the normal link.
  • the HBA card driver will be triggered to send an error code to the multi-path software of the host, and the multi-path software will complete service switching according to the error code, which can effectively shorten the perceived fault of the HBA card. link time and improve system reliability.
  • the host sends a query request for querying the faulty link information to the storage device according to a preset period; A query request for querying the faulty link information is continuously sent to the storage device.
  • the host can flexibly issue a query request to the storage device, so that the storage device can timely return faulty link information according to the query request.
  • the faulty link information is unique identification information of the faulty link
  • the unique identification information of the faulty link includes an initiator and a target WWN or Internet Protocol IP address
  • the initiator is the port of the faulty link on the host
  • the target is the port of the faulty link on the storage device.
  • the storage device is further configured to send the faulty link information to the host through a normal link in the at least two links.
  • the storage device after the storage device carries the faulty link information in the feedback information of the query request, it sends the information to the host through the normal links of at least two links, which can ensure that the host can correctly receive the faulty link. link information and complete the link switching, the normal link can be the link that the host can normally deliver services.
  • the present application provides a method for switching a faulty link, including: a host receiving faulty link information sent by a storage device, and at least two links exist between the host and the storage device; the host The service on the faulty link corresponding to the faulty link information is switched to the normal link among the at least two links according to the faulty link information.
  • the host switches the services on the faulty link to the normal link by receiving the faulty link information sent by the storage device, which can shorten the time for the host to perceive the faulty link, thereby shortening the service switching time.
  • the host switches the services on the faulty link to the normal link by receiving the faulty link information sent by the storage device, which can shorten the time for the host to perceive the faulty link, thereby shortening the service switching time.
  • the host sends a query request for querying the faulty link information to the storage device; the host receives the information sent by the storage device. Feedback information of the query request, where the feedback information carries the faulty link information.
  • the host disconnects the faulty link according to the faulty link information.
  • the HBA card driver of the host sends an error code to the multipath software of the host, and the multipath software of the host sends the faulty link The traffic on the switch is switched to the normal link.
  • the host sends a query request for querying the faulty link information to the storage device according to a preset period; or, the host serially A query request for querying the faulty link information is continuously sent to the storage device.
  • the faulty link information is unique identification information of the faulty link
  • the unique identification information of the faulty link includes an initiator and a target WWN or Internet Protocol IP address
  • the initiator is the port of the faulty link on the host
  • the target is the port of the faulty link on the storage device.
  • the present application provides a method for switching a faulty link, including: a storage device monitoring a link interacting with a host, and there are at least two links between the storage device and the host; the When monitoring a link failure, the storage device sends the failed link information to the host, so that the host switches the services on the failed link to the at least two links according to the failed link information the normal link in the storage device; the storage device receives the service delivered by the host through the normal link.
  • the storage device receives a query request sent by the host for querying the faulty link information; and carries the faulty link information in the in the feedback information of the query request, and send the feedback information to the host.
  • the storage device sends the faulty link information to the host through a normal link in the at least two links.
  • the storage device receives a query request for querying the faulty link information sent by the host according to a preset period; or, the The storage device receives a query request continuously sent by the host for querying the information of the faulty link.
  • the faulty link information is unique identification information of the faulty link
  • the unique identification information of the faulty link includes an initiator and a target WWN or Internet Protocol IP address
  • the initiator is the port of the faulty link on the host
  • the target is the port of the faulty link on the storage device.
  • the present application provides a network device, comprising: a receiving unit configured to receive fault link information sent by a storage device, at least two links exist between the network device and the storage device; a processing unit is used to switch the service on the faulty link corresponding to the faulty link information to the normal link of the at least two links according to the faulty link information.
  • the network device further includes a sending unit, the sending unit is configured to send a message for querying the faulty link information to the storage device query request; the receiving unit is specifically configured to receive feedback information of the query request sent by the storage device, where the feedback information carries the faulty link information.
  • the processing unit is further configured to disconnect the faulty link according to the faulty link information.
  • the processing unit is specifically configured to: send an error code to multi-path software, and the multi-path software switches the service on the faulty link to the normal link.
  • the present application provides a storage device, comprising: a monitoring unit for monitoring a link interacting with a host, where there are at least two links between the storage device and the host; a sending unit, When the monitoring unit detects that a link is faulty, send faulty link information to the host, so that the host switches the service on the faulty link to the at least one according to the faulty link information A normal link in the two links; a receiving unit, configured to receive the service delivered by the host through the normal link.
  • the receiving unit is further configured to receive a query request sent by the host for querying the faulty link information; the sending unit, It is also used for carrying the faulty link information in the feedback information of the query request, and sending the feedback information to the host.
  • the sending unit is specifically configured to: send the faulty link to the host through a normal link in the at least two links information.
  • the present application provides a computing device, the computing device includes a processor and a memory, the processor and the memory are connected through an internal bus, and instructions are stored in the memory, and the processor calls the The instructions in the memory are used to execute the second aspect and the method for switching a faulty link provided in combination with any one of the implementation manners of the second aspect.
  • the present application provides a computing device, the computing device includes a processor and a memory, the processor and the memory are connected through an internal bus, and instructions are stored in the memory, and the processor calls the The instructions in the memory are used to execute the third aspect and the method for switching a faulty link provided in combination with any one of the implementation manners of the third aspect.
  • the present application provides a computer storage medium, where a computer program is stored in the computer storage medium, and when the computer program is executed by a processor, the second aspect and any combination of the second aspect can be implemented.
  • a flow of a method for switching a faulty link provided by an implementation manner.
  • the present application provides a computer storage medium, where a computer program is stored in the computer storage medium, and when the computer program is executed by a processor, the above-mentioned third aspect and any combination of the above-mentioned third aspect can be implemented.
  • a flow of a method for switching a faulty link provided by an implementation manner.
  • the present application provides a computer program product, the computer program includes instructions, when the computer program is executed by a computer, so that the computer can execute the above second aspect and any implementation manner in combination with the above second aspect
  • the provided flow of the method for switching the faulty link
  • the present application provides a computer program product, the computer program includes instructions, when the computer program is executed by a computer, the computer can execute the above third aspect and implement in combination with any one of the above third aspects The flow of the method for switching the faulty link provided by the method.
  • FIG. 1 is a schematic diagram of a link switching scenario provided by an embodiment of the present application
  • FIG. 2 is a schematic diagram of a system architecture provided by an embodiment of the present application.
  • FIG. 3 is a schematic flowchart of a link failure switching method provided by an embodiment of the present application.
  • FIG. 4 is a schematic structural diagram of a network device provided by an embodiment of the present application.
  • FIG. 5 is a schematic structural diagram of a storage device provided by an embodiment of the present application.
  • FIG. 6 is a schematic structural diagram of a computing device provided by an embodiment of the present application.
  • FIG. 7 is a schematic structural diagram of another computing device provided by an embodiment of the present application.
  • the host can deploy various services and applications (such as multi-path management services, link-aware services, etc.), which can include physical machines, virtual machines, containers, etc., to deliver services to storage devices, such as application servers, distributed file system server, etc.
  • various services and applications such as multi-path management services, link-aware services, etc.
  • storage devices such as application servers, distributed file system server, etc.
  • a storage device can also be called a storage array, which can specifically include a device that can store data in the form of external centralized storage or distributed storage, and is used to receive services from the host, such as storage servers, distributed database servers, and so on.
  • the link is the communication path between the host and the storage device, which is used for information exchange between the host and the storage device.
  • the link can select any one of the multiple links to download. business.
  • the small computer system interface (SCSI) protocol is mainly used to transmit commands, status and block data between the host and the storage device, and the operating system's input/output (such as disk, tape, optical storage, etc.) input/output, I/O) operations can be implemented through the SCSI protocol, which is generally embedded in the onboard logic of the device driver or host adapter.
  • SCSI small computer system interface
  • the network-based non-volatile storage standard (Non-Volatile memory express over fabrics, NVMe-oF) is to support the network storage of the data center and realize the NVMe standard in the high-speed serial computer expansion bus standard (peripheral component interconnect express, PCIe) extension on the bus.
  • NVMe-oF uses a message-based model to send requests and responses between hosts and storage devices over the network, replacing PCIe to extend the distance over which NVMe hosts and NVMe storage subsystems can communicate.
  • the storage area network uses FC technology to connect storage devices and server hosts through FC switches. It is an independent transmission control protocol/internet protocol (TCP/ A private network other than IP) network, SAN provides a way to connect with existing local area network (LAN), and supports widely used SCSI protocol and IP protocol through the same physical channel.
  • TCP/ A private network other than IP transmission control protocol/internet protocol
  • a host bus adapter is a board that can be inserted into a computer or a mainframe, and is an essential device for connecting a host to an FC network.
  • the HBA connects the host to the storage device or storage device network through Fibre Channel or SCSI, and provides I/O processing and physical connection between the host and the storage device.
  • the host side (such as the HBA card) senses it. After sensing that the link is disconnected, the current faulty link is switched and another link is selected.
  • the normal link delivers services.
  • the normal link may be a link through which the host can normally deliver services to the storage device.
  • FIG. 1 which shows a schematic diagram of a link switching scenario, an application 1110 , a multipath software 1120 and an HBA driver 1130 are deployed in the host 110 , and the application 1110 generates the service that needs to be delivered, and sends the service through the HBA.
  • the driver 1130 delivers services to the storage device 120, the host 110 and the storage device 120 are connected through a SAN, there are multiple links in the SAN, the storage device 120 is deployed with a controller 1210, and the controller 1210 is used to receive and process the host 110
  • the HBA driver 1130 will sense that the link has been disconnected.
  • the HBA driver does not receive the feedback that the I/O execution is completed within the preset time, the HBA driver can determine that the link has been disconnected and cannot continue to use the link to deliver services.
  • the HBA driver 1130 sends The multipath software 1120 returns an error code (eg linkdown), and the multipath software 1120 parses the error code after receiving the error code returned by the HBA driver 1130, thereby confirming that the current link has been disconnected and cannot be used, and then selects another chain If the service is successfully delivered to the storage device 120, the multipath software 1120 can determine that the reselected link is a normal link, and then notify the application 1110 that the service can be delivered using the reselected link. It can be seen that, when the link fails, link switching is required to complete the service switching.
  • error code eg linkdown
  • the time consumed in the whole process is the time for the HBA driver 1130 to sense the link disconnection, the time for the HBA driver 1130 to process the returned error code, and the multipath software. 1120 switches the processing time and the time at which the multipath software 1120 determines that the reselected link is the normal link.
  • the switching processing time of the multi-path software 1120 and the time for the multi-path software 1120 to determine that the re-selected link is a normal link are relatively short, usually several milliseconds. Therefore, the main time consumed by the entire switching process is the perception of the HBA driver 1130 The time the link is down and the time the HBA driver 1130 processes the return error code.
  • the HBA driver in order to prevent the link from being temporarily disconnected and then restored, thus affecting the continuity of the service, and to avoid misjudging the flash as a link failure, the HBA driver usually does not set the link disconnection time to an excessive value.
  • the default parameter value is generally greater than 5 seconds. Therefore, the current solution cannot effectively shorten the service switching time and cannot improve the system reliability.
  • the present application provides a method for switching a faulty link.
  • the storage device can sense whether the link is faulty and actively notify the host of the faulty link.
  • Link switching shortens service switching time and improves system reliability.
  • the technical solutions of the embodiments of the present application can be applied to any system that needs to perform link switching, and is especially applicable to scenarios where there are multiple paths between hosts and storage devices, for example, SCSI networking scenarios and NVMe-oF scenarios.
  • SCSI networking scenarios for example, SCSI networking scenarios and NVMe-oF scenarios.
  • the storage device can use the method for switching the faulty link provided in the embodiment of the present application to perform link switching, In order to shorten the service switching time and improve the system reliability.
  • FIG. 2 shows a schematic diagram of a system architecture according to an embodiment of the present application.
  • the system 200 includes: a host 210 and a storage device 220 , the host 210 is connected to the storage device 220 through an FC network or an Ethernet network (ethernet, ETH), and there are multiple chains between the host 210 and the storage device 220 (for example, multiple Fibre Channels), the host 210 includes an application program 2110, a link failure handling service 2120, a multi-path software 2130, an NVMe driver 2140, an HBA driver 2150, and a network interface controller (NIC) driver 2160;
  • the storage device 220 includes a controller 2210 and a link monitor 2220.
  • the link failure processing service 2120 in the host 210 continuously or periodically sends a link failure query request on each link, and the application 2110 generates the service that needs to be sent and sends the control in the storage device 220 through the multi-path software 2130
  • the server 2210 delivers services, and the link monitor 2220 monitors each link between the host 210 and the storage device 220.
  • a link failure is detected (for example, a certain link between the host 210 and the storage device 220 is detected The optical signal or electrical signal of the session link is interrupted)
  • the link monitor 2220 sends the unique identification information (such as the initiator and the target) corresponding to the faulty link in the feedback information of the link fault query request issued by the link fault processing service 2120.
  • the globally unique name (WWN) or internet protocol (IP) address of the server) is returned to the link failure handling service 2120 through other normal links, and the link failure handling service 2120 receives the corresponding
  • identify the link mark corresponding to the faulty link for example, NVMe ctrl
  • disconnect the faulty link for example, delete the link mark corresponding to the faulty link in the host or set the status of the faulty link to Unavailable state
  • the link mark is generated when the host and the storage device establish a connection, used to identify the link between the host and the storage device, each link generates a link mark
  • HBA driver 2150 or NIC driver 2160 An error code is immediately returned to the multi-path software 2130, and the multi-path software 2130 identifies the error code and performs link switching, and switches the services generated by the application program 2110 to other normal links for delivery.
  • the storage device senses the link failure and actively informs the host, instead of being driven by the host's HBA or NIC. Sensing link failure can reduce the HBA driver or NIC driver sensing link disconnection time, so that link switching can be completed quickly, service switching time can be shortened, and system reliability can be improved.
  • the process includes:
  • the host 210 sends a query request for querying the faulty link information to the storage device 220.
  • the host 210 and the storage device 220 are connected through a SAN, there are multiple links (for example, multiple Fibre Channels) between them, and the link failure handling service 2120 deployed in the host 210 is under each link Send a query request for querying faulty link information.
  • multiple links for example, multiple Fibre Channels
  • the host 210 may send a query request on each link through periodic timing to query the faulty link information, and the period may be set as required, for example, set to 500 milliseconds;
  • the uplink continuously sends a query request to query the faulty link information.
  • the storage device 220 will return a confirmation message after a fixed time interval (for example, 5 seconds). Once a fault occurs, the storage device 220 will query the request The faulty link information is returned immediately in the feedback information.
  • the storage device 220 monitors the link interacting with the host 210.
  • the link monitor 2220 in the storage device 220 monitors each link. If a link suddenly fails, the link monitor 2220 will immediately sense that, for example, the host 210 and the storage device If the optical signal or electrical signal of a certain link between 220 is suddenly interrupted, the link monitor 2220 can immediately sense and determine that the link is faulty.
  • the storage device 220 sends the link failure information to the host 210.
  • the link monitor 2220 in the storage device 220 fills the unique identification information of the faulty link into the feedback information of the query request for the faulty link sent by the host 210, because the host 210 There are other normal links with the storage device 220 , so the unique identification information of the faulty link can be successfully returned to the host 210 , and then returned to the link failure processing service 2120 in the host 210 .
  • the storage device 220 cannot directly and actively send messages to the host 210. Therefore, even if the storage device 220 perceives a link failure, it cannot actively inform the host 210 about the faulty link information.
  • the host 210 needs to send the message to the storage device 220 by sending The query request for querying the faulty link information enables the storage device 220 to feed back according to the received query request, so as to obtain the faulty link information.
  • the storage device queries the status of each link, and when it is determined that a link is faulty, the link information is carried in the feedback information of the query request, and the feedback information is sent to the host 210 .
  • the storage device can query the status of each link in the following way: the status of each link is stored in the memory of the storage device (for example, filling a certain segment of storage space with 0 or a negotiated value to indicate the status of the link). status), when the storage device 220 receives the query request sent by the host 210, it will query the status of each link, read the status information of each link, and when it is determined that the link is faulty, the storage device 220 will The information of the route is carried in the feedback information of the query request, and the feedback information is sent to the host 210 .
  • the unique identification information of the faulty link has different meanings in different application scenarios.
  • the unique identification information can be the information of the initiator and the target. WWN, the initiator is the port of the link on the host 210 (that is, the port of the HBA card), and the target is the port of the link on the storage device 220; in the RoCE-NVMe networking scenario, the unique identification information can be the boot IP of the initiator and target, where the port of the initiator is the port of the ETH network card (that is, the port of the NIC card).
  • the IP is allocated and used when the host 210 and the storage device 220 establish a connection, and they appear in pairs.
  • the IP of each initiator in the host 210 has a unique one corresponding to it in the storage device 220
  • the IP of the target An IP pair can uniquely identify a link.
  • S304 The host 210 disconnects the faulty link according to the faulty link information.
  • the link failure processing service 2120 in the host 210 identifies the link label corresponding to the failed link.
  • the tag is an object created by the host 210 for managing links, and each link has a unique link tag, for example, the link tag can be NVMe ctrl.
  • the NVMe driver 2140 in the host 210 pre-stores all link information between the host 210 and the storage device 220, and each link is identified by the WWN or IP pair of the initiator and the target, and There is only one link tag corresponding to it.
  • the link failure processing service 2120 receives the WWN or IP pair of the initiator and the target, it checks the full amount of link information stored in the NVMe driver 2140 in combination with the NVMelist_subsys command, thereby identifying the link flag corresponding to the faulty link.
  • the multi-path software 2130 to identify that there are other normal links between the host 210 and the storage device 220, delete the link mark (for example, NVMe ctrl) through the NVMe disconnect command, thereby triggering the HBA driver 2150 or the NIC driver 2160 to detect
  • the link mark for example, NVMe ctrl
  • the HBA driver 2150 or the NIC driver 2160 After detecting that the link mark is deleted, the I/O request that has been sent through the link corresponding to the link mark but has not received confirmation information carries an error code, and the I/O request is sent.
  • the multi-path software 2130 recognizes the error code, determines that the link is faulty, and then resends the I/O request to the storage device through the normal link; or, the link failure processing service 2120 By issuing the keep alive command, the HBA driver 2150 or the NIC driver 2160 is triggered to perform the routine operation of detecting the link failure, that is, the HBA driver 2150 or the NIC driver 2160 will immediately issue the detection I/O to the storage device 220 to detect the link If it is detected that the link state is a fault state, the link flag will be deleted, and an error code will be carried in the IO request that has not received confirmation information on the link, and the IO request carrying the error code will be carried. Sent to the multi-path software 2130, the multi-path software 2130 identifies the error code, determines that the link is faulty, and re-sends the IO request to the storage device through the normal link to perform link switching.
  • the host after receiving the faulty link information returned by the storage device, the host actively issues a command to delete the link tag corresponding to the faulty link or triggers the HBA driver or NIC driver to perform an example test operation, thereby prompting the HBA driver or NIC to perform an example test operation.
  • the driver immediately returns an error code to the multipath software, instead of the HBA driver or NIC driver actively sensing and confirming that the link is faulty and returning an error code to the multipath software. This ensures that the multipath software can receive the error code in time to complete the chain. It can greatly shorten the service switching time and improve the system reliability.
  • S305 The host 210 delivers services through other normal links.
  • the multi-path software 2130 sets the status of the current path to a fault state, and re-selects a link (for example, a link can be randomly selected) from the remaining links for retry. , send the service I/O to the storage device 220, when the success message returned by the storage device 220 can be received, it can be determined that the re-selected link is a normal link and can support the service delivery, and the multi-path software 2130 notifies the application program 2110, the service IO can be delivered by using the reselected link to complete the read and write operations on the data in the storage device 220.
  • a link for example, a link can be randomly selected
  • FIG. 4 is a schematic structural diagram of a network device provided by an embodiment of the present application.
  • the network device may be the host in the method embodiment described in FIG. 3, and may perform the fault link described in FIG. 3.
  • the method and steps in the embodiment of the switching method take the host as the main body of execution.
  • the network device 400 includes a receiving unit 410 , a processing unit 420 and a sending unit 430 . in,
  • a receiving unit 410 configured to receive fault link information sent by a storage device, and there are at least two links between the network device and the storage device;
  • the processing unit 420 is configured to switch the service on the faulty link corresponding to the faulty link information to the normal link of the at least two links according to the faulty link information.
  • the receiving unit 410 is configured to execute the foregoing step S303, and optionally execute an optional method among the foregoing steps
  • the processing unit 420 is configured to execute the foregoing step S304, and optionally execute an optional method among the foregoing steps.
  • the sending unit 430 is configured to execute the foregoing steps S301 and S305, and optionally execute the optional method in the foregoing steps.
  • the above three units can transmit data to each other through a communication channel. It should be understood that each unit included in the network device 400 may be a software unit, a hardware unit, or a part of a software unit and a part of a hardware unit.
  • the sending unit 430 is configured to send a query request for querying the faulty link information to the storage device; the receiving unit 410 is specifically configured to receive the information sent by the storage device. Feedback information of the query request, where the feedback information carries the faulty link information.
  • the processing unit 420 is further configured to disconnect the faulty link according to the faulty link information.
  • the processing unit 420 is specifically configured to: send an error code to multi-path software, and the multi-path software switches the service on the faulty link to the normal link.
  • the sending unit 430 is specifically configured to: send a query request for querying the faulty link information to the storage device according to a preset period; or, continuously send a query request to the storage device in series The query request for the information about the faulty link.
  • the faulty link information is the unique identification information of the faulty link
  • the unique identification information of the faulty link includes the globally unique name WWN or the Internet Protocol IP address of the initiator and the target
  • the initiator is a port of the faulty link on the network device
  • the target is a port of the faulty link on the storage device.
  • each unit of the network device may be added, reduced or combined as required.
  • the operations and/or functions of each unit in the network device are respectively to implement the corresponding flow of the method described in FIG. 3 , and are not repeated here for brevity.
  • FIG. 5 is a schematic structural diagram of a storage device provided by an embodiment of the present application.
  • the storage device may be the storage device in the method embodiment described in FIG. 3 , and may execute the methods and steps in the method embodiment of the faulty link switching described in FIG. 3 with the storage device as the execution subject.
  • the storage device 500 includes a monitoring unit 510 , a sending unit 520 and a receiving unit 530 . in,
  • a monitoring unit 510 configured to monitor the link interacting with the host, and there are at least two links between the storage device and the host;
  • the sending unit 520 is configured to send the faulty link information to the host when the monitoring unit 510 detects a link failure, so that the host switches the service on the faulty link to the host according to the faulty link information.
  • the receiving unit 530 is configured to receive the service delivered by the host through the normal link.
  • the monitoring unit 510 is configured to execute the foregoing step S302, and optionally execute an optional method among the foregoing steps
  • the sending unit 520 is configured to execute the foregoing step S303, and optionally execute an optional method among the foregoing steps.
  • the receiving unit 530 is configured to execute the foregoing steps S301 and S305, and optionally execute the optional method in the foregoing steps.
  • the above three units can transmit data to each other through a communication path. It should be understood that each unit included in the storage device 500 may be a software unit, a hardware unit, or a part of a software unit and a part of a hardware unit.
  • the receiving unit 530 is further configured to receive a query request sent by the host for querying the faulty link information; the sending unit 520 is further configured to carry the faulty link information In the feedback information of the query request, the feedback information is sent to the host.
  • the sending unit 520 is specifically configured to: send the faulty link information to the host through a normal link in the at least two links.
  • the receiving unit 530 is specifically configured to: receive a query request sent by the host according to a preset period for querying the information on the faulty link; A query request for querying the faulty link information.
  • the faulty link information is the unique identification information of the faulty link
  • the unique identification information of the faulty link includes the globally unique name WWN or the Internet Protocol IP address of the initiator and the target
  • the initiator is a port of the faulty link on the host
  • the target is a port of the faulty link on the storage device.
  • each unit of the storage device may be added, reduced or combined as required.
  • the operations and/or functions of each unit in the storage device are respectively in order to implement the corresponding flow of the method described in FIG. 3 , and are not repeated here for brevity.
  • FIG. 6 is a schematic structural diagram of a computing device provided by an embodiment of the present application.
  • the computing device 600 includes a processor 610 , a communication interface 620 and a memory 630 , and the processor 610 , the communication interface 620 and the memory 630 are connected to each other through an internal bus 640 .
  • the computing device 600 may be the host in FIG. 2 .
  • the functions performed by the host in FIG. 2 are actually performed by the processor 610 of the host.
  • the processor 610 may be composed of one or more general-purpose processors, such as a central processing unit (central processing unit, CPU), or a combination of a CPU and a hardware chip.
  • the above-mentioned hardware chip may be an application-specific integrated circuit (ASIC), a programmable logic device (PLD) or a combination thereof.
  • the above-mentioned PLD may be a complex programmable logic device (CPLD), a field-programmable gate array (FPGA), a general array logic (generic array logic, GAL) or any combination thereof.
  • the bus 640 may be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus or the like.
  • PCI peripheral component interconnect
  • EISA extended industry standard architecture
  • the bus 640 can be divided into an address bus, a data bus, a control bus, and the like. For ease of presentation, only one thick line is used in FIG. 6, but it does not mean that there is only one bus or one type of bus.
  • the memory 630 may include volatile memory (volatile memory), such as random access memory (RAM); the memory 630 may also include non-volatile memory (non-volatile memory), such as read-only memory (read- only memory, ROM), flash memory (flash memory), hard disk drive (HDD) or solid-state drive (solid-state drive, SSD); the memory 630 may also include a combination of the above types.
  • volatile memory volatile memory
  • non-volatile memory such as read-only memory (read- only memory, ROM), flash memory (flash memory), hard disk drive (HDD) or solid-state drive (solid-state drive, SSD
  • the memory 630 may also include a combination of the above types.
  • the program code may be used to implement the functional units shown in the network device 400, or used to implement the method steps in the method embodiment shown in FIG. 3 with the host as the main body of execution.
  • FIG. 7 is a schematic structural diagram of another computing device provided by an embodiment of the present application.
  • the computing device 700 includes a processor 710 , a communication interface 720 and a memory 730 , and the processor 710 , the communication interface 720 and the memory 730 are connected to each other through an internal bus 740 .
  • the computing device 700 may be the storage device in FIG. 2 .
  • the functions performed by the storage device in FIG. 2 are actually performed by the processor 710 of the storage device.
  • the processor 710 may be composed of one or more general-purpose processors, such as a CPU, or a combination of a CPU and a hardware chip.
  • the above-mentioned hardware chip may be an ASIC, a PLD or a combination thereof.
  • the above PLD can be CPLD, FPGA, GAL or any combination thereof.
  • the bus 740 may be a PCI bus, an EISA bus, or the like.
  • the bus 740 can be divided into an address bus, a data bus, a control bus, and the like. For convenience of representation, only one thick line is used in FIG. 7, but it does not mean that there is only one bus or one type of bus.
  • Memory 730 may include volatile memory, such as RAM; memory 730 may also include non-volatile memory, such as ROM, flash memory, HDD, or SSD; memory 730 Combinations of the above categories may also be included.
  • the program code may be used to implement the functional units shown in the storage device 500, or used to implement the method steps in the method embodiment shown in FIG. 3 with the storage device as the main body of execution.
  • Embodiments of the present application further provide a computer-readable storage medium, on which a computer program is stored.
  • the program When the program is executed by a processor, it can implement some or all of the steps described in the above method embodiments, and realize the above The function of any one of the functional units described in FIG. 6 .
  • Embodiments of the present application also provide a computer program product, which, when run on a computer or a processor, causes the computer or processor to execute one or more steps in any one of the above methods. If each constituent unit of the above-mentioned device is implemented in the form of a software functional unit and sold or used as an independent product, it may be stored in the computer-readable storage medium.
  • the size of the sequence numbers of the above-mentioned processes does not mean the sequence of execution, and the execution sequence of each process should be determined by its functions and internal logic, and should not be implemented in the present application.
  • the implementation of the examples constitutes no limitation.
  • the functions, if implemented in the form of software functional units and sold or used as independent products, may be stored in a computer-readable storage medium.
  • the technical solution of the present application can be embodied in the form of a software product in essence, or the part that contributes to the prior art or the part of the technical solution, and the computer software product is stored in a storage medium, including Several instructions are used to cause a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present application.
  • the aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), magnetic disk or optical disk and other media that can store program codes .

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Hardware Redundancy (AREA)
  • Computer And Data Communications (AREA)

Abstract

本申请提供一种故障链路的切换方法、系统及相关设备。其中,该方法包括:主机接收存储设备发送的故障链路信息,该主机与存储设备之间存在至少两条链路;该主机根据故障链路信息将所述故障链路信息对应的故障链路上的业务切换至所述至少两条链路中的正常链路。上述方法能够使得主机快速感知故障链路并完成链路切换,缩短链路切换时间,提高系统可靠性。

Description

一种故障链路的切换方法、系统及相关设备
本申请要求于2020年9月10日提交中国专利局、申请号为202010947350.4、申请名称为“一种故障链路的切换方法、系统及相关设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本发明涉及存储技术领域,尤其涉及一种故障链路的切换方法、系统及相关设备。
背景技术
小型计算机系统接口(small computer system interface,SCSI)协议以及基于网络的非易失性存储标准(Non-Volatile memory express over fabrics,NVMe-oF)是常用的网络存储传输标准协议。在SCSI组网和NVMe-oF组网的场景中,通过采用光纤通道(fiber channel,FC)交换机连接存储设备和服务器主机,建立专用于数据存储的存储区域网络(storage area network,SAN),在SAN中,主机与存储设备之间存在多条链路,主机通过SAN中的多条链路下发业务。若在主机下发业务的过程中,链路发生故障,则需要将业务从故障链路切换到正常链路进行下发,其中,业务从故障链路切换到正常链路所需要的时间称为业务切换时间,在存储系统中,业务切换时间是衡量系统整体可靠性的重要参数,一般而言,业务切换时间越短,系统的可靠性越高。在业务切换过程中,HBA驱动感知链路断开时间对业务切换时间影响比较大。
目前都是通过手动配置主机总线适配器(host bus adapter,HBA)的驱动感知链路断开时间,如果HBA驱动没有在所配置的时间内接收到I/O执行完成的反馈信息,则HBA确认链路故障,并发送错误码至主机的多路径,使多路径进行业务切换。为了减少业务切换时间,可以将驱动感知链路断开时间设置的比较小,但是设置的太小的话,又可能将闪断误判为链路故障。
发明内容
本发明实施例公开了一种故障链路的切换方法、系统及相关设备,能够快速感知故障链路并完成链路切换,缩短业务切换时间,提高系统可靠性。
第一方面,本申请提供了一种故障链路的切换系统,所述系统包括主机和存储设备,所述主机和所述存储设备之间存在至少两条链路,其中:所述存储设备用于对所述至少两条链路进行监测,并在监测到链路故障时向所述主机发送链路故障信息;所述主机用于接收所述存储设备发送的故障链路信息,并根据所述故障链路信息将所述故障链路信息对应的故障链路上的业务切换至所述至少两条链路中的正常链路。
在本申请提供的方案中,存储设备通过监测链路并向主机发送故障链路信息,以使得主机能够快速的感知到故障链路根据故障链路信息完成链路切换,可以缩短业务切换时间,提高系统可靠性。
结合第一方面,在第一方面的一种可能的实现方式中,所述主机还用于向所述存储设备发送查询所述故障链路信息的查询请求;所述存储设备还用于将所述故障链路信息携带在所述查询请求的反馈信息中,并将所述反馈信息发送至所述主机。
在本申请提供的方案中,主机通过发送查询请求以使得存储设备能够将监测到的故障链路信息携带在该查询请求的反馈信息中并返回至主机,这样可以避免主机主动感知故障链路, 能够有效缩短主机感知故障链路的时间。
结合第一方面,在第一方面的一种可能的实现方式中,所述主机还用于根据所述故障链路信息,断开所述故障链路。
在本申请提供的方案中,主机在接收到存储设备返回的故障链路信息之后,主动断开该故障链路,这样有效缩短业务切换时间。可选的,主机可以在接收到故障链路信息之后确定与该故障链路信息匹配的链路标记,然后删除该链路标记以断开故障链路;或者,主机将故障链路的状态标记为不可用状态以断开故障链路。
结合第一方面,在第一方面的一种可能的实现方式中,所述主机在根据所述故障链路信息将所述故障链路信息对应的故障链路上的业务切换至所述至少两条链路中的正常链路时,具体用于:所述主机的主机总线适配器HBA卡驱动发送错误码至所述主机的多路径软件,所述主机的多路径软件将所述故障链路上的业务切换至所述正常链路。
在本申请提供的方案中,主机断开故障链路之后将会触发HBA卡驱动发送错误码至主机的多路径软件,多路径软件从而根据错误码完成业务切换,这样可以有效缩短HBA卡感知故障链路的时间,提高系统可靠性。
结合第一方面,在第一方面的一种可能的实现方式中,所述主机按照预设周期向所述存储设备发送查询所述故障链路信息的查询请求;或者是,所述主机串行持续向所述存储设备发送查询所述故障链路信息的查询请求。
在本申请提供的方案中,主机可以灵活的向存储设备下发查询请求,以使得存储设备根据该查询请求能够及时的返回故障链路信息。
结合第一方面,在第一方面的一种可能的实现方式中,所述故障链路信息为所述故障链路的唯一标识信息,所述故障链路的唯一标识信息包括启动器和目标器的全球唯一名字WWN或网际互连协议IP地址,所述启动器为所述故障链路在所述主机上的端口,所述目标器为所述故障链路在所述存储设备上的端口。
结合第一方面,在第一方面的一种可能的实现方式中,所述存储设备还用于通过所述至少两条链路中的正常链路向所述主机发送所述故障链路信息。
在本申请提供的方案中,存储设备在将故障链路信息携带在查询请求的反馈信息中之后,通过至少两条链路中的正常链路发送给主机,可以保证主机能够正确的接收到故障链路信息并完成链路切换,正常链路可以为主机能够正常下发业务的链路。
第二方面,本申请提供了一种故障链路的切换方法,包括:主机接收存储设备发送的故障链路信息,所述主机与所述存储设备之间存在至少两条链路;所述主机根据所述故障链路信息将所述故障链路信息对应的故障链路上的业务切换至所述至少两条链路中的正常链路。
在本申请提供的方案中,主机通过接收存储设备发送的故障链路信息将故障链路上的业务切换至正常链路,这样可以缩短主机感知故障链路的时间,进而缩短业务的切换时间,提高了系统可靠性。
结合第二方面,在第二方面的一种可能的实现方式中,所述主机向所述存储设备发送用于查询所述故障链路信息的查询请求;所述主机接收所述存储设备发送的所述查询请求的反馈信息,所述反馈信息中携带所述故障链路信息。
结合第二方面,在第二方面的一种可能的实现方式中,所述主机根据所述故障链路信息,断开所述故障链路。
结合第二方面,在第二方面的一种可能的实现方式中,所述主机的HBA卡驱动发送错误 码至所述主机的多路径软件,所述主机的多路径软件将所述故障链路上的业务切换至所述正常链路。
结合第二方面,在第二方面的一种可能的实现方式中,所述主机按照预设周期向所述存储设备发送查询所述故障链路信息的查询请求;或者是,所述主机串行持续向所述存储设备发送查询所述故障链路信息的查询请求。
结合第二方面,在第二方面的一种可能的实现方式中,所述故障链路信息为所述故障链路的唯一标识信息,所述故障链路的唯一标识信息包括启动器和目标器的全球唯一名字WWN或网际互连协议IP地址,所述启动器为所述故障链路在所述主机上的端口,所述目标器为所述故障链路在所述存储设备上的端口。
第三方面,本申请提供了一种故障链路的切换方法,包括:存储设备对与主机交互的链路进行监测,所述存储设备与所述主机之间存在至少两条链路;所述存储设备在监测到链路故障时,向所述主机发送故障链路信息,以使所述主机根据所述故障链路信息将所述故障链路上的业务切换至所述至少两条链路中的正常链路;所述存储设备接收所述主机通过所述正常链路下发的业务。
结合第三方面,在第三方面的一种可能的实现方式中,所述存储设备接收所述主机发送的用于查询所述故障链路信息的查询请求;将所述故障链路信息携带在所述查询请求的反馈信息中,并将所述反馈信息发送至所述主机。
结合第三方面,在第三方面的一种可能的实现方式中,所述存储设备通过所述至少两条链路中的正常链路向所述主机发送所述故障链路信息。
结合第三方面,在第三方面的一种可能的实现方式中,所述存储设备接收所述主机按照预设周期发送的用于查询所述故障链路信息的查询请求;或者是,所述存储设备接收所述主机串行持续发送的用于查询所述故障链路信息的查询请求。
结合第三方面,在第三方面的一种可能的实现方式中,所述故障链路信息为所述故障链路的唯一标识信息,所述故障链路的唯一标识信息包括启动器和目标器的全球唯一名字WWN或网际互连协议IP地址,所述启动器为所述故障链路在所述主机上的端口,所述目标器为所述故障链路在所述存储设备上的端口。
第四方面,本申请提供了一种网络设备,包括:接收单元,用于接收存储设备发送的故障链路信息,所述网络设备与所述存储设备之间存在至少两条链路;处理单元,用于根据所述故障链路信息将所述故障链路信息对应的故障链路上的业务切换至所述至少两条链路中的正常链路。
结合第四方面,在第四方面的一种可能的实现方式中,所述网络设备还包括发送单元,所述发送单元,用于向所述存储设备发送用于查询所述故障链路信息的查询请求;所述接收单元,具体用于接收所述存储设备发送的所述查询请求的反馈信息,所述反馈信息中携带所述故障链路信息。
结合第四方面,在第四方面的一种可能的实现方式中,所述处理单元,还用于根据所述故障链路信息,断开所述故障链路。
结合第四方面,在第四方面的一种可能的实现方式中,所述处理单元,具体用于:将错误码发送至多路径软件,所述多路径软件将所述故障链路上的业务切换至所述正常链路。
第五方面,本申请提供了一种存储设备,包括:监测单元,用于对与主机交互的链路进行监测,所述存储设备与所述主机之间存在至少两条链路;发送单元,用于在所述监测单元监测到链路故障时,向所述主机发送故障链路信息,以使所述主机根据所述故障链路信息将所述故障链路上的业务切换至所述至少两条链路中的正常链路;接收单元,用于接收所述主机通过所述正常链路下发的业务。
结合第五方面,在第五方面的一种可能的实现方式中,所述接收单元,还用于接收所述主机发送的用于查询所述故障链路信息的查询请求;所述发送单元,还用于将所述故障链路信息携带在所述查询请求的反馈信息中,并将所述反馈信息发送至所述主机。
结合第五方面,在第五方面的一种可能的实现方式中,所述发送单元,具体用于:通过所述至少两条链路中的正常链路向所述主机发送所述故障链路信息。
第六方面,本申请提供了一种计算设备,所述计算设备包括处理器和存储器,所述处理器和所述存储器通过内部总线相连,所述存储器中存储有指令,所述处理器调用所述存储器中的指令以执行上述第二方面以及结合上述第二方面中的任意一种实现方式所提供的故障链路的切换方法。
第七方面,本申请提供了一种计算设备,所述计算设备包括处理器和存储器,所述处理器和所述存储器通过内部总线相连,所述存储器中存储有指令,所述处理器调用所述存储器中的指令以执行上述第三方面以及结合上述第三方面中的任意一种实现方式所提供的故障链路的切换方法。
第八方面,本申请提供了一种计算机存储介质,所述计算机存储介质存储有计算机程序,当所述计算机程序被处理器执行时,可以实现上述第二方面以及结合上述第二方面中的任意一种实现方式所提供的故障链路的切换方法的流程。
第九方面,本申请提供了一种计算机存储介质,所述计算机存储介质存储有计算机程序,当所述计算机程序被处理器执行时,可以实现上述第三方面以及结合上述第三方面中的任意一种实现方式所提供的故障链路的切换方法的流程。
第十方面,本申请提供了一种计算机程序产品,该计算机程序包括指令,当该计算机程序被计算机执行时,使得计算机可以执行上述第二方面以及结合上述第二方面中的任意一种实现方式所提供的故障链路的切换方法的流程。
第十一方面,本申请提供了一种计算机程序产品,该计算机程序包括指令,当该计算机程序被计算机执行时,使得计算机可以执行上述第三方面以及结合上述第三方面中的任意一种实现方式所提供的故障链路的切换方法的流程。
附图说明
为了更清楚地说明本发明实施例技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1是本申请实施例提供的一种链路倒换的场景示意图;
图2是本申请实施例提供的一种系统架构的示意图;
图3是本申请实施例提供的一种链路故障倒换方法的流程示意图;
图4是本申请实施例提供的一种网络设备的结构示意图;
图5是本申请实施例提供的一种存储设备的结构示意图;
图6是本申请实施例提供的一种计算设备的结构示意图;
图7是本申请实施例提供的又一种计算设备的结构示意图。
具体实施方式
下面结合附图对本申请实施例中的技术方案进行清楚、完整的描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。
首先,结合附图对本申请中所涉及的部分用语和相关技术进行解释说明,以便于本领域技术人员理解。
主机可以部署各种服务和应用程序(例如多路径管理服务、链路感知服务等),具体可以包括物理机、虚拟机、容器等,用于向存储设备下发业务,例如应用服务器、分布式文件系统服务器等。
存储设备又可以称为存储阵列,具体可以包括外置集中式存储或分布式存储等形态的能够存储数据的设备,用于接收主机下发的业务,例如存储服务器、分布式数据库服务器等。
链路为主机与存储设备之间的通信通路,用于主机与存储设备之间进行信息交互,主机和存储设备之间一般存在多条链路,主机可以选择多条链路中的任意一条下发业务。
小型计算机系统接口(small computer system interface,SCSI)协议主要是在主机和存储设备之间传送命令、状态和块数据,操作系统对外部设备(例如磁盘、磁带、光存储等)的输入/输出(input/output,I/O)操作,可以通过SCSI协议来实现,一般情况下SCSI协议都嵌入到设备驱动器或者主机适配器的板载逻辑中。
基于网络的非易失性存储标准(Non-Volatile memory express over fabrics,NVMe-oF)是为了支持数据中心的网络存储,实现NVMe标准在高速串行计算机扩展总线标准(peripheral component interconnect express,PCIe)总线上的扩展。NVMe-oF使用基于消息的模型通过网络在主机和存储设备之间发送请求和响应,替代PCIe来扩展NVMe主机和NVMe存储子系统进行通信的距离。
存储区域网络(storage area network,SAN)采用FC技术,通过FC交换机连接存储设备和服务器主机,是一种专门为存储建立的独立于传输控制协议/网际协议(transmission control protocol/internet protocol,TCP/IP)网络之外的专用网络,SAN提供了一种与现有局域网(local area network,LAN)连接的方法,并且通过同一物理信道支持广泛使用的SCSI协议和IP协议。
主机总线适配器(host bus adapter,HBA)是能插入计算机或大型主机的板卡,是将主机接入FC网络必不可少的设备。HBA通过光纤信道或SCSI把主机连接到存储设备或存储设备网上,在主机和存储设备之间提供I/O处理和物理连接。
目前在主机向存储设备下发业务的过程中,链路发生故障时,都是由主机侧(例如HBA卡)进行感知,在感知到链路断开以后切换当前故障链路,重新选择另外一条正常链路下发业务,正常链路具体可以是主机能够向存储设备正常下发业务的链路。如图1所示,其示出 了一种链路切换的场景示意图,主机110中部署了应用程序1110、多路径软件1120和HBA驱动1130,应用程序1110产生需要下发的业务,并通过HBA驱动1130向存储设备120下发业务,主机110和存储设备120之间通过SAN连接,SAN中存在多条链路,存储设备120中部署了控制器1210,控制器1210用于接收并处理主机110下发的业务,当正在下发业务的链路发生故障或控制器1210发生故障时,经过一段时间后,HBA驱动1130将感知到链路已经断开,例如,HBA驱动可以利用超时机制进行链路故障感知,当HBA驱动在预先设置的时间内没有接收到I/O执行完成的反馈,则HBA驱动则可以确定链路已经断开,无法继续使用该链路下发业务,HBA驱动1130向多路径软件1120返回错误码(例如linkdown),多路径软件1120在接收到HBA驱动1130返回的错误码后对该错误码进行解析,从而确认当前链路已经断开不可使用,然后选择另外一条链路重新下发业务,若成功下发业务至存储设备120之后,多路径软件1120可以确定重新选择的链路为正常链路,然后通知应用程序1110可以使用重新选择的链路的下发业务。可以看出,在链路出现故障需要进行链路切换从而完成业务切换,整个过程需要消耗的时间为HBA驱动1130感知链路断开的时间、HBA驱动1130处理返回错误码的时间、多路径软件1120切换处理时间以及多路径软件1120确定重新选择的链路为正常链路的时间。其中,多路径软件1120切换处理时间和多路径软件1120确定重新选择的链路为正常链路的时间都比较短暂,通常为几毫秒,因此,整个切换过程所消耗的主要时间为HBA驱动1130感知链路断开的时间和HBA驱动1130处理返回错误码的时间。为了快速完成链路切换,缩短业务切换时间,通常都是通过手动配置HBA的驱动感知链路断开时间,例如在Linux文件系统下使用光纤卡(Qlogic)HBA的FC组网场景中,对SCSI层的dev_loss_tmo参数和Qlogic HBA驱动的qlport_down_retry参数进行配置,将参数值配置到最小值,以使得HBA驱动能够快速感知链路断开并向多路径软件返回错误码,多路径软件根据返回的错误码进行链路切换,将业务通过其它正常链路进行下发,从而达到缩短业务切换时间的目的。
需要说明的是,为了避免链路因为短暂的断开又恢复,从而影响业务的连续性,避免将闪断误判为链路故障,通常不会将HBA驱动感知链路断开时间设置的过小,一般默认的参数值都是大于5秒,因此,目前的解决方案并不能有效的缩短业务切换时间,不能提高系统可靠性。
基于上述,本申请提供了一种故障链路的切换方法,可以由存储设备感知链路是否出现故障并主动告知主机故障链路,由主机下发断开故障链路的指令,从而可以快速完成链路切换,缩短业务切换时间,提高系统可靠性。
本申请实施例的技术方案可以应用于任何需要进行链路切换的系统中,尤其适用于主机和存储设备存在多路径的场景,例如,SCSI组网场景和NVMe-oF场景等。例如,在SCSI组网的SAN存储网络多路径的场景中,主机和存储设备之间的链路出现故障时,存储设备可以使用本申请实施例提供的故障链路的切换方法进行链路切换,以缩短业务切换时间,提高系统可靠性。
图2示出了本申请实施例的一种系统架构的示意图。如图2所示,该系统200包括:主机210和存储设备220,主机210通过FC网络或以太网络(ethernet,ETH)与存储设备220进行连接,主机210和存储设备220之间存在多条链路(例如多条光纤通道),主机210包括应用程序2110、链路故障处理服务2120、多路径软件2130、NVMe驱动2140、HBA驱动2150和网络接口控制器(network interface controller,NIC)驱动2160;存储设备220包括 控制器2210和链路监控器2220。主机210中的链路故障处理服务2120在每条链路上持续或周期性下发链路故障查询请求,应用程序2110产生需要下发的业务并通过多路径软件2130向存储设备220中的控制器2210下发业务,链路监控器2220对主机210和存储设备220之间的各条链路进行监测,当监测到某条链路故障时(例如监测到主机210和存储设备220的某个会话链接的光信号或电信号中断),链路监控器2220在链路故障处理服务2120下发的链路故障查询请求的反馈信息中将故障链路对应的唯一标识信息(例如启动器和目标器的全球唯一名字(world wide name,WWN)或网际协议(internet protocol,IP)地址)通过其它正常链路返回给链路故障处理服务2120,链路故障处理服务2120接收到故障链路对应的唯一标识信息之后,识别出故障链路对应的链路标记(例如NVMe ctrl),然后断开故障链路(例如在主机中删除故障链路对应的链路标记或将故障链路的状态设置为不可用状态,所述链路标记在主机与存储设备建立连接时生成,用于标识主机与存储设备之间的链路,每条链路生成一个链路标记),HBA驱动2150或NIC驱动2160会立即向多路径软件2130返回错误码,多路径软件2130识别错误码并进行链路切换,将应用程序2110产生的业务切换到其它正常链路进行下发。
可以看出,图2所示的故障链路切换系统与图1所示的故障链路切换相比,存储设备感知链路出现故障并主动告知主机,而避免由主机的HBA驱动或NIC驱动去感知链路出现故障,这样可以减少HBA驱动或NIC驱动感知链路断开时间,从而可以快速完成链路切换,缩短业务切换时间,提高系统的可靠性。
结合图2所示的系统架构的示意图,下面将描述本申请实施例提供的故障链路的切换方法。如图3所示,该流程包括:
S301:主机210向存储设备220发送用于查询故障链路信息的查询请求。
具体地,主机210和存储设备220之间通过SAN进行连接,它们之间存在多条链路(例如多条光纤通道),主机210中部署的链路故障处理服务2120在每条链路都下发用于查询故障链路信息的查询请求。
可选的,主机210可以通过周期定时在每条链路上下发查询请求以查询故障链路信息,其周期可以根据需要进行设置,例如设置为500毫秒;或者是,主机210在每条链路上串行持续下发查询请求以查询故障链路信息,在没有故障出现时,存储设备220将会间隔固定时间(例如5秒)后返回确认消息,一旦出现故障,则存储设备220在查询请求的反馈信息中立即返回故障链路信息。
可以看出,通过周期性下发查询请求查询故障链路信息,不需要一直占用链路资源,但下发操作比较频繁,且存储设备220无法第一时间进行反馈,但是串行持续下发查询请求查询故障链路信息,将导致每条链路都至少有一个I/O一直占用链路资源,但不需要频繁执行下发操作,且存储设备220能够第一时间反馈故障链路信息,提高了反馈效率。本申请对具体选用何种方式不作限定。
S302:存储设备220对与主机210交互的链路进行监测。
具体地,存储设备220中的链路监控器2220对每一条链路都进行监测,若某条链路突然出现故障,则链路监控器2220将会立即感知到,例如,主机210和存储设备220之间的某个链路的光信号或电信号突然中断,则链路监控器2220可以立即感知并确定该链路出现故障。
S303:存储设备220向主机210发送链路故障信息。
具体地,存储设备220中的链路监控器2220在感知到链路出现故障之后,将故障链路的 唯一标识信息填充到主机210下发的故障链路查询请求的反馈信息中,由于主机210和存储设备220之间还存在其它正常的链路,所以故障链路的唯一标识信息是可以成功返回至主机210,进而返回至主机210中的链路故障处理服务2120。
应理解,存储设备220不能直接主动的向主机210发送消息,因此,存储设备220即使感知到链路出现故障也不能主动告知主机210相关故障链路信息,主机210需要通过向存储设备220下发查询故障链路信息的查询请求以使存储设备220根据接收到的查询请求进行反馈,进而才能获取到故障链路信息。在存储设备接收到查询请求后,查询每条链路的状态,当确定有链路发生故障后,将链路信息携带在查询请求的反馈信息中,并将该反馈信息发送至主机210。存储设备查询每条链路的状态的方式例如可以为:存储设备的内存中存储了各个链路的状态(例如将某段存储空间全部填充为0或协商好的某个数值以表示链路的状态),当存储设备220接收到主机210下发的查询请求之后,将查询各个链路的状态,读取各个链路的状态信息,当确定链路出现故障时,则存储设备220将故障链路的信息携带在查询请求的反馈信息中,并将该反馈信息发送至主机210。
需要说明的是,故障链路的唯一标识信息在不同的应用场景中代表不同的含义,例如,在FC-SCSI或FC-NVMe组网场景中,该唯一标识信息可以是启动器和目标器的WWN,启动器为链路在主机210上的端口(即HBA卡的端口),目标器为链路在存储设备220上的端口;在RoCE-NVMe组网场景中,该唯一标识信息可以是启动器和目标器的IP,这里启动器的端口为ETH网卡的端口(即NIC卡的端口)。应理解,该IP是在主机210和存储设备220在建立连接时分配使用的,是成对出现的,主机210中的每个启动器的IP在存储设备220中都存在唯一一个与之对应的目标器的IP,一个IP对可以唯一标识一条链路。
S304:主机210根据故障链路信息断开故障链路。
具体地,主机210中的链路故障处理服务2120接收到存储设备220反馈的故障链路的启动器和目标器的WWN或IP对后,识别出故障链路对应的链路标记,该链路标记是主机210用于管理链路所创建的一个对象,每一条链路都存在唯一一个链路标记,例如,该链路标记可以是NVMe ctrl。
需要说明的是,主机210中的NVMe驱动2140中预先存储了主机210与存储设备220之间的全量链路信息,每一条链路都用启动器和目标器的WWN或IP对进行标识,且存在唯一一个与之对应的链路标记。
示例性的,链路故障处理服务2120接收到启动器和目标器的WWN或IP对之后,结合NVMelist_subsys命令查看NVMe驱动2140中存储的全量链路信息,从而识别出故障链路对应的链路标记,然后通过多路径软件2130识别出主机210与存储设备220之间还存在其它正常链路之后,通过NVMe disconnect命令删除该链路标记(例如NVMe ctrl),从而触发HBA驱动2150或NIC驱动2160侦测到该链路标记被删除后,则在已通过所述链路标记对应的链路发送,但还没有收到确认信息的I/O请求中携带错误码,并将所述I/O请求发送至至多路径软件2130,多路径软件2130识别出错误码,确定该链路出现故障,则将所述I/O请求通过正常链路重新发送至存储设备;或者是,链路故障处理服务2120通过下发keep alive命令以触发HBA驱动2150或NIC驱动2160执行例行检测链路故障的操作,即HBA驱动2150或NIC驱动2160将会立即向存储设备220下发检测I/O以检测链路状态,若检测到该链路状态是故障状态时,则删除所述链路标记,并在该链路上还没收到确认信息的IO请求中携带错误码,并将携带了错误码的IO请求发送至多路径软件2130,多路径软件2130识别出错误码,确定该链路出现故障,并将所述IO请求通过正常链路重新下发至存储设备,以执行链路切换。
可以看出,主机是在接收到存储设备返回的故障链路信息之后通过主动下发命令删除故障链路对应的链路标记或触发HBA驱动或NIC驱动执行例测操作,从而促使HBA驱动或NIC驱动立即向多路径软件返回错误码,而不是由HBA驱动或NIC驱动主动感知并确认链路出现故障后向多路径软件返回错误码,这样可以保证多路径软件能够及时接收到错误码从而完成链路切换,大大缩短业务倒换时间,提高了系统可靠性。
S305:主机210通过其它正常链路下发业务。
具体地,多路径软件2130在识别出错误码之后,将当前路径的状态置为故障(fault)状态,重新在剩余的链路中选择一条链路(例如可以随机选择一条链路)进行重试,向存储设备220发送业务I/O,当能够接收到存储设备220返回的成功消息之后,则可以确定重新选择的链路为正常链路,能够支持下发业务,多路径软件2130通知应用程序2110,可以使用重新选择的链路下发业务IO,完成对存储设备220中的数据进行读写操作。
上述详细阐述了本申请实施例的方法,为了便于更好的实施本申请实施例的上述方案,相应地,下面还提供用于配合实施上述方案的相关设备。
参见图4,图4是本申请实施例提供的一种网络设备的结构示意图,该网络设备可以是上述图3所述的方法实施例中的主机,可以执行图3所述的故障链路的切换方法实施例中以主机为执行主体的方法和步骤。如图4所示,该网络设备400包括接收单元410、处理单元420和发送单元430。其中,
接收单元410,用于接收存储设备发送的故障链路信息,所述网络设备与所述存储设备之间存在至少两条链路;
处理单元420,用于根据所述故障链路信息将所述故障链路信息对应的故障链路上的业务切换至所述至少两条链路中的正常链路。
具体地,所述接收单元410用于执行前述步骤S303,且可选的执行前述步骤中可选的方法,所述处理单元420用于执行前述步骤S304,且可选的执行前述步骤中可选的方法,所述发送单元430用于执行前述步骤S301和S305,且可选的执行前述步骤中可选的方法。上述三个单元之间互相可以通过通信通路进行数据传输,应理解,网络设备400包括各单元可以为软件单元、也可以为硬件单元、或部分为软件单元部分为硬件单元。
作为一个实施例,所述发送单元430,用于向所述存储设备发送用于查询所述故障链路信息的查询请求;所述接收单元410,具体用于接收所述存储设备发送的所述查询请求的反馈信息,所述反馈信息中携带所述故障链路信息。
作为一个实施例,所述处理单元420,还用于根据所述故障链路信息,断开所述故障链路。
作为一个实施例,所述处理单元420,具体用于:将错误码发送至多路径软件,所述多路径软件将所述故障链路上的业务切换至所述正常链路。
作为一个实施例,所述发送单元430,具体用于:按照预设周期向所述存储设备发送查询所述故障链路信息的查询请求;或者是,串行持续向所述存储设备发送查询所述故障链路信息的查询请求。
作为一个实施例,所述故障链路信息为所述故障链路的唯一标识信息,所述故障链路的唯一标识信息包括启动器和目标器的全球唯一名字WWN或网际互连协议IP地址,所述启动器为所述故障链路在所述网络设备上的端口,所述目标器为所述故障链路在所述存储设备上的端口。
应理解,上述网络设备的结构仅仅作为一种示例,不应构成具体的限定,可以根据需要对网络设备的各个单元进行增加、减少或合并。此外,网络设备中的各个单元的操作和/或功能分别为了实现上述图3所描述的方法的相应流程,为了简洁,在此不再赘述。
参见图5,图5是本申请实施例提供的一种存储设备的结构示意图。该存储设备可以是上述图3所述的方法实施例中的存储设备,可以执行图3所述的故障链路的切换方法实施例中以存储设备为执行主体的方法和步骤。如图5所示,该存储设备500包括监测单元510、发送单元520和接收单元530。其中,
监测单元510,用于对与主机交互的链路进行监测,所述存储设备与所述主机之间存在至少两条链路;
发送单元520,用于在监测单元510监测到链路故障时,向所述主机发送故障链路信息,以使所述主机根据所述故障链路信息将所述故障链路上的业务切换至所述至少两条链路中的正常链路;
接收单元530,用于接收所述主机通过所述正常链路下发的业务。
具体地,所述监测单元510用于执行前述步骤S302,且可选的执行前述步骤中可选的方法,所述发送单元520用于执行前述步骤S303,且可选的执行前述步骤中可选的方法,所述接收单元530用于执行前述步骤S301和S305,且可选的执行前述步骤中可选的方法。上述三个单元之间互相可以通过通信通路进行数据传输,应理解,存储设备500包括各单元可以为软件单元、也可以为硬件单元、或部分为软件单元部分为硬件单元。
作为一个实施例,所述接收单元530,还用于接收所述主机发送的用于查询所述故障链路信息的查询请求;所述发送单元520,还用于将所述故障链路信息携带在所述查询请求的反馈信息中,并将所述反馈信息发送至所述主机。
作为一个实施例,所述发送单元520,具体用于:通过所述至少两条链路中的正常链路向所述主机发送所述故障链路信息。
作为一个实施例,所述接收单元530,具体用于:接收所述主机按照预设周期发送的用于查询所述故障链路信息的查询请求;或者是,接收所述主机串行持续发送的用于查询所述故障链路信息的查询请求。
作为一个实施例,所述故障链路信息为所述故障链路的唯一标识信息,所述故障链路的唯一标识信息包括启动器和目标器的全球唯一名字WWN或网际互连协议IP地址,所述启动器为所述故障链路在所述主机上的端口,所述目标器为所述故障链路在所述存储设备上的端口。
应理解,上述存储设备的结构仅仅作为一种示例,不应构成具体的限定,可以根据需要对存储设备的各个单元进行增加、减少或合并。此外,存储设备中的各个单元的操作和/或功能分别为了实现上述图3所描述的方法的相应流程,为了简洁,在此不再赘述。
参见图6,图6是本申请实施例提供的一种计算设备的结构示意图。如图6所示,该计算设备600包括:处理器610、通信接口620以及存储器630,所述处理器610、通信接口620以及存储器630通过内部总线640相互连接。
所述计算设备600可以是图2中的主机。图2中的主机所执行的功能实际上是由所述主机的处理器610来执行。
所述处理器610可以由一个或者多个通用处理器构成,例如中央处理器(central processing unit,CPU),或者CPU和硬件芯片的组合。上述硬件芯片可以是专用集成电路 (application-specific integrated circuit,ASIC)、可编程逻辑器件(programmable logic device,PLD)或其组合。上述PLD可以是复杂可编程逻辑器件(complex programmable logic device,CPLD)、现场可编程逻辑门阵列(field-programmable gate array,FPGA)、通用阵列逻辑(generic array logic,GAL)或其任意组合。
总线640可以是外设部件互连标准(peripheral component interconnect,PCI)总线或扩展工业标准结构(extended industry standard architecture,EISA)总线等。所述总线640可以分为地址总线、数据总线、控制总线等。为便于表示,图6中仅用一条粗线表示,但不表示仅有一根总线或一种类型的总线。
存储器630可以包括易失性存储器(volatile memory),例如随机存取存储器(random access memory,RAM);存储器630也可以包括非易失性存储器(non-volatile memory),例如只读存储器(read-only memory,ROM)、快闪存储器(flash memory)、硬盘(hard disk drive,HDD)或固态硬盘(solid-state drive,SSD);存储器630还可以包括上述种类的组合。程序代码可以是用来实现网络设备400所示的功能单元,或者用于实现图3所示的方法实施例中以主机为执行主体的方法步骤。
参见图7,图7是本申请实施例提供的又一种计算设备的结构示意图。如图7所示,该计算设备700包括:处理器710、通信接口720以及存储器730,所述处理器710、通信接口720以及存储器730通过内部总线740相互连接。
所述计算设备700可以是图2中的存储设备。图2中的存储设备所执行的功能实际上是由所述存储设备的处理器710来执行。
所述处理器710可以由一个或者多个通用处理器构成,例如CPU,或者CPU和硬件芯片的组合。上述硬件芯片可以是ASIC、PLD或其组合。上述PLD可以是CPLD、FPGA、GAL或其任意组合。
总线740可以是PCI总线或EISA总线等。所述总线740可以分为地址总线、数据总线、控制总线等。为便于表示,图7中仅用一条粗线表示,但不表示仅有一根总线或一种类型的总线。
存储器730可以包括易失性存储器(volatile memory),例如RAM;存储器730也可以包括非易失性存储器(non-volatile memory),例如ROM、快闪存储器(flash memory)、HDD或SSD;存储器730还可以包括上述种类的组合。程序代码可以是用来实现存储设备500所示的功能单元,或者用于实现图3所示的方法实施例中以存储设备为执行主体的方法步骤。
本申请实施例还提供一种计算机可读存储介质,其上存储有计算机程序,该程序被处理器执行时,可以实现上述方法实施例中记载的任意一种的部分或全部步骤,以及实现上述图6所描述的任意一个功能单元的功能。
本申请实施例还提供了一种计算机程序产品,当其在计算机或处理器上运行时,使得计算机或处理器执行上述任一个方法中的一个或多个步骤。上述所涉及的设备的各组成单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在所述计算机可读取存储介质中。
在上述实施例中,对各个实施例的描述各有侧重,某个实施例中没有详述的部分,可以参见其它实施例的相关描述。
还应理解,在本申请的各种实施例中,上述各过程的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本申请实施例的实施过程构 成任何限定。
所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统、装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
所述功能如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(Read-Only Memory,ROM)、随机存取存储器(Random Access Memory,RAM)、磁碟或者光盘等各种可以存储程序代码的介质。
以上所述,以上实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的范围。

Claims (23)

  1. 一种故障链路的切换系统,其特征在于,包括主机和存储设备,所述主机和所述存储设备之间存在至少两条链路,其中:
    所述存储设备用于对所述至少两条链路进行监测,并在监测到链路故障时向所述主机发送故障链路信息;
    所述主机用于接收所述存储设备发送的故障链路信息,并根据所述故障链路信息将所述故障链路信息对应的故障链路上的业务切换至所述至少两条链路中的正常链路。
  2. 如权利要求1所述的系统,其特征在于,
    所述主机还用于向所述存储设备发送查询所述故障链路信息的查询请求;
    所述存储设备还用于将所述故障链路信息携带在所述查询请求的反馈信息中,并将所述反馈信息发送至所述主机。
  3. 如权利要求2所述的系统,其特征在于,所述主机还用于:
    根据所述故障链路信息,断开所述故障链路。
  4. 如权利要求3所述的系统,其特征在于,所述主机在根据所述故障链路信息将所述故障链路信息对应的故障链路上的业务切换至所述至少两条链路中的正常链路时,具体用于:
    所述主机的主机总线适配器HBA卡驱动发送错误码至所述主机的多路径软件,所述主机的多路径软件将所述故障链路上的业务切换至所述正常链路。
  5. 如权利要求1-4任一项所述的系统,其特征在于,
    所述存储设备还用于通过所述至少两条链路中的正常链路向所述主机发送所述故障链路信息。
  6. 一种故障链路的切换方法,其特征在于,所述方法包括:
    主机接收存储设备发送的故障链路信息,所述主机与所述存储设备之间存在至少两条链路;
    所述主机根据所述故障链路信息将所述故障链路信息对应的故障链路上的业务切换至所述至少两条链路中的正常链路。
  7. 如权利要求6所述的方法,其特征在于,所述方法还包括:
    所述主机向所述存储设备发送用于查询所述故障链路信息的查询请求;
    所述主机接收所述存储设备发送的故障链路信息包括:
    所述主机接收所述存储设备发送的所述查询请求的反馈信息,所述反馈信息中携带所述故障链路信息。
  8. 如权利要求6或7所述的方法,其特征在于,所述方法还包括:
    所述主机根据所述故障链路信息,断开所述故障链路。
  9. 如权利要求8所述的方法,其特征在于,所述主机根据所述故障链路信息将所述故障 链路信息对应的故障链路上的业务切换至所述至少两条链路中的正常链路,包括:
    所述主机的HBA卡驱动发送错误码至所述主机的多路径软件,所述主机的多路径软件将所述故障链路上的业务切换至所述正常链路。
  10. 一种故障链路的切换方法,其特征在于,所述方法包括:
    存储设备对与主机交互的链路进行监测,所述存储设备与所述主机之间存在至少两条链路;
    所述存储设备在监测到链路故障时,向所述主机发送故障链路信息,以使所述主机根据所述故障链路信息将所述故障链路上的业务切换至所述至少两条链路中的正常链路;
    所述存储设备接收所述主机通过所述正常链路下发的业务。
  11. 如权利要求10所述的方法,其特征在于,所述方法还包括:
    所述存储设备接收所述主机发送的用于查询所述故障链路信息的查询请求;
    所述向所述主机发送故障链路信息包括:
    将所述故障链路信息携带在所述查询请求的反馈信息中,并将所述反馈信息发送至所述主机。
  12. 如权利要求10或11所述的方法,其特征在于,所述方法还包括:
    所述存储设备通过所述至少两条链路中的正常链路向所述主机发送所述故障链路信息。
  13. 一种网络设备,其特征在于,包括:
    接收单元,用于接收存储设备发送的故障链路信息,所述网络设备与所述存储设备之间存在至少两条链路;
    处理单元,用于根据所述故障链路信息将所述故障链路信息对应的故障链路上的业务切换至所述至少两条链路中的正常链路。
  14. 如权利要求13所述的网络设备,其特征在于,所述网络设备还包括发送单元,
    所述发送单元,用于向所述存储设备发送用于查询所述故障链路信息的查询请求;
    所述接收单元,具体用于接收所述存储设备发送的所述查询请求的反馈信息,所述反馈信息中携带所述故障链路信息。
  15. 如权利要求13或14所述的网络设备,其特征在于,
    所述处理单元,还用于根据所述故障链路信息,断开所述故障链路。
  16. 如权利要求15所述的网络设备,其特征在于,所述处理单元,具体用于:
    将错误码发送至多路径软件,所述多路径软件将所述故障链路上的业务切换至所述正常链路。
  17. 一种存储设备,其特征在于,包括:
    监测单元,用于对与主机交互的链路进行监测,所述存储设备与所述主机之间存在至少两条链路;
    发送单元,用于在所述监测单元监测到链路故障时,向所述主机发送故障链路信息,以使所述主机根据所述故障链路信息将所述故障链路上的业务切换至所述至少两条链路中的正常链路;
    接收单元,用于接收所述主机通过所述正常链路下发的业务。
  18. 如权利要求17所述的存储设备,其特征在于,
    所述接收单元,还用于接收所述主机发送的用于查询所述故障链路信息的查询请求;
    所述发送单元,还用于将所述故障链路信息携带在所述查询请求的反馈信息中,并将所述反馈信息发送至所述主机。
  19. 如权利要求17或18所述的存储设备,其特征在于,所述发送单元,具体用于:
    通过所述至少两条链路中的正常链路向所述主机发送所述故障链路信息。
  20. 一种计算设备,其特征在于,所述计算设备包括存储器和处理器,所述处理器执行所述存储器中存储的计算机指令,使得所述计算设备执行权利要求6-9任一项所述的方法。
  21. 一种计算设备,其特征在于,所述计算设备包括存储器和处理器,所述处理器执行所述存储器中存储的计算机指令,使得所述计算设备执行权利要求10-12任一项所述的方法。
  22. 一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,当所述计算机程序被处理器执行时实现权利要求6-9任一项所述的方法的功能。
  23. 一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,当所述计算机程序被处理器执行时实现权利要求10-12任一项所述的方法的功能。
PCT/CN2021/117211 2020-09-10 2021-09-08 一种故障链路的切换方法、系统及相关设备 WO2022052953A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP21866006.6A EP4210280A4 (en) 2020-09-10 2021-09-08 METHOD AND SYSTEM FOR TRANSFER OF FAILED LINK, AND ASSOCIATED DEVICE
US18/181,158 US20230205654A1 (en) 2020-09-10 2023-03-09 Faulty Link Switching Method and System, and Related Device

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010947350.4A CN114257541A (zh) 2020-09-10 2020-09-10 一种故障链路的切换方法、系统及相关设备
CN202010947350.4 2020-09-10

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US18/181,158 Continuation US20230205654A1 (en) 2020-09-10 2023-03-09 Faulty Link Switching Method and System, and Related Device

Publications (1)

Publication Number Publication Date
WO2022052953A1 true WO2022052953A1 (zh) 2022-03-17

Family

ID=80632093

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/117211 WO2022052953A1 (zh) 2020-09-10 2021-09-08 一种故障链路的切换方法、系统及相关设备

Country Status (4)

Country Link
US (1) US20230205654A1 (zh)
EP (1) EP4210280A4 (zh)
CN (1) CN114257541A (zh)
WO (1) WO2022052953A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023197972A1 (zh) * 2022-04-14 2023-10-19 华为技术有限公司 一种光传输设备、业务设备、业务传输的方法和系统

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115022180B (zh) * 2022-05-18 2024-05-28 浪潮思科网络科技有限公司 一种基于RoCE-SAN的拓扑管理方法、装置、设备及介质
US20240012708A1 (en) * 2022-07-06 2024-01-11 Dell Products L.P. Real-time sense data querying
CN118051360A (zh) * 2022-11-15 2024-05-17 华为技术有限公司 一种故障通知方法及相关装置

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050188239A1 (en) * 2004-01-30 2005-08-25 Dell Products L.P. Method, software and system for multi-path fail-over recovery in sequential storage systems
CN101741831A (zh) * 2008-11-10 2010-06-16 国际商业机器公司 动态物理和虚拟多路径输入/输出的方法、系统和装置
CN102984002A (zh) * 2012-11-27 2013-03-20 华为技术有限公司 一种处理i/o超时的方法和装置
CN104461951A (zh) * 2014-11-19 2015-03-25 浪潮(北京)电子信息产业有限公司 动态管理物理和虚拟多路径i/o的方法及系统
CN105760261A (zh) * 2014-12-16 2016-07-13 华为技术有限公司 业务输入输出io处理方法和装置

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4840236B2 (ja) * 2007-04-12 2011-12-21 株式会社日立製作所 ネットワークシステム及びノード装置

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050188239A1 (en) * 2004-01-30 2005-08-25 Dell Products L.P. Method, software and system for multi-path fail-over recovery in sequential storage systems
CN101741831A (zh) * 2008-11-10 2010-06-16 国际商业机器公司 动态物理和虚拟多路径输入/输出的方法、系统和装置
CN102984002A (zh) * 2012-11-27 2013-03-20 华为技术有限公司 一种处理i/o超时的方法和装置
CN104461951A (zh) * 2014-11-19 2015-03-25 浪潮(北京)电子信息产业有限公司 动态管理物理和虚拟多路径i/o的方法及系统
CN105760261A (zh) * 2014-12-16 2016-07-13 华为技术有限公司 业务输入输出io处理方法和装置

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP4210280A4

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023197972A1 (zh) * 2022-04-14 2023-10-19 华为技术有限公司 一种光传输设备、业务设备、业务传输的方法和系统

Also Published As

Publication number Publication date
EP4210280A4 (en) 2024-03-13
US20230205654A1 (en) 2023-06-29
EP4210280A1 (en) 2023-07-12
CN114257541A (zh) 2022-03-29

Similar Documents

Publication Publication Date Title
WO2022052953A1 (zh) 一种故障链路的切换方法、系统及相关设备
US10938710B2 (en) Protection switching method and system, and network device
CN106330475B (zh) 一种通信系统中管理主备节点的方法和装置及高可用集群
KR101498413B1 (ko) 파이버 채널 포워더 패브릭 로그인 시퀀스
CN107707628B (zh) 用于传输数据处理请求的方法和装置
US9838245B2 (en) Systems and methods for improved fault tolerance in solicited information handling systems
WO2011151222A1 (en) Path error correction in storage area networks
JP2006504186A (ja) 複数の伝送路フェイルオーバー、フェイルバックおよび負荷分散を備えるシステム
JP2012108905A (ja) 決定論的sasディスカバリ及びコンフィギュレーションの方法
CN111343019B (zh) 一种重连方法、装置和存储介质
CN107948063B (zh) 一种建立聚合链路的方法和接入设备
US20140095754A1 (en) Back-Off Retry with Priority Routing
WO2021047619A1 (zh) 虚拟网卡链路状态设置方法、装置及存储介质
CN108512753A (zh) 一种集群文件系统中消息传输的方法及装置
US7895300B1 (en) Systems and methods for testing device ports in a storage area network
WO2018054109A1 (zh) 一种端口设置方法、装置及系统
CN111352574B (zh) 路径切换的方法、装置及计算机可读存储介质
CN109445984B (zh) 一种业务恢复方法、装置、仲裁服务器以及存储系统
US11860719B2 (en) Method for implementing storage service continuity in storage system, front-end interface card, and storage system
CN110661599B (zh) 一种主、备节点间的ha实现方法、装置及存储介质
CN113949623B (zh) Mlag双主异常修复方法、装置、电子设备及存储介质
CN112650440B (zh) 路径替换方法及装置
JP2015114952A (ja) ネットワークシステム、監視制御装置およびソフトウェア検証方法
US8111610B2 (en) Flagging of port conditions in high speed networks
JP2000244526A (ja) 多重化したネットワーク接続装置システム

Legal Events

Date Code Title Description
NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 2021866006

Country of ref document: EP

Effective date: 20230402