CN107547271B - Method and device for recovering stacked equipment - Google Patents
Method and device for recovering stacked equipment Download PDFInfo
- Publication number
- CN107547271B CN107547271B CN201710698087.8A CN201710698087A CN107547271B CN 107547271 B CN107547271 B CN 107547271B CN 201710698087 A CN201710698087 A CN 201710698087A CN 107547271 B CN107547271 B CN 107547271B
- Authority
- CN
- China
- Prior art keywords
- stacking
- sub
- devices
- stacking device
- member devices
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000000034 method Methods 0.000 title claims abstract description 22
- 238000011084 recovery Methods 0.000 claims description 34
- 238000001514 detection method Methods 0.000 claims description 11
- 238000005516 engineering process Methods 0.000 description 7
- 238000010586 diagram Methods 0.000 description 6
- 230000006855 networking Effects 0.000 description 4
- 238000013467 fragmentation Methods 0.000 description 2
- 238000006062 fragmentation reaction Methods 0.000 description 2
- 230000003993 interaction Effects 0.000 description 2
- 230000003287 optical effect Effects 0.000 description 2
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 239000007787 solid Substances 0.000 description 1
Images
Landscapes
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
The present disclosure relates to a method and an apparatus for recovering a stacking device, which are applied to a main member device in a sub-stacking device in a disabled state formed by splitting the stacking device, and the method for recovering includes: detecting whether all member devices in the sub-stacking devices to which the sub-stacking devices belong are the same as all member devices in the stacking devices before the stacking devices are split; and recovering the service interfaces of all the member devices of the sub-stacking device to which the sub-stacking device belongs under the condition that all the member devices of the sub-stacking device to which the sub-stacking device belongs are detected to be the same as all the member devices of the stacking device before the stacking device is split. Therefore, the stacking equipment can be restored to a normal working state, and the stacking equipment can normally run.
Description
Technical Field
The present disclosure relates to the field of communications technologies, and in particular, to a method and an apparatus for recovering a stacking device.
Background
An Intelligent Resilient Framework (IRF) is a virtualization technology, and a core idea of the IRF is to connect multiple devices through stacking ports to form a stacking link, so as to virtualize the multiple devices into one device, where the multiple devices may be referred to as a stacking device, and each device is referred to as a member device.
IRF fragmentation can result when the stack link between member devices is broken. One stacking device is split to form a plurality of new stacking devices.
In the prior art, the IRF split is detected by MAD (Multi-Active Detection), and one of the stacked devices formed after the split is in a normal operating state, while the remaining stacked devices are migrated to a Recovery (disabled) state.
After the failed stacking link is repaired, if a user carelessly restarts the stacking device in the working state, each member device of the restarted stacking device will be added into the stacking device in the Recovery state, so that all service ports except the reserved port on the member device in the original stacking device in the working state are all closed, and the entire stacking system does not have the stacking device in the working state and cannot normally operate.
Disclosure of Invention
In view of this, the present disclosure provides a method and an apparatus for recovering a stacking apparatus.
According to an aspect of the present disclosure, there is provided a recovery method of a stacking device, which is applied to a main member device in a sub-stacking device in a disabled state formed by splitting of the stacking device, the recovery method including: detecting whether all member devices in the sub-stacking devices to which the sub-stacking devices belong are the same as all member devices in the stacking devices before the stacking devices are split; and recovering the service interfaces of all the member devices of the sub-stacking device to which the sub-stacking device belongs under the condition that all the member devices of the sub-stacking device to which the sub-stacking device belongs are detected to be the same as all the member devices of the stacking device before the stacking device is split.
According to another aspect of the present disclosure, there is provided a recovery apparatus for a stacking device, which is applied to a main member device of a sub-stacking device in a disabled state formed by splitting of the stacking device, the recovery apparatus including: the detection module is used for detecting whether all member devices in the sub-stacking devices to which the detection module belongs are the same as all member devices in the stacking devices before the stacking devices are split; a restoring module, configured to restore service interfaces of all member devices of the sub-stacking device to which the detecting module belongs, when the detecting module detects that all member devices of the sub-stacking device to which the detecting module belongs are the same as all member devices of the stacking device before the stacking device is split.
Therefore, the stacking equipment can be recovered to a normal working state, and can normally run, so that the stacking equipment which is in a conflict state for a long time and caused by misoperation when the stacking equipment is recovered can be recovered to be normal as soon as possible, and the situation that a network is unavailable for a long time due to the fact that the physical interfaces of member equipment such as a switch or a router in the stacking equipment are closed by mistake can be prevented.
Other features and aspects of the present disclosure will become apparent from the following detailed description of exemplary embodiments, which proceeds with reference to the accompanying drawings.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate exemplary embodiments, features, and aspects of the disclosure and, together with the description, serve to explain the principles of the disclosure.
Fig. 1 is a schematic diagram of stacked networking in an embodiment of the disclosure.
Fig. 2 is a flowchart illustrating a method of recovering a stacked device according to an exemplary embodiment.
Fig. 3 is a block diagram illustrating a structure of a recovery apparatus of a stacking apparatus according to an exemplary embodiment.
Fig. 4 is a block diagram illustrating a recovery apparatus 900 for a stacked device according to an example embodiment.
Detailed Description
Various exemplary embodiments, features and aspects of the present disclosure will be described in detail below with reference to the accompanying drawings. In the drawings, like reference numbers can indicate functionally identical or similar elements. While the various aspects of the embodiments are presented in drawings, the drawings are not necessarily drawn to scale unless specifically indicated.
The word "exemplary" is used exclusively herein to mean "serving as an example, embodiment, or illustration. Any embodiment described herein as "exemplary" is not necessarily to be construed as preferred or advantageous over other embodiments.
Furthermore, in the following detailed description, numerous specific details are set forth in order to provide a better understanding of the present disclosure. It will be understood by those skilled in the art that the present disclosure may be practiced without some of these specific details. In some instances, methods, means, elements and circuits that are well known to those skilled in the art have not been described in detail so as not to obscure the present disclosure.
Fig. 1 is a schematic diagram of one example of stacked networking in an embodiment of the present disclosure. As shown in fig. 1, the stack device 1 includes a member device a and a member device B, the member device is, for example, a switch or a router, and the example of the present invention is described by taking the case that the stack device includes two member devices, and of course, the case that the stack device includes more than two member devices is also applicable to the present invention. In the example of fig. 1, member device a and member device B each include a stacking port and an ethernet interface. The connection path between the stacking ports of member device a and member device B is called a stacking link. For example, member device A has a stacking port of XGE1/1/2 and member device A has a GE (Gigabit Ethernet) interface of GE1/0/2, member device B has a stacking port of XGE2/1/1 and member device B has an Ethernet interface of GE 2/0/1. The member device a and the member device B may be a master member device of the stacking device 1, for example, the member device a is a master member device, and the member device B is a slave member device.
In the stacking device, each member device advertises the state of the member device, the connection relationship of the member device, such as the connection relationship of the stacking port, the member device number, the priority of the member device, and the like (i.e. topology information) through a stacking port interaction Hello message. Each member device locally records the known topology information and periodically sends the known topology information out of the stacking port, and after receiving the topology information sent by other member devices, the locally recorded topology information is updated, so that all the member devices can collect complete topology information. For example, member device a in fig. 1 collects topology information including member device a and member device B, and correspondingly, member device B in fig. 1 also collects topology information including member device a and member device B.
When the stacking link between the member device a and the member device B in fig. 1 is broken, the stacking device 1 may be split, for example, into the sub-stacking device 2 and the sub-stacking device 3, the sub-stacking device 2 and the sub-stacking device 3 cannot communicate with each other through the stacking port, and the sub-stacking device 2 and the sub-stacking device 3 are each a separate stacking device and have the same configuration as the stacking device 1, which may cause a conflict.
The fragmentation of the stacked devices can be detected and processed by MAD (Multi-Active Detection) technology to prevent the occurrence of the collision. For example, in the case that the MAD technology is adopted to detect that the stacking device is split, the MAD technology reserves one sub-stacking device in the split stacking device, and closes all traffic interfaces of other sub-stacking devices after the split. Wherein the traffic interface comprises an interface for stack traffic forwarding, such as an ethernet interface, but does not comprise a stack port. That is, the MAD technique makes the state of the reserved sub-stacking device a normal operating state, and makes the state of the sub-stacking device with all traffic interfaces turned off a disabled state (Recovery). This can prevent the occurrence of the collision.
After the above processing is performed by using the MAD technology, if the failure is recovered, the stack device needs to be recovered to normal, and the sub-stack device in the Recovery state needs to be manually recovered. The manual operation is not intelligent, but also causes misoperation, for example, the sub-stacking device in the normal working state is restarted, so that all member devices in the sub-stacking device in the normal working state are added into the sub-stacking device in the Recovery state, and the whole stacking device cannot normally run.
For example, when the stacking device 1 in fig. 1 is split, it may be detected by using the MAD technology that the stacking device 1 is split into the sub-stacking device 2 and the sub-stacking device 3, the sub-stacking device 2 is reserved, and all service interfaces of the sub-stacking device 3 are closed, and then, when the stacking device is recovered, the sub-stacking device 2 is mistakenly restarted, which may cause the member device a of the sub-stacking device 2 to also join the sub-stacking device 3 in the Recovery state, so that neither the sub-stacking device 2 nor the sub-stacking device 3 may not normally operate.
For the purpose of more clearly describing the present disclosure, the embodiments of the present disclosure will be described in detail below by taking the stacked networking shown in fig. 1 as an example.
Fig. 2 is a flowchart illustrating a recovery method of a stacking device, which may be applied to a primary member device of a sub-stacking device in a disabled state formed by splitting of the stacking device, according to an example embodiment. As shown in fig. 2, the recovery method may include the steps of:
in step S210, it is detected whether all member devices in the sub-stacking device to which the sub-stacking device belongs are the same as all member devices in the stacking device before the splitting of the stacking device.
In a possible implementation manner, first, it can be known from the above description that, based on the stack port interaction hello packet, the main member device in the sub-stack device in the disabled state can acquire the information of all the member devices in the sub-stack device. And, before the stacking device is split, any member device in the stacking device can acquire information of all member devices in the stacking device. Therefore, the main member device of the sub-stack device in the disabled state may compare the member device information acquired twice before and after the splitting, thereby detecting whether all the member devices of the sub-stack device in the disabled state are identical to all the member devices of the stack device.
If not, for example, one or more member devices of all the member devices in the stack device are not member devices of the child stack device in the disabled state, it indicates that the child stack device is not generated by joining the child stack device in the normal operating state to the child stack device in the Recovery state after the stack device is split due to restarting the child stack device in the normal operating state, and therefore, no processing is performed.
On the contrary, if the same, that is, all the member devices in the stack devices are member devices in the sub-stack devices in the disabled state, it indicates that the sub-stack device is generated by joining the sub-stack device in the normal operation state to the sub-stack device in the Recovery state after the stack device is split, due to the restart of the sub-stack device in the normal operation state, and thus the following step S230 is performed.
For example, in the stack networking shown in fig. 1, the member device a detects that all member devices, i.e., the member device a and the member device B, in the sub-stack device 3 are the same as all member devices, i.e., the member device a and the member device B, in the stack 1, and proceeds to perform the following step S230.
In step S230, in the case that it is detected that all member devices in the sub-stacking device to which the sub-stacking device belongs are the same as all member devices in the stacking device before the splitting of the stacking device, the service interfaces of all member devices of the sub-stacking device to which the sub-stacking device belongs are restored.
Therefore, the stacking equipment can be recovered to a normal working state, and can normally run, so that the stacking equipment which is in a conflict state for a long time and caused by misoperation when the stacking equipment is recovered can be recovered to be normal as soon as possible, and the phenomenon that a network is unavailable for a long time due to the fact that physical interfaces of member equipment, such as switches or routers, in the stacking equipment are closed by mistake can be prevented.
In a possible implementation manner, the main member device may obtain the service interfaces of all the member devices in the sub-stacking device by obtaining topology information of the service interface carrying the member device. The master member device may then traverse the traffic interfaces of all member devices of the sub-stacking device in a predetermined order to restore the traffic interfaces of all member devices of the sub-stacking device one by one.
Illustratively, the service interfaces of all the member devices of the sub-stack device are sequentially restored according to the sequence from small to large of the service interfaces of all the member devices of the sub-stack device.
Illustratively, according to the descending order of the service interfaces of all the member devices of the sub-stack device, the service interfaces of all the member devices of the sub-stack device are restored in sequence.
Illustratively, if a chained topology is adopted among the member devices in the sub-stacking device, the service interfaces of all the member devices of the sub-stacking device are restored in sequence according to the sequence of the chained topology.
Illustratively, the service interfaces of all member devices of the sub-stack device are traversed according to a preset sequence, and the service interfaces of all member devices of the sub-stack device are sequentially restored.
In one possible implementation, detecting whether all member devices in the sub-stacking device to which the sub-stacking device belongs are the same as all member devices in the stacking device before the splitting of the stacking device includes: every preset time interval, detecting whether all member devices in the sub-stacking devices to which the sub-stacking devices belong are the same as all member devices in the stacking devices before the stacking devices are split.
Thus, the recovery method of the present disclosure may be periodically performed with a predetermined time as a period.
In a possible implementation manner, detecting whether all member devices in the sub-stacking device to which the sub-stacking device belongs are the same as all member devices in the stacking device before the splitting of the stacking device at predetermined intervals includes: starting a timer with preset time; when the predetermined time has elapsed since the timer was started, it is detected whether all member devices in the sub-stack to which the self belongs are the same as all member devices in the stack device before the stack device is split.
Illustratively, the predetermined time is 5 seconds.
Fig. 3 is a block diagram illustrating a structure of a recovery apparatus of a stacking apparatus according to an exemplary embodiment. The recovery apparatus 300 can be applied to a main member device among sub-stacking devices in a disabled state formed by splitting of the stacking device. As shown in fig. 3, the recovery apparatus 300 may include a detection module 310 and a recovery module 330.
The detecting module 310 is used to detect whether all member devices in the sub-stacking devices to which the detecting module belongs are the same as all member devices in the stacking device before the stacking device is split. The restoring module 330 is connected to the detecting module 310, and is configured to restore the traffic interfaces of all member devices of the sub-stack device in case that the detecting module 310 detects that all member devices of the sub-stack device to which the detecting module belongs are the same as all member devices of the stack device before the stack device is split.
In one possible implementation, the detection module 310 is configured to: every preset time interval, detecting whether all member devices in the sub-stacking devices to which the sub-stacking devices belong are the same as all member devices in the stacking devices before the stacking devices are split.
In one possible implementation, the detection module 310 is configured to: starting a timer with preset time; when a predetermined time has elapsed from when the timer is started, it is detected whether all member devices in the sub-stacking devices to which the sub-stacking devices belong are the same as all member devices in the stacking device before the splitting of the stacking device.
In one possible implementation, the recovery module 330 is configured to: and traversing the service interfaces of all member devices of the sub-stacking device to which the sub-stacking device belongs according to a preset sequence, and sequentially recovering the service interfaces of all member devices of the sub-stacking device to which the sub-stacking device belongs.
With regard to the apparatus in the above-described embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
Fig. 4 is a block diagram illustrating a recovery apparatus 900 for a stacked device according to an example embodiment. Referring to fig. 4, the recovery apparatus 900 may include a processor 901, a machine-readable storage medium 902 storing machine-executable instructions. The processor 901 and the machine-readable storage medium 902 may communicate via a system bus 903. Also, the processor 901 performs the above-described restoration method of the stacked device by reading machine-executable instructions in the machine-readable storage medium 902 corresponding to the restoration method of the stacked device.
The machine-readable storage medium 902 referred to herein may be any electronic, magnetic, optical, or other physical storage device that can contain or store information such as executable instructions, data, and the like. For example, the machine-readable storage medium may be: a RAM (random Access Memory), a volatile Memory, a non-volatile Memory, a flash Memory, a storage drive (e.g., a hard drive), a solid state drive, any type of storage disk (e.g., an optical disk, a dvd, etc.), or similar storage medium, or a combination thereof.
Having described embodiments of the present disclosure, the foregoing description is intended to be exemplary, not exhaustive, and not limited to the disclosed embodiments. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The terms used herein were chosen in order to best explain the principles of the embodiments, the practical application, or technical improvements to the techniques in the marketplace, or to enable others of ordinary skill in the art to understand the embodiments disclosed herein.
Claims (8)
1. A recovery method of a stacking device, which is applied to a main member device in a sub-stacking device in a disabled state formed by splitting of the stacking device, is characterized by comprising the following steps:
detecting whether all member devices in the sub-stacking devices to which the sub-stacking devices belong are the same as all member devices in the stacking devices before the stacking devices are split;
and recovering the closed service interfaces of all the member devices of the sub-stacking device to which the sub-stacking device belongs in the case of detecting that all the member devices of the sub-stacking device to which the sub-stacking device belongs are the same as all the member devices of the stacking device before the stacking device is split.
2. The recovery method of claim 1, wherein detecting whether all member devices in the child stacking devices to which the child stacking device belongs are the same as all member devices in the stacking device before the stacking device is split comprises:
detecting whether all member devices in the sub-stacking devices to which the sub-stacking devices belong are the same as all member devices in the stacking devices before the stacking devices are split every preset time interval.
3. The recovery method according to claim 2, wherein detecting whether all member devices in the sub-stacking devices to which the sub-stacking device belongs are the same as all member devices in the stacking device before the stacking device is split at predetermined intervals comprises:
starting a timer with the timing being the preset time;
detecting whether all member devices in the sub-stacking device to which the sub-stacking device belongs are the same as all member devices in the stacking device before the stacking device is split when the predetermined time elapses from when the timer is started.
4. The recovery method according to any of claims 1 to 3, wherein recovering the closed traffic interfaces of all member devices of the child stack device comprises:
and traversing the closed service interfaces of all the member devices of the sub-stacking device to which the sub-stacking device belongs according to a preset sequence, and sequentially recovering the closed service interfaces of all the member devices of the sub-stacking device to which the sub-stacking device belongs.
5. A recovery apparatus for a stacking device, applied to a main member device in a sub-stacking device in a disabled state formed by splitting of the stacking device, the recovery apparatus comprising:
the detection module is used for detecting whether all member devices in the sub-stacking devices to which the detection module belongs are the same as all member devices in the stacking devices before the stacking devices are split;
a restoring module, configured to restore the closed service interfaces of all the member devices of the sub-stacking device to which the detecting module belongs, when the detecting module detects that all the member devices of the sub-stacking device to which the detecting module belongs are the same as all the member devices of the stacking device before the stacking device is split.
6. The recovery apparatus of claim 5, wherein the detection module is configured to:
detecting whether all member devices in the sub-stacking devices to which the sub-stacking devices belong are the same as all member devices in the stacking devices before the stacking devices are split every preset time interval.
7. The recovery apparatus of claim 6, wherein the detection module is configured to:
starting a timer with the timing being the preset time;
detecting whether all member devices in the sub-stacking device to which the sub-stacking device belongs are the same as all member devices in the stacking device before the stacking device is split when the predetermined time elapses from when the timer is started.
8. The recovery apparatus according to any one of claims 5 to 7, wherein the recovery module is configured to:
and traversing the closed service interfaces of all the member devices of the sub-stacking device to which the sub-stacking device belongs according to a preset sequence, and sequentially recovering the closed service interfaces of all the member devices of the sub-stacking device to which the sub-stacking device belongs.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710698087.8A CN107547271B (en) | 2017-08-15 | 2017-08-15 | Method and device for recovering stacked equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710698087.8A CN107547271B (en) | 2017-08-15 | 2017-08-15 | Method and device for recovering stacked equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN107547271A CN107547271A (en) | 2018-01-05 |
CN107547271B true CN107547271B (en) | 2021-03-02 |
Family
ID=60971491
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710698087.8A Active CN107547271B (en) | 2017-08-15 | 2017-08-15 | Method and device for recovering stacked equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107547271B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109445975B (en) * | 2018-10-18 | 2022-05-10 | 新华三技术有限公司 | Exception handling method, logic device and member equipment |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6272139B1 (en) * | 1997-12-29 | 2001-08-07 | Nortel Networks Limited | Signaling protocol for rerouting ATM connections in PNNI environments |
CN102946321A (en) * | 2012-10-16 | 2013-02-27 | 杭州华三通信技术有限公司 | IRF (intelligent resilient framework) network-based fault handling method and device |
CN103354504A (en) * | 2013-06-25 | 2013-10-16 | 杭州华三通信技术有限公司 | Method and apparatus for managing virtual network equipment |
-
2017
- 2017-08-15 CN CN201710698087.8A patent/CN107547271B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6272139B1 (en) * | 1997-12-29 | 2001-08-07 | Nortel Networks Limited | Signaling protocol for rerouting ATM connections in PNNI environments |
CN102946321A (en) * | 2012-10-16 | 2013-02-27 | 杭州华三通信技术有限公司 | IRF (intelligent resilient framework) network-based fault handling method and device |
CN103354504A (en) * | 2013-06-25 | 2013-10-16 | 杭州华三通信技术有限公司 | Method and apparatus for managing virtual network equipment |
Also Published As
Publication number | Publication date |
---|---|
CN107547271A (en) | 2018-01-05 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP5508289B2 (en) | Network recovery system and method from multilink failure | |
US10277454B2 (en) | Handling failure of stacking system | |
US8824275B2 (en) | Route calculating after switching occurs from a primary main control board to a standby main control board | |
CN107612754B (en) | Bidirectional forwarding link fault detection method and device and network node equipment | |
CN110572318A (en) | Main/standby switching method and router | |
CN110730125A (en) | Message forwarding method and device, dual-active system and communication equipment | |
US10693761B2 (en) | Computer system including multilayer switches | |
CN107547271B (en) | Method and device for recovering stacked equipment | |
CN107547255B (en) | Cluster system upgrading method, main control board and cluster system | |
KR101075462B1 (en) | Method to elect master nodes from nodes of a subnet | |
CN112134794B (en) | Flow table backup method and device | |
US9769059B2 (en) | Fast interlayer forwarding | |
CN108234358B (en) | Multicast message transmission method, device and machine readable storage medium | |
CN103200092B (en) | A kind of routing daemon management method and equipment based on virtual network device | |
CN115250388A (en) | Method and system for OLT state switching in dual-homing PON protection system and OLT | |
CN107210945B (en) | Method for operating a computer network and computer network | |
KR20150104435A (en) | Method of performing transition of operation mode for a routing processor | |
CN109617716B (en) | Data center exception handling method and device | |
CN110661599B (en) | HA implementation method, device and storage medium between main node and standby node | |
CN109347746B (en) | MAC address learning method and device | |
US10516625B2 (en) | Network entities on ring networks | |
CN102546313B (en) | Multi-activation detection method and multi-activation detection device | |
WO2016202015A1 (en) | Method and apparatus for protecting active and standby access network elements in data communications network | |
CN117411840A (en) | Link failure processing method, device, equipment, storage medium and program product | |
CN111835544A (en) | Monitoring method and system of virtual router based on user mode protocol stack |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |