Method for assigning identifiers to switches in stack, optical cable, and related device
AssigneeHuawei Technologies Co., Ltd.
InventorsJie Yang, Jincheng Fu
Life of this patent
Estimating the term…
Abstract
A method for assigning identifiers to switches in a stack includes detecting, by a switch, a terminal identifier stored in an optical module that is connected to a stack port of the switch, where the optical module is at one end of an optical cable; and if a condition is met, assigning, by the switch, identifiers to N stackable switches along a direction starting from the switch to another switch connected to the stack port, where the condition includes: a value of the terminal identifier is a specified value, and N is greater than or equal to 2. According to this application, an efficiency of assigning the identifiers to the switches in a stack can be improved.
Claims19
A method implemented by a first switch, the method comprising:
- detecting a plurality of terminal identifiers stored in a plurality of optical modules, wherein each of the optical modules connects to one of a plurality of stack ports of the first switch, and wherein each of the optical modules is located at a first end of an optical cable;
- performing a comparison of the terminal identifiers to a pre-defined specified value;
- and
- assigning, based on the comparison, when all values of the terminal identifiers are a same value, and when the same value is the pre-defined specified value, different switch identifiers to N stackable switches along a selected direction selected from two possible directions,
- wherein the two possible directions are opposed to each other,
- wherein the selected direction is from the first switch to a second switch connected to the stack ports, and
- wherein N is greater than or equal to 2.
A first switch comprising:
- a plurality of stack ports configured to connect to a plurality of optical modules, wherein each of the optical modules is located at a first end of an optical cable;
- a detector configured to detect a plurality of terminal identifiers stored in the optical modules;
- and
- an assigner coupled to the detector and configured to assign, based on a comparison of the terminal identifiers to a pre-defined specified value, when all values of the terminal identifiers are a same value, and when the same value is the pre-defined specified value, different switch identifiers to N stackable switches along a selected direction selected from two possible directions,
- wherein the two possible directions are opposed to each other,
- wherein the selected direction is from the first switch to a second switch connected to the stack ports, and
- wherein N is greater than or equal to 2.
A first device comprising:
- a plurality of stack ports;
- and
- a processor coupled to the stack ports and configured to:
- detect a plurality of terminal identifiers stored in a plurality of optical modules connected to the stack ports, wherein each of the optical modules is located at a first end of an optical cable;
- perform a comparison of the terminal identifiers to a pre-defined specified value;
- and
- assign, based on the comparison, when all values of the terminal identifiers are a same value, and when the same value is the pre-defined specified value, different switch identifiers to N stackable devices along a selected direction selected from two possible directions,
- wherein the two possible directions are opposed to each other,
- wherein the selected direction is from the first device to a second device connected to the stack ports, and
- wherein N is greater than or equal to 2.
Dependencies are inferred from the claim text.