Management method of cluster switch and related device
By using the destination port number and preset mapping table of the SNMP message in the cluster switch to forward or process the packet, the cluster switch management efficiency and reliability problems are solved, and efficient network management is achieved.
Patent Information
- Application Number
- CN202411890304.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-20
- Publication Date
- 2025-03-25
AI Technical Summary
How to effectively manage each switch in a cluster switch to improve the efficiency and reliability of network management.
After receiving the SNMP message by commanding the switch, it is determined whether the destination port number is the same as the SNMP port number. If the same, the message will be processed; if it is different and in the preset mapping table, the message will be forwarded to the target switch for processing.
It realizes accurate forwarding or local processing of packets by presetting the mapping table and SNMP packet destination port number without adding hardware devices, improves efficient management of cluster switches, and improves network management efficiency, reliability and scalability.
Smart Images

Figure CN119696982A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of network technology, and in particular to a cluster switch management method and related devices. Background Art
[0002] Cluster Switch System (CSS) refers to a network technology that combines multiple switch devices that support cluster features and logically virtualizes them into one switch device. A cluster includes a command switch and multiple member switches, and the command switch can manage the member switches. A cluster switch only needs to occupy one IP address in the network (only the external IP address of the command switch is displayed to the outside, and the internal IP address of each switch in the cluster switch is not displayed to the outside), thereby saving network resources. How to effectively manage each switch in a cluster switch has become one of the technical problems that need to be solved in the field of network technology. Summary of the invention
[0003] Based on the above problems, the present application provides a cluster switch management method to manage each switch in the cluster switch, improve the efficiency and reliability of network management, and provide strong support for building a stable, efficient and flexible network environment.
[0004] The embodiments of the present application disclose the following technical solutions:
[0005] In a first aspect, the present application provides a cluster switch management method, wherein the cluster switch includes a command switch and multiple member switches, and the method includes:
[0006] After receiving the SNMP message, the command switch determines whether the destination port number in the SNMP message is the same as the SNMP port number of the command switch;
[0007] If it is determined that the destination port number is the same as the SNMP port number of the command switch, the command switch processes the SNMP message to generate a first reply message;
[0008] If it is determined that the destination port number is different from the SNMP port number of the command switch, and the destination port number is a port number in a preset mapping table, then based on the destination port number and the preset mapping table, determine the target switch; forward the SNMP message to the target switch; process the SNMP message by the target switch to generate a second reply message; the target switch is one of the multiple member switches; the preset mapping table indicates the correspondence between the SNMP port number of the member switch and the IP address of the member switch inside the cluster switch.
[0009] In an optional implementation, determining the target switch based on the destination port number and the preset mapping table includes:
[0010] Determine the mapped IP address based on the destination port number and the preset mapping table;
[0011] A switch having the mapped IP address among the multiple member switches is used as the target switch.
[0012] In an optional implementation manner, forwarding the SNMP message to the target switch includes:
[0013] A first message header is generated based on a forwarding table, the mapped IP address and the SNMP port number of the command switch; the forwarding table is composed of a source IP address, a destination address, a source port number and a destination port number in the SNMP message; the source IP address in the first message header is the source IP address in the SNMP message, the destination IP address is the mapped IP address, the source port number is the source port number in the SNMP message, and the destination port number is the SNMP port number of the command switch;
[0014] Based on the first message header, the SNMP protocol is sent to the target switch through the command switch.
[0015] In an optional implementation, after the second reply message is generated, the method further includes:
[0016] Generate a second message header based on the forwarding table and the mapped IP address; the source IP address in the second message header is the mapped IP address, the destination IP address is the source IP address in the SNMP message, the source port number is the destination port number in the SNMP message, and the destination port number is the source port number in the SNMP message;
[0017] Based on the second message header, the second reply message is sent to the command switch through the target switch.
[0018] In an optional implementation manner, after the command switch receives the second reply message, the method further includes:
[0019] Based on the forwarding table, a third message header is generated; the source IP address in the third message header is the destination IP address in the SNMP message, the destination IP address is the source IP address in the SNMP message, the source port number is the destination port number in the SNMP message, and the destination port number is the source port number in the SNMP message;
[0020] Based on the third message header, the second reply message is sent to the requester through the command switch; the requester is a sender of the SNMP message to the command switch.
[0021] In an optional implementation, the method includes:
[0022] Based on the forwarding table, a third message header is generated; the source IP address in the third message header is the destination IP address in the SNMP message, the destination IP address is the source IP address in the SNMP message, the source port number is the destination port number in the SNMP message, and the destination port number is the source port number in the SNMP message;
[0023] Based on the third message header, the first reply message is sent to the requester through the command switch; the requester is a sender of the SNMP message to the command switch.
[0024] In an optional implementation, the step of generating the preset mapping table includes:
[0025] Allocate an SNMP port number to each of the member switches through the command switch;
[0026] Based on the SNMP port number of each member switch, the IP address of each member switch inside the cluster switch and the SNMP port number of the command switch, the preset mapping table is constructed through the command switch.
[0027] A second aspect of the present application provides a cluster switch management device, the device comprising:
[0028] The initial information acquisition module is used to determine whether the destination port number in the SNMP message is the same as the SNMP port number of the command switch after the command switch receives the SNMP message;
[0029] A first reply message generating module, configured to process the SNMP message through the command switch to generate a first reply message if it is determined that the destination port number is the same as the SNMP port number of the command switch;
[0030] A second reply message generating module is used to determine a target switch based on the destination port number and the preset mapping table if it is determined that the destination port number is different from the SNMP port number of the command switch and the destination port number is a port number in a preset mapping table; forward the SNMP message to the target switch; process the SNMP message through the target switch to generate a second reply message; the target switch is one of the multiple member switches; the preset mapping table indicates the correspondence between the SNMP port number of the member switch and the IP address of the member switch inside the cluster switch.
[0031] A third aspect of the present application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the method introduced in any implementation manner of the first aspect.
[0032] A fourth aspect of the present application provides an electronic device, including:
[0033] a memory having a computer program stored thereon;
[0034] A processor is used to execute the computer program in the memory to implement the steps of the method introduced in any implementation manner of the first aspect.
[0035] Compared with the prior art, this application has the following beneficial effects:
[0036] The present application discloses a management method for a cluster switch, including: after receiving an SNMP message, the command switch determines whether the destination port number in the SNMP message is the same as the SNMP port number of the command switch; if they are the same, the command switch processes the SNMP message to generate a first reply message; if it is determined that the destination port number is different from the SNMP port number of the command switch, and the destination port number is a port number in a preset mapping table, the target switch is determined based on the destination port number and the preset mapping table; the SNMP message is forwarded to the target switch; the target switch processes the SNMP message to generate a second reply message. The preset mapping table indicates the corresponding relationship between the SNMP port number of the member switch and the IP address of the member switch inside the cluster switch. In this way, accurate forwarding or local processing of messages can be achieved through the preset mapping table and the destination port number of the SNMP message without adding any additional hardware devices, and efficient management of each switch in the cluster switch can be achieved, thereby improving the efficiency, reliability and scalability of network management. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0038] Figure 1 A schematic diagram of the structure of a cluster switch provided in an embodiment of the present application;
[0039] Figure 2 A schematic diagram of a preset mapping table provided in an embodiment of the present application;
[0040] Figure 3 A flow chart of a cluster switch management method provided in an embodiment of the present application;
[0041] Figure 4 A schematic diagram of a cluster switch processing SNMP messages provided in an embodiment of the present application;
[0042] Figure 5 A schematic diagram of the structure of a cluster switch management device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0043] Cluster Switch System (CSS) refers to a network technology that combines multiple switch devices that support cluster features and logically virtualizes them into one switch device. A cluster includes a command switch and multiple member switches, and the command switch can manage the member switches. A cluster switch only needs to occupy one IP address in the network (only the external IP address of the command switch is displayed to the outside, and the internal IP address of each switch in the cluster switch is not displayed to the outside), thereby saving network resources. How to effectively manage each switch in a cluster switch has become one of the technical problems that need to be solved in the field of network technology.
[0044] To solve the above problems, the present application discloses a cluster switch management method, including: after receiving an SNMP message, the command switch determines whether the destination port number in the SNMP message is the same as the SNMP port number of the command switch; if they are the same, the command switch processes the SNMP message to generate a first reply message; if it is determined that the destination port number is different from the SNMP port number of the command switch, and the destination port number is a port number in a preset mapping table, the target switch is determined based on the destination port number and the preset mapping table; the SNMP message is forwarded to the target switch; the target switch processes the SNMP message to generate a second reply message. The preset mapping table indicates the corresponding relationship between the SNMP port number of the member switch and the IP address of the member switch inside the cluster switch.
[0045] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0046] To facilitate understanding of the technical solution in this application, the cluster switch is first introduced. Figure 1 A schematic diagram of the structure of a cluster switch provided in an embodiment of the present application. Figure 1 As shown, the cluster switch includes a command switch A and multiple member switches, namely member switch B, member switch C, member switch D, member switch E and member switch F. Each switch in the cluster switch supports the SNMP protocol (Simple Network Management Protocol).
[0047] The command switch in a cluster switch can manage member switches. Specifically:
[0048] First, the command switch A can assign an SNMP port number to each member switch. For example, the command switch A assigns SNMP port number 19501 to member switch B and SNMP port number 19504 to member switch E.
[0049] Then, the command switch A can obtain its own SNMP port number and the SNMP port number of each member switch.
[0050] Secondly, the command switch A integrates a message forwarding processing module, which can forward the received SNMP message to the member switches; at the same time, after receiving the SNMP message, the command switch will obtain the source IP address, destination IP address, source port number and destination port number information in the SNMP message and generate a forwarding table.
[0051] Finally, the command switch can also build a preset mapping table based on the SNMP port number of each member switch, the IP address of each member switch inside the cluster switch, and the SNMP port number of the command switch.
[0052] Figure 2 A schematic diagram of a preset mapping table provided in an embodiment of the present application. The preset mapping table indicates the correspondence between the SNMP port number of a member switch and the IP address of the member switch inside the cluster switch.
[0053] Combination Figure 2 As shown in the figure, the SNMP port number of member switch B is 19501, its mapped IP address is 1.1.1.1, and the mapped port number is the port number of command switch A, that is, 161; the SNMP port number of member switch C is 19502, its mapped IP address is 1.1.1.2, and the mapped port number is the port number of command switch A, that is, 161.
[0054] For the cluster switch, the command switch and each member switch have internal IP addresses. For example, the internal IP address of the command switch A is 1.1.1.10; the internal IP address of the member switch is 1.1.1.1.
[0055] When a cluster switch exists in the network, the cluster switch occupies only one IP address and only displays the external IP address of the command switch (displayed Figure 1 The external IP address of command switch A is 100.1.1.2), and the internal IP address of each switch in the cluster switch is not displayed to the outside.
[0056] Figure 3 A flow chart of a cluster switch management method provided in an embodiment of the present application. Figure 3 As shown, the cluster switch management method disclosed in this application includes:
[0057] S301: After receiving an SNMP message, the command switch determines whether a destination port number in the SNMP message is the same as the SNMP port number of the command switch.
[0058] S302: If it is determined that the destination port number is the same as the SNMP port number of the command switch, the command switch processes the SNMP message to generate a first reply message.
[0059] After receiving the SNMP message sent by the requester, the command switch determines whether the destination port number in the SNMP message is the same as the SNMP port number of the command switch.
[0060] If the destination port number in the SNMP message is the same as the SNMP port number of the command switch, the requester accesses the command switch. The command switch processes the SNMP message and generates the first reply message.
[0061] S303, if it is determined that the destination port number is different from the SNMP port number of the command switch, and the destination port number is a port number in a preset mapping table, then based on the destination port number and the preset mapping table, determine the target switch; forward the SNMP message to the target switch; process the SNMP message through the target switch to generate a second reply message.
[0062] If the destination port number in the SNMP message is different from the SNMP port number of the command switch, but the destination port number in the SNMP message is a port number in the preset mapping table, the destination switch is determined based on the destination port number in the SNMP message and the preset mapping table.
[0063] After receiving the SNMP message and obtaining the destination port number in the message, the command switch determines whether the destination port number is a port number in a preset mapping table if the destination port number is different from the SNMP port number of the command switch. If the destination port number is a port number in the preset mapping table, the mapped IP address corresponding to the destination port number is determined according to the preset mapping table; and then the switch with the mapped IP address among the multiple member switches is used as the target switch.
[0064] After the target switch is determined, the command switch generates a first message header, a second message header, and a third message header based on the forwarding table, the mapped IP address, and the SNMP port number of the command switch.
[0065] The command switch sends the SNMP protocol to the target switch based on the information in the first message header; the target switch generates a second reply message after processing the SNMP protocol; the target switch sends the second reply message to the command switch based on the information in the second message header; after receiving the second reply message, the command switch sends the second reply message to the requester based on the information in the third message header.
[0066] Figure 4A schematic diagram of a cluster switch processing SNMP messages provided in an embodiment of the present application. Figure 4 As shown, after the command switch A receives the SNMP message sent by the requester, the command switch A obtains the source IP address 100.1.1.1, the destination IP address 100.1.1.2, the source port number 100 and the destination port number 19501 in the SNMP message, and generates a forwarding table.
[0067] Command switch A determines that the destination port number 19501 in the SNMP message is not the SNMP port number 161 of command switch A, but the SNMP port number recorded in the preset mapping table; command switch A determines the mapped IP address based on the destination port number in the SNMP message and the preset mapping table; and selects the member switch with the mapped IP address among the multiple member switches in the cluster switch as the target switch. Figure 4 It can be seen from the preset mapping table in that the target switch is member switch B.
[0068] After determining the target switch, i.e., member switch B, the command switch obtains the forwarding table, the mapped IP address, and the SNMP port number of the command switch, and generates a first message header; the source IP address in the first message header is the source IP address (100.1.1.1) in the SNMP message, the destination IP address is the mapped IP address (1.1.1.1), the source port number is the source port number (100) in the SNMP message, and the destination port number is the SNMP port number of the command switch (also called the mapped port number 161); then, according to the information in the first message header, the command switch A sends the SNMP protocol to the member switch B.
[0069] After member switch B receives the SNMP protocol, member switch B processes the SNMP protocol and generates a second reply message. Member switch B generates a second message header based on the forwarding table and the mapped IP address; wherein the source IP address in the second message header is the mapped IP address (1.1.1.1), the destination IP address is the source IP address (100.1.1.1) in the SNMP message, the source port number is the destination port number (19501) in the SNMP message, and the destination port number is the source port number (100) in the SNMP message; then, according to the information in the second message header, member switch B sends a second reply message to command switch A.
[0070] After receiving the second reply message, the command switch A generates a third message header based on the forwarding table; the source IP address in the third message header is the IP address (100.1.1.2) displayed by the command switch to the outside, the destination IP address is the source IP address (100.1.1.1) in the SNMP message, the source port number is the destination port number (19501) in the SNMP message, and the destination port number is the source port number (100) in the SNMP message; then, according to the third message header, the command switch A sends a second reply message to the requester.
[0071] It is understandable that if the destination port number in the SNMP protocol is 161, which is the SNMP port number of the command switch, the command switch does not forward the SNMP protocol externally, and the command switch directly processes the SNMP protocol to generate the first reply message. Then, the command switch generates a third message header based on the forwarding table; the source IP address in the third message header is the IP address displayed by the command switch externally, the destination IP address is the source IP address in the SNMP message, the source port number is the destination port number in the SNMP message, and the destination port number is the source port number in the SNMP message; then, according to the information in the third message header, the command switch sends the first reply message to the requester.
[0072] It can be understood that after the command switch receives the SNMP message, if the destination port number in the SNMP message is different from the port number in the SNMP message, the member switch (target switch) with the destination port number in the preset mapping table is directly forwarded by the command switch to the target switch for processing. In this case, the command switch only completes the message forwarding work, and the actual message processing work is completed by the target switch, so that the workload of the command switch can be reduced.
[0073] The present application discloses a management method for cluster switches. There is no need to modify the standard SNMP protocol. It only requires that each switch in the cluster switch supports the SNMP protocol. This effectively solves the problem of being unable to remotely manage each switch in the cluster switch, improves the efficiency and reliability of network management, and provides strong support for building a stable, efficient and flexible network environment.
[0074] Based on the cluster switch management method disclosed in the above embodiments, the present application also discloses a cluster switch management device. Figure 5 A schematic diagram of the structure of a cluster switch management device provided in an embodiment of the present application. Figure 5 As shown, the cluster switch management device 500 disclosed in the present application includes:
[0075] The initial information acquisition module 501 is used for determining whether the destination port number in the SNMP message is the same as the SNMP port number of the command switch after the command switch receives the SNMP message;
[0076] A first reply message generating module 502 is configured to process the SNMP message through the command switch to generate a first reply message if it is determined that the destination port number is the same as the SNMP port number of the command switch;
[0077] The second reply message generation module 503 is used to determine the target switch based on the destination port number and the preset mapping table if it is determined that the destination port number is different from the SNMP port number of the command switch, and the destination port number is a port number in a preset mapping table; forward the SNMP message to the target switch; process the SNMP message through the target switch to generate a second reply message; the target switch is one of the multiple member switches; the preset mapping table indicates the correspondence between the SNMP port number of the member switch and the IP address of the member switch inside the cluster switch.
[0078] In an optional implementation, the second reply message generating module 503 includes:
[0079] An IP address determination unit, configured to determine a mapped IP address based on the destination port number and the preset mapping table;
[0080] The target switch determining unit is configured to use a switch having the mapped IP address among the multiple member switches as the target switch.
[0081] In an optional implementation, the second reply message generating module 503 includes:
[0082] A first message header generating unit, configured to generate a first message header based on a forwarding table, the mapped IP address and the SNMP port number of the command switch; the forwarding table is formed based on the source IP address, the destination address, the source port number and the destination port number in the SNMP message; the source IP address in the first message header is the source IP address in the SNMP message, the destination IP address is the mapped IP address, the source port number is the source port number in the SNMP message, and the destination port number is the SNMP port number of the command switch;
[0083] A protocol forwarding unit is used to send the SNMP protocol to the target switch through the command switch based on the first message header.
[0084] In an optional implementation, the cluster switch management device 500 further includes:
[0085] A second message header generation module, used to generate a second message header based on the forwarding table and the mapped IP address; the source IP address in the second message header is the mapped IP address, the destination IP address is the source IP address in the SNMP message, the source port number is the destination port number in the SNMP message, and the destination port number is the source port number in the SNMP message;
[0086] The second reply message forwarding module is configured to send the second reply message to the command switch through the target switch based on the second message header.
[0087] In an optional implementation, the cluster switch management device 500 further includes:
[0088] A third message generation module, used to generate a third message header based on the forwarding table; the source IP address in the third message header is the destination IP address in the SNMP message, the destination IP address is the source IP address in the SNMP message, the source port number is the destination port number in the SNMP message, and the destination port number is the source port number in the SNMP message;
[0089] The third reply message forwarding module is used to send the second reply message to the requester through the command switch based on the third message header; the requester is the sender of the SNMP message to the command switch.
[0090] In an optional implementation, the cluster switch management device 500 further includes:
[0091] A third message header generation module, used to generate a third message header based on the forwarding table; the source IP address in the third message header is the destination IP address in the SNMP message, the destination IP address is the source IP address in the SNMP message, the source port number is the destination port number in the SNMP message, and the destination port number is the source port number in the SNMP message;
[0092] The first reply message forwarding module is used to send the first reply message to the requester through the command switch based on the third message header; the requester is the sender of the SNMP message to the command switch.
[0093] In an optional implementation, the cluster switch management device 500 further includes:
[0094] A port number allocation module, used for allocating an SNMP port number to each of the member switches through the command switch;
[0095] The mapping table generating module is used to construct the preset mapping table through the command switch based on the SNMP port number of each member switch, the IP address of each member switch inside the cluster switch and the SNMP port number of the command switch.
[0096] Based on the cluster switch management method and device provided in the above embodiments, the present application also provides a computer-readable storage medium on which a computer program is stored. When the program is executed by a processor, some or all of the steps in the cluster switch management method mentioned above are implemented.
[0097] Based on the cluster switch management method and device provided in the above embodiments, the present application further provides an electronic device, including:
[0098] a memory having a computer program stored thereon;
[0099] The processor is configured to execute the computer program in the memory to implement part or all of the steps in the cluster switch management method provided in the above embodiment.
[0100] It should be noted that each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment. The device embodiment described above is merely schematic, in which the unit described as a separate component may or may not be physically separated, and the component prompted as a unit may or may not be a physical unit, that is, it may be located in one place, or it may be distributed on multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative work.
[0101] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed in the present application should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
Claims
1. A cluster switch management method, characterized in that: The cluster switch includes a command switch and a plurality of member switches, and the method includes: After receiving the SNMP message, the command switch determines whether the destination port number in the SNMP message is the same as the SNMP port number of the command switch; If it is determined that the destination port number is the same as the SNMP port number of the command switch, the command switch processes the SNMP message to generate a first reply message; If it is determined that the destination port number is different from the SNMP port number of the command switch, and the destination port number is a port number in a preset mapping table, then based on the destination port number and the preset mapping table, determine the target switch; forward the SNMP message to the target switch; process the SNMP message by the target switch to generate a second reply message; the target switch is one of the multiple member switches; the preset mapping table indicates the correspondence between the SNMP port number of the member switch and the IP address of the member switch inside the cluster switch.
2. The method according to claim 1, characterized in that The determining of the target switch based on the destination port number and the preset mapping table includes: Determine the mapped IP address based on the destination port number and the preset mapping table; A switch having the mapped IP address among the multiple member switches is used as the target switch.
3. The method according to claim 2, characterized in that The step of forwarding the SNMP message to the target switch includes: A first message header is generated based on a forwarding table, the mapped IP address and the SNMP port number of the command switch; the forwarding table is composed of a source IP address, a destination address, a source port number and a destination port number in the SNMP message; the source IP address in the first message header is the source IP address in the SNMP message, the destination IP address is the mapped IP address, the source port number is the source port number in the SNMP message, and the destination port number is the SNMP port number of the command switch; Based on the first message header, the SNMP protocol is sent to the target switch through the command switch.
4. The method according to claim 2, characterized in that: After generating the second reply message, the method further includes: Generate a second message header based on the forwarding table and the mapped IP address; the source IP address in the second message header is the mapped IP address, the destination IP address is the source IP address in the SNMP message, the source port number is the destination port number in the SNMP message, and the destination port number is the source port number in the SNMP message; Based on the second message header, the second reply message is sent to the command switch through the target switch.
5. The method according to claim 4, characterized in that After the command switch receives the second reply message, the method further includes: Based on the forwarding table, a third message header is generated; the source IP address in the third message header is the destination IP address in the SNMP message, the destination IP address is the source IP address in the SNMP message, the source port number is the destination port number in the SNMP message, and the destination port number is the source port number in the SNMP message; Based on the third message header, the second reply message is sent to the requester through the command switch; the requester is a sender of the SNMP message to the command switch.
6. The method according to claim 1, characterized in that The method comprises: Based on the forwarding table, a third message header is generated; the source IP address in the third message header is the destination IP address in the SNMP message, the destination IP address is the source IP address in the SNMP message, the source port number is the destination port number in the SNMP message, and the destination port number is the source port number in the SNMP message; Based on the third message header, the first reply message is sent to the requester through the command switch; the requester is a sender of the SNMP message to the command switch.
7. The method according to any one of claims 1 to 6, characterized in that The step of generating the preset mapping table includes: Allocate an SNMP port number to each of the member switches through the command switch; Based on the SNMP port number of each member switch, the IP address of each member switch inside the cluster switch and the SNMP port number of the command switch, the preset mapping table is constructed through the command switch.
8. A cluster switch management device, characterized in that: The device comprises: The initial information acquisition module is used to determine whether the destination port number in the SNMP message is the same as the SNMP port number of the command switch after the command switch receives the SNMP message; A first reply message generating module, configured to process the SNMP message through the command switch to generate a first reply message if it is determined that the destination port number is the same as the SNMP port number of the command switch; A second reply message generating module is used to determine a target switch based on the destination port number and the preset mapping table if it is determined that the destination port number is different from the SNMP port number of the command switch and the destination port number is a port number in a preset mapping table; forward the SNMP message to the target switch; process the SNMP message through the target switch to generate a second reply message; the target switch is one of the multiple member switches; the preset mapping table indicates the correspondence between the SNMP port number of the member switch and the IP address of the member switch inside the cluster switch.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the steps of the method described in any one of claims 1 to 7 are implemented.
10. An electronic device, characterized in that: include: a memory having a computer program stored thereon; A processor, configured to execute the computer program in the memory to implement the steps of the method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Simple network management protocol based cluster management method and system
CN101098256A
SNMPv3-based cluster management method of Ethernet switches
CN101662391A
Communication method and device for network element group network
CN102377835A
Apparatus and method for redirection of network management messages in a cluster of network devices
US6725264B1