CN109361781B - Message forwarding method, device, server, system and storage medium - Google Patents

Message forwarding method, device, server, system and storage medium Download PDF

Info

Publication number
CN109361781B
CN109361781B CN201811292902.1A CN201811292902A CN109361781B CN 109361781 B CN109361781 B CN 109361781B CN 201811292902 A CN201811292902 A CN 201811292902A CN 109361781 B CN109361781 B CN 109361781B
Authority
CN
China
Prior art keywords
server
arp request
management port
message
forwarding
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
Application number
CN201811292902.1A
Other languages
Chinese (zh)
Other versions
CN109361781A (en
Inventor
雷鸣春
叶鹏军
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
New H3C Information Technologies Co Ltd
Original Assignee
New H3C Information Technologies Co Ltd
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 New H3C Information Technologies Co Ltd filed Critical New H3C Information Technologies Co Ltd
Priority to CN201811292902.1A priority Critical patent/CN109361781B/en
Publication of CN109361781A publication Critical patent/CN109361781A/en
Application granted granted Critical
Publication of CN109361781B publication Critical patent/CN109361781B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/09Mapping addresses
    • H04L61/10Mapping addresses of different types
    • H04L61/103Mapping addresses of different types across network layers, e.g. resolution of network layer into physical layer addresses or address resolution protocol [ARP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/74Address processing for routing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L2101/00Indexing scheme associated with group H04L61/00
    • H04L2101/60Types of network addresses
    • H04L2101/618Details of network addresses
    • H04L2101/622Layer-2 addresses, e.g. medium access control [MAC] addresses

Abstract

The embodiment of the application provides a message forwarding method, a message forwarding device, a server, a message forwarding system and a storage medium, and relates to the technical field of communication. The method is applied to the server in the message forwarding system comprising a plurality of servers, the shared management port of the server is connected with the adjacent previous device, the special management port of the server is connected with the adjacent next device, and the method comprises the following steps: the server obtains a message to be forwarded sent by the adjacent previous device through the shared management port; the server forwards the message to be forwarded to the next adjacent device through the special management port. The normal forwarding of the message is realized, and because the shared management port and the dedicated management port of the server are respectively connected with different devices, the ports required by the connection devices of the forwarding devices in the message forwarding system can be saved, so that the technical problem that the BMC needs to occupy a large amount of port resources of the forwarding devices when managing the server is solved.

Description

Message forwarding method, device, server, system and storage medium
Technical Field
The present application relates to the field of communications technologies, and in particular, to a method, an apparatus, a server, a system, and a storage medium for forwarding a packet.
Background
A BMC (Baseboard Management Controller) in the server can intelligently manage the server based on an IPMI (Intelligent Platform Management Interface) protocol. There are two types of interfaces provided to the BMC on the server, which are a dedicated management port and a shared management port, respectively.
At present, a dedicated management port and a shared management port on a server can be connected to an access switch, so that the BMC can intelligently manage the server through the connection between the dedicated management port and the shared management port and the forwarding device. If a rack is added, tens to twenty or more servers can be generally installed, twenty to forty or more port resources on the forwarding device need to be occupied to realize management of the servers in cooperation with the BMC, which results in serious occupation of the port resources of the forwarding device.
Disclosure of Invention
The application aims to provide a message forwarding method, a message forwarding device, a server, a message forwarding system and a message forwarding storage medium, and effectively solve the technical problem that the requirement of server management on switch port resources cannot be effectively reduced in the prior art.
In order to achieve the above object, embodiments of the present application are implemented as follows:
in a first aspect, an embodiment of the present application provides a packet forwarding method, which is applied to a server in a packet forwarding system including multiple servers, where a shared management port of the server is connected to an adjacent previous device, and a dedicated management port of the server is connected to an adjacent next device, where the method includes:
the server obtains the message to be forwarded sent by the adjacent previous device through the shared management port;
and the server forwards the message to be forwarded to the next adjacent device through the special management port.
With reference to the first aspect, in some optional implementations, the method further includes:
if the link at the shared management port is disconnected, the server generates a first ARP request containing the MAC address of the server;
the server sends the first ARP request to the next adjacent equipment through the special management port, so that when the next adjacent equipment is forwarding equipment, the forwarding equipment determines to send a message to the shared management port based on the obtained first ARP request; and when the next adjacent device is a server, the next adjacent device generates a second ARP request containing the MAC address of the next adjacent device based on the first ARP request, and forwards the first ARP request and the second ARP request downwards.
With reference to the first aspect, in some optional implementations, the method further includes:
if the link at the shared management port is recovered to be connected from disconnection, the server generates a third ARP request and a fourth ARP request containing the MAC address of the server;
when the next adjacent device is a forwarding device, the server discards the third ARP request; sending the fourth ARP request to the adjacent previous equipment through the shared management port;
when the next adjacent device is a server, the server sends the third ARP request to the next adjacent server through the special management port, so that the next adjacent server generates a fourth ARP request containing the MAC address of the next adjacent server based on the third ARP request and forwards the third ARP request downwards; the server also forwards the fourth ARP request generated by the server and a fourth ARP request sent by the next adjacent server to the previous adjacent device through the shared management port.
With reference to the first aspect, in some optional implementations, the method further includes:
if the link at the shared management port of other servers is disconnected, the server obtains a first ARP request which is generated by the other servers and contains the MAC addresses of the other servers through the shared management port;
the server generates a second ARP request containing the MAC address of the server based on the first ARP request;
the server sends the first ARP request and the second ARP request to the next adjacent equipment through the special management port, so that when the next adjacent equipment is forwarding equipment, the forwarding equipment determines to send a message to the shared management port based on the obtained first ARP request and the obtained second ARP request; and when the next adjacent equipment is a server, forwarding the first ARP request downwards by the next adjacent equipment.
With reference to the first aspect, in some optional implementations, after the server sends the first ARP request and the second ARP request to the next device in the neighborhood through the dedicated management port, the method further includes:
and the server forwards the message to be forwarded received from the special management port to the adjacent previous device from the shared management port.
With reference to the first aspect, in some optional implementations, the method further includes:
when the link at the shared management port of the other server is restored from disconnection to connection, the server obtains a third ARP request containing the MAC address of the other server;
the server generates a fourth ARP request containing the MAC address of the server based on the third ARP request, and sends the fourth ARP request to the adjacent previous equipment through the shared management port;
when the next device is a forwarding device, the server discards the third ARP request;
and when the next device is a server, the server forwards the third ARP request to the next adjacent device through the special management port, so that the next device sends the third ARP request down.
In a second aspect, an embodiment of the present application provides a packet forwarding apparatus, which is applied to a server in a packet forwarding system including multiple servers, where a shared management port of the server is connected to an adjacent previous device, and a dedicated management port of the server is connected to an adjacent next device, where the apparatus includes:
and the first message obtaining module is used for obtaining the message to be forwarded, which is sent by the adjacent previous device, through the shared management port by the server.
And the first message forwarding module is used for the server to forward the message to be forwarded to the next adjacent device through the special management port.
With reference to the second aspect, in some optional implementations, the apparatus further includes:
and the first message generation module is used for generating a first ARP request containing the MAC address of the server if the link at the shared management port is disconnected.
A first message sending module, configured to send the first ARP request to the next adjacent device through the dedicated management port by the server, so that when the next adjacent device is a forwarding device, the forwarding device determines to send a message to the shared management port based on the obtained first ARP request; and when the next adjacent device is a server, the next adjacent device generates a second ARP request containing the MAC address of the next adjacent device based on the first ARP request, and forwards the first ARP request and the second ARP request downwards.
With reference to the second aspect, in some optional implementations, the apparatus further includes:
and the second message generation module is used for generating a third ARP request and a fourth ARP request containing the MAC addresses of the servers if the link at the shared management port is recovered from disconnection to connection.
A second message sending module, configured to discard the third ARP request by the server when the next adjacent device is a forwarding device; and sending the fourth ARP request to the adjacent previous equipment through the shared management port.
The second message sending module is further configured to, when the next adjacent device is a server, send the third ARP request to the next adjacent server through the dedicated management port, so that the next adjacent server generates a fourth ARP request including its MAC address based on the third ARP request and forwards the third ARP request downward; the server also forwards the fourth ARP request generated by the server and a fourth ARP request sent by the next adjacent server to the previous adjacent device through the shared management port.
With reference to the second aspect, in some optional implementations, the apparatus further includes:
and the second message obtaining module is used for obtaining the first ARP request which is generated by other servers and contains the MAC addresses of other servers through the shared management port if the link at the shared management port of other servers is disconnected.
And the third message generation module is used for generating a second ARP request containing the MAC address of the server based on the first ARP request by the server.
A third message sending module, configured to send, by the server, the first ARP request and the second ARP request to the next neighboring device through the dedicated management port, so that when the next neighboring device is a forwarding device, the forwarding device determines to send a message to the shared management port based on the obtained first ARP request and the obtained second ARP request; and when the next adjacent equipment is a server, forwarding the first ARP request downwards by the next adjacent equipment.
With reference to the second aspect, in some optional implementations, the apparatus further includes:
and the second message forwarding module is used for the server to forward the message to be forwarded, which is received from the dedicated management port, to the adjacent previous device from the shared management port.
With reference to the second aspect, in some optional implementations, the apparatus further includes:
and the third message obtaining module is used for obtaining a third ARP request containing the MAC addresses of other servers by the server when the link at the shared management port of the other servers is restored from disconnection to connection.
And the fourth message generation module is used for generating a fourth ARP request containing the MAC address of the server on the basis of the third ARP request and sending the fourth ARP request to the adjacent previous equipment through the shared management port.
And the fourth message sending module is used for discarding the third ARP request by the server when the next device is a forwarding device.
And the fourth message sending module is further configured to, when the next device is a server, forward the third ARP request to an adjacent next device through the dedicated management port by the server, so that the next device downloads the third ARP request.
In a third aspect, an embodiment of the present application provides a server, where the server includes: a host, a network card and a BMC; the network card is respectively connected with the host and the BMC, a shared management port of the server is arranged on the network card, and a special management port of the server is arranged on the BMC;
the BMC is configured to monitor a shared management port of the server and a dedicated management port of the server to execute the message forwarding method according to the first aspect and any implementation manner of the first aspect.
In a fourth aspect, an embodiment of the present application provides a packet forwarding system, where the packet forwarding system includes: a plurality of servers and a forwarding device,
the dedicated management port of each server in the plurality of servers is connected with the shared management port of the next adjacent server to form a link, and the shared management port of the server at the first end of the link and the dedicated management port of the server at the second end of the link are both connected with the forwarding device;
any one of the servers is configured to execute the message forwarding method according to the first aspect and any implementation manner of the first aspect.
In a fifth aspect, an embodiment of the present application provides a computer-readable storage medium having a non-volatile program code executable by a computer, where the program code causes the computer to execute the message forwarding method according to the first aspect and any implementation manner of the first aspect.
The beneficial effects of the embodiment of the application include:
the shared management port based on the server is connected with the adjacent previous device, the message to be forwarded sent by the adjacent previous device is obtained through the shared management port, and the message to be forwarded is forwarded to the adjacent next device through the dedicated management port based on the connection of the dedicated management port of the server and the adjacent next device, so that the normal forwarding of the message is realized. Meanwhile, because the shared management port and the dedicated management port of the server are respectively connected with different devices, the ports required by the connection devices of the forwarding devices in the message forwarding system can be saved, and the technical problem that the BMC needs to occupy a large amount of port resources of the forwarding devices when managing the server is solved.
In order to make the aforementioned objects, features and advantages of the present application more comprehensible, preferred embodiments accompanied with figures are described in detail below.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are required to be used in the embodiments will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present application and therefore should not be considered as limiting the scope, and it will be apparent to those skilled in the art that other related drawings can be obtained from the drawings without inventive effort.
Fig. 1 shows a block diagram of a message forwarding system according to a first embodiment of the present application;
fig. 2 is a block diagram illustrating a structure of a server in a message forwarding system according to a first embodiment of the present application;
fig. 3 is a flowchart illustrating a message forwarding method according to a second embodiment of the present application;
fig. 4 is a schematic diagram illustrating a first application scenario of a message forwarding method according to a second embodiment of the present application;
fig. 5 is a schematic diagram illustrating a second application scenario of a message forwarding method according to a second embodiment of the present application;
fig. 6 shows a block diagram of a message forwarding apparatus according to a third embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. The components of the embodiments of the present application, generally described and illustrated in the figures herein, can be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the present application, presented in the accompanying drawings, is not intended to limit the scope of the claimed application, but is merely representative of selected embodiments of the application. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the present application without inventive step, are within the scope of the present application.
It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures. The terms "first," "second," and the like are used solely to distinguish one from another and are not to be construed as indicating or implying relative importance.
First embodiment
Referring to fig. 1, an embodiment of the present application provides a message forwarding system 10, where the message forwarding system 10 includes: a forwarding device 11 and a plurality of servers 20.
The forwarding device 11 may be a device in a communication network for forwarding a packet, and the forwarding device 11 may be a switch, a router, a gateway, or a bridge. In the present embodiment, the description will be made by taking the forwarding device 11 as an example of a switch, but the present invention is not limited thereto.
Each server 20 of the plurality of servers 20 may be a conventional web server or database server, or the like, or each server 20 may be a cluster of sub-servers formed from a plurality of sub-servers. The description will be made by taking each server 20 as a web server as an example, but the description is not limited thereto.
In this embodiment, each server 20 may include a dedicated management port and a shared management port, and in the plurality of servers 20, the shared management port of the server 20 may be connected to the previous adjacent device, and the dedicated management port of the server 20 may be connected to the next adjacent device. The previous device adjacent to the shared management port of the server 20 may be another server 20 or forwarding device 11, and the next device adjacent to the dedicated management port of the server 20 may also be another server 20 or forwarding device 11.
As an alternative to multiple servers 20 being connected to forwarding device 11, multiple servers 20 may be connected in sequence to form a link. The shared management port of the server 20 at the first end of the link may then be connected to the first port of the forwarding device 11. The shared management port of server 20 at the second end of the link may then be connected to the second port of forwarding device 11. The shared management port of the server 20 located between the first end and the second end of the link may be connected to the dedicated management port of the previous server 20, and the dedicated management port of the server 20 located between the first end and the second end of the link may be connected to the shared management port of the next server 20.
In this embodiment, the forwarding device 11 may default to forward the message to the server 20 in the link through the first port, and after the forwarding device 11 performs ARP entry learning, the forwarding device 11 may forward the message to the server 20 in the link through the second port.
Referring to fig. 2, each server 20 may include: host 21, network card 22, and BMC 23. The network card 22 may be connected to the host 21 and the BMC23, respectively.
The configuration of the server 20 will be described below by taking any one of the plurality of servers 20 as an example.
The host 21 is a core device in the server 20, and the host 21 is used for implementing core functions of each server 20, for example, data interaction, data processing and data storage of the server 20 and other devices.
The Network card 22 may support a Network card of an NCSI (Network Controller side band Interface) protocol, a shared management port of the server 20 is provided on the Network card 22, and the Network card 22 can also be in communication connection with the host 21. In addition, the network card 22 can also be in communication connection with the BMC23 in an NCSI manner, so that the BMC23 can intelligently monitor and manage the host 21 of the server 20 through the network card 22.
BMC23 may include: a Processor 231, a first port 232, and a second port 233, where the Processor 231 may be a Central Processing Unit (CPU), a Network Processor (NP), or the like; but may also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic, discrete hardware components, etc.
The first port 232 may be connected to the network card 22, so that the processor 231 of the BMC23 can monitor and manage the host 21 intelligently through the first port 232 and the network card 22, and in this embodiment, can manage the host 21. The second port 232 of the BMC23 may be a dedicated management port of the server 20.
In this embodiment, the processor 231 of the BMC23 monitors through the shared management port and/or the dedicated management port, and can manage the messages obtained by the shared management port and/or the dedicated management port of each server 20, that is, can execute the message forwarding method described below.
It should be noted that the processor 231 of the BMC23 implements the execution of the message forwarding method, and since the BMC23 is integrated in the server 20, the implementation of the message forwarding method can be understood as being implemented by taking the server 20 as an execution subject as a whole, so that a person skilled in the art can easily understand the present solution.
Second embodiment
The present embodiment provides a message forwarding method, it should be noted that the steps shown in the flowchart of the figure can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown. The present embodiment will be described in detail below.
Referring to fig. 3, in the message forwarding method provided in this embodiment, the message forwarding method is applied to any server in a plurality of servers in a message forwarding system. The message forwarding method comprises the following steps: step S110 and step S120.
Step S110: and the server obtains the message to be forwarded sent by the adjacent previous device through the shared management port.
Step S120: and the server forwards the message to be forwarded to the next adjacent device through the special management port.
The steps of the present application are described in detail below with reference to fig. 3 and 4.
The BMC in the server can manage the server processing message only by powering on, so that the BMC can be powered on, and the BMC is powered on to start and start to operate. After the BMC is powered on, the server can start to execute the message forwarding method on the whole.
When the power is not supplied, the position or the structure of the server in the link may be changed, but the changed server cannot know the position due to the power-off, so after each power-on, the server needs to re-determine the position of the server in the link, so as to determine how to forward the obtained message by determining the position in the link.
In this embodiment, after the power is turned on, the processing mode of the server on the packet is a hybrid mode, that is, the server may analyze and process any obtained unicast or broadcast packet. Then, by analyzing and processing any unicast or broadcast message obtained, the server can determine the location of the server in the link by determining whether to obtain the device advertisement message sent by the forwarding device from a dedicated management port of the server within a preset time.
As an optional manner, the device advertisement message sent by the forwarding device may be an STP message (Spanning Tree Protocol) and/or an LLDP message (Link Layer Discovery Protocol). The STP message may be a message generated and transmitted by the forwarding device, and the LLDP message may be a message generated and transmitted by the forwarding device if the device type indicated by the LLDP message is the forwarding device.
For the forwarding device, the forwarding device may generate and send the STP message and/or the LLDP message uninterruptedly for a certain duration according to a preset rule, where the certain duration may be 5 to 7 seconds. Therefore, if the preset time is set to be longer than the certain time duration, for example, the preset time is set to be 30 seconds, after the power is turned on, the server located at the first end of the link and the server located at the second end of the link are connected to the forwarding device, and the server located at the first end of the link and the server located at the second end of the link can receive the STP message and/or the LLDP message within the preset time duration. Thus, the server can determine whether the server is located at the first end of the link, the second end of the link, or between the first end of the link and the second end of the link by judging whether to obtain the STP message and/or the LLDP message sent by the device from the dedicated management port of the server and whether to obtain the STP message and/or the LLDP message sent by the forwarding device from the shared management port of the server within the preset time.
If the server determines that the STP message is obtained from the shared management port of the server and/or the LLDP message including the forwarding device in the message is obtained by analyzing the obtained message within the preset time, the server may determine that the server is located at the first end of the link, that is, it is determined that the shared management port of the server is connected to the first port of the forwarding device.
If the server determines that the STP message is not obtained from any of the shared management port and the dedicated management port of the server and/or the LLDP message including the forwarding device is obtained in the message by analyzing the obtained message within the preset time, the server may determine that the server is located between the first end of the link and the second end of the link, that is, it is determined that the shared management port and the dedicated management port of the server are not connected to the forwarding device.
If the server determines that the STP message is obtained from the dedicated management port of the server and/or the LLDP message including the forwarding device is obtained from the dedicated management port of the server by analyzing the obtained message within the preset time, the server may determine that the server is located at the second end of the link, that is, it is determined that the dedicated management port of the server is connected to the second port of the forwarding device.
In this embodiment, the server may determine the processing rule for the packet by determining the position of the server in the link, so that the server changes the hybrid processing mode for the packet after being powered on to process the packet according to the processing rule.
In this embodiment, if the server determines that the shared management port of the server is connected to the first port of the forwarding device, or that the shared management port and the dedicated management port of the server are not connected to the forwarding device, the server determines that the processing rule for the packet may include:
the server analyzes the obtained message, and if the message is determined to be a unicast message sent to the server, the server can perform corresponding processing on the unicast message without forwarding; if the unicast message is determined to be sent to other servers or other devices in the network, the server can forward the unicast message without processing the unicast message; if the broadcast message is determined to be the STP message and/or the LLDP message, the server can also perform corresponding processing on the STP message and/or the LLDP message without forwarding; if the broadcast message is determined to be of other types, for example, if the broadcast message is a normal ARP request and the request includes the IP address and the MAC address of the server itself, the server may generate an ARP response to respond to the ARP request; or, if the request is a normal ARP request and the request does not include the IP address and the MAC address of the server itself, the server may forward the ARP request, but if the ARP request is a special ARP request, the server may process the special ARP request to generate another ARP request according to the ARP request, and send the another ARP request and the ARP request to be forwarded out from the non-receiving port together.
In addition, the processing rule determined by the server may further include:
before any type of message is forwarded, the server can judge whether the message needs to be forwarded from a special management port of the server. If the message is not forwarded from the dedicated management port of the server, the message may be forwarded from a corresponding port other than the dedicated management port, and if the message is forwarded from the dedicated management port of the server, the message may be forwarded from the dedicated management port of the server by connecting the shared management port of the server to the first port of the forwarding device or by connecting neither the shared management port of the server nor the dedicated management port of the server to the forwarding device.
It should be noted that, since the shared management port of the server is connected to the first port of the forwarding device or neither the shared management port nor the dedicated management port of the server is connected to the forwarding device, the dedicated management port of the server may be connected to the next server adjacent to the link. Thus, the message forwarded from the dedicated management port of the server can be forwarded to the next adjacent server without being forwarded to the forwarding device to cause a message storm in the link.
In this embodiment, if the server determines that the dedicated management port of the server is connected to the second port of the forwarding device, the determining, by the server, a processing rule for the packet may include:
the server analyzes the obtained message, and if the message is determined to be a unicast message sent to the server, the server can perform corresponding processing on the unicast message without forwarding; if the unicast message is determined to be sent to other servers or other devices in the network, the server can forward the unicast message without processing the unicast message; if the broadcast message is determined to be the STP message and/or the LLDP message, the server can also perform corresponding processing on the STP message and/or the LLDP message without forwarding; if the broadcast message is determined to be of other types, for example, an ARP request, the server may process the ARP request to generate another ARP request according to the ARP request, and send the another ARP request and the ARP request to be forwarded out from the non-receiving port together.
In addition, the processing rule determined by the server may further include:
before any type of message is forwarded, the server can judge whether the message needs to be forwarded from a special management port of the server. If not, the message can be forwarded from the corresponding port, and if so, the message can be discarded without forwarding based on the connection of the dedicated management port of the server and the second port of the forwarding device.
It should be noted that, because the dedicated management port of the server is connected to the second port of the forwarding device, if the message is forwarded from the dedicated management port of the server, the forwarded message may be forwarded to the forwarding device, which may cause a message storm in the link.
After powering on, determining the position of the server in the link, and determining the corresponding processing rule, the server may process the obtained packet according to the determined processing rule, that is, the server may perform step S110.
Step S110: and the server obtains the message to be forwarded sent by the adjacent previous device through the shared management port.
Based on the default state of the forwarding device, the message to be forwarded can be forwarded to the link through the first port, so that the shared management port of the server is connected with the previous adjacent device, and the message to be forwarded sent by the previous adjacent device can be obtained through the shared management port. Based on the position of the server in the link, if the server determines that the server is located at the first end of the link, the adjacent previous device may be a forwarding device, and the server may obtain a message to be forwarded, which is sent by the first port of the forwarding device, through the shared management port; if the server determines that the server is located at the second end of the link or between the first end and the second end, the previous adjacent device may be another server, and the server may obtain the message to be forwarded, which is sent by the dedicated management port of the previous adjacent server, through the shared management port.
Step S120: and the server forwards the message to be forwarded to the next adjacent device through the special management port.
After the server obtains the message to be forwarded, the server may process the message to be forwarded based on the processing rule.
Alternatively, if the server determines that the server is located at the first end or between the first end and the second end, the server may determine that the packet to be forwarded is to be processed based on a processing rule determined by the server being located at the first end or between the first end and the second end, so as to determine whether the packet needs to be forwarded through a dedicated management port of the server. If it is determined that the message to be forwarded can be forwarded through the non-dedicated management port of the server, the server can forward the message to be forwarded through the corresponding non-dedicated management port. If it is determined that the message to be forwarded can be forwarded through the dedicated management port of the server, the server may also process the rule to determine that the message to be forwarded is forwarded to the next adjacent device through the dedicated management port of the server, that is, to the shared management port of the next adjacent server.
If the server determines that the server is located at the second end, the server may determine that the message to be forwarded is to be processed based on the processing rule determined by the server being located at the second end, so as to determine whether forwarding through a dedicated management port of the server is required. If it is determined that the message to be forwarded can be forwarded through the non-dedicated management port of the server, the server can forward the message to be forwarded through the corresponding non-dedicated management port. If the message to be forwarded is determined to be forwarded through the dedicated management port of the server, the server may also process the rule to determine to discard the message to be forwarded and not forward the message to be forwarded.
Assume that the dedicated management port a2 of the server a is connected to the shared management port B1 of the server B, the dedicated management port B2 of the server B is connected to the shared management port C1 of the server C, the dedicated management port C2 of the server C is connected to the shared management port D1 of the server D, the shared management port a1 of the server a is connected to the port E1 of the switch E, and the dedicated management port D2 of the server D is connected to the port E2 of the switch E.
After being powered on, the server A obtains the STP message and/or the LLDP message sent by the switch E through the shared management port A1 to determine that the shared management port A1 is connected with the switch E. The server D obtains the STP message and/or the LLDP message sent by the switch E through the special management port D2 to determine that the special management port D2 is connected with the switch E. And the server B and the server C are determined not to be connected with the switch E because the STP message and/or the LLDP message are not obtained within the preset time length.
After obtaining the message, the server a may forward the message that needs to be forwarded from the dedicated management port a2 to the shared management port B1 of the server B from the dedicated management port a 2; the server B can forward the message which needs to be forwarded from the special management port B2 to the shared management port C1 of the server C from the special management port B2; the server C can forward the message which needs to be forwarded from the dedicated management port C2 to the shared management port D1 of the server D from the dedicated management port C2; the server D may discard the message that needs to be forwarded from the dedicated portal D2 without forwarding.
It can be understood that, in the case of forming a link, the server may correctly process the obtained packet based on the determined processing rule.
In this embodiment, if the link at a shared management port in the link is disconnected, the link at the dedicated management port of the server connected to the shared management port is also disconnected, and the link is divided into two first sub-links and two second sub-links. The first port from the server disconnected from the dedicated management port to the forwarding device is the first sublink. Because the disconnection of the dedicated management port does not affect each server on the first sublink to process the message, that is, each server on the first sublink can process or discard the obtained message normally, each server on the first sublink can continue to operate based on the current processing rule of the message, and does not perform corresponding processing for the disconnected dedicated management port.
However, for a second sublink from the server with the disconnected shared management port to the second port of the forwarding device, the disconnection of the shared management port means that the server on the second sublink cannot obtain the message forwarded by the first port of the forwarding device, and thus the server with the disconnected shared management port cannot normally operate. Therefore, the server on the second sublink can perform corresponding processing, so that the forwarding device performs ARP entry learning on the server on the second sublink, and further, the second sublink can also perform message forwarding normally.
In the following, with reference to fig. 5, when a link at a shared management port in a link is broken, how to perform relevant processing on a server on the second sublink connected to the second port of the forwarding device is described in detail, and how to perform ARP entry learning on the server on the second sublink by the forwarding device is also described in detail.
As one way of the link disconnection at the shared management port of the server, the server can detect the link disconnection at the own shared management port, that is, detect that the state of the own shared management port is Down. In this case, the server can generate a special ARP request according to preset rules.
Optionally, the special ARP request generated by the server may be a first ARP request, a source address in the first ARP request may be a MAC address of a management port of the server, and a destination address in the first ARP request is a special first broadcast address, for example, 127.0.0.1.
In addition, when the first ARP request is generated, the server detects that the link at the shared management port of the server is disconnected, and then the server may further adjust the processing rule of the packet, that is, "the packet that needs to be forwarded from the dedicated management port of the server is forwarded from the dedicated management port of the server only when it is determined that the dedicated management port of the server is not connected to the forwarding device, and the packet that needs to be forwarded from the dedicated management port of the server is discarded when it is determined that the dedicated management port of the server is connected to the forwarding device" to: "regardless of whether the dedicated management port of the server is connected to the forwarding device, the message can be received and sent through the dedicated management port of the server".
After the server generates the first ARP request, the server sends the first ARP request to the next device adjacent to the server through the dedicated management port of the server.
If the second sublink also has a server other than the server, it indicates that the next device adjacent to the server may be the server, and the next server adjacent to the server may generate a second ARP request including its own MAC address based on the first ARP request, and forward the first ARP request and the second ARP request downward. So that each server on the second sub-link, except that server, can perform the same operations as the next server in the neighborhood. The shared management port of each server on the second sub-link except the server may obtain the first ARP request, and the dedicated management port of each server may forward the first ARP request. And each server on the second sub-link except the server can generate each second ARP request containing the MAC address of the management port of each server based on the obtained first ARP request, and the dedicated management port of each server can also send out each generated second ARP request. Therefore, the shared management port of each server obtains the second ARP request sent by each other server, and forwards the second ARP request sent by each other server through the special management port of each server. Thus, the forwarding of each server in turn causes the second port of the forwarding device to obtain the first ARP request and the second ARP request generated by each server. Of course, each server that obtains the first ARP request also adjusts the processing rule of the packet to be the same as the processing rule of the server that is disconnected from the shared management port based on the first ARP request.
If there is no server other than the server on the second sub-link, which indicates that the next device in the neighborhood may be the server, the second port of the forwarding device may obtain the first ARP request sent by the server.
As a way of the link disconnection at the shared management port of the other server before the server, the other server can generate and send a first ARP request containing the MAC address of the management port of the other server, and adjust the processing rule of the other server for the message. Accordingly, the shared management port of the server located on the second sublink can obtain the first ARP request through forwarding of the first ARP request by each server before the server, or the shared management port of the server is connected with the dedicated management ports of other servers whose shared management ports are disconnected to obtain the first ARP request sent by other servers whose shared management ports are disconnected.
Based on the special first broadcast address in the first ARP request, the server can know that the shared management port of the other server is disconnected, and the server can also know that the processing rule of the message needs to be adjusted. Therefore, the server may adjust "the message to be forwarded from the dedicated management port of the server is forwarded from the dedicated management port of the server if it is determined that the dedicated management port of the server is not connected to the forwarding device, and the message to be forwarded from the dedicated management port of the server is discarded if it is determined that the dedicated management port of the server is connected to the forwarding device" to be the same as that of another server whose shared management port is disconnected: "regardless of whether the dedicated management port of the server is connected to the forwarding device, the message can be received and sent through the dedicated management port of the server".
Furthermore, the server can obtain a second ARP request that needs to generate a MAC address of the server based on the first ARP request, and therefore the server can obtain the second ARP request by replacing the MAC address of the management port of the server with the MAC address of the management port of the server in the first ARP request. The server may send the first ARP request and the generated second ARP request to the next device in the neighborhood through a dedicated management port of the server.
If there are other servers below the server on the second sub-link, it is described that the next device adjacent to the second sub-link may be the server, and the next server adjacent to the second sub-link may generate a second ARP request including its own MAC address based on the first ARP request, and forward the first ARP request, the second ARP request sent by the other servers, and the second ARP request generated by itself downward. In this way, each server on the second sub-link, except for the server, may perform the same operation as the next server in the neighborhood, such that the second port of the forwarding device obtains the first ARP request and the second ARP request generated by each server.
If there is no other server below the server on the second sub-link, it means that the next adjacent device may be a forwarding device, so that the second port of the forwarding device can obtain the first ARP request and the second ARP request generated by each server.
If the forwarding device performs ARP entry learning based on the obtained first ARP request and/or the second ARP request generated by each server, the forwarding device may determine that a message may be sent to the dedicated management port of the server at the second end of the link through the second port. After each server on the second sublink adjusts the processing rule of the message, each server can process the obtained message, or each server can forward the message to be forwarded to the shared management port of the adjacent server through the dedicated management port of each server, so that the message to be forwarded is processed and forwarded on the second sublink, and further the server on the second sublink can continue to work normally under the condition that the link is disconnected.
Continuing the foregoing assumption, if server C's shared management port C1 is broken, the link is split into a first sub-link comprising server a and server B, and a second sub-link comprising server C and server D. And the server A and the server B on the first sub-link do not adjust, and continue to process the message based on the original processing rule.
For the second sublink, the server C may adjust its own processing rule for the packet, and send the generated first ARP request to the server D through the dedicated management port C2 of the server C. The shared management port D1 of the server D can obtain the first ARP request, so that the processing rule of the message by itself is adjusted to be the same as the processing rule of the server C according to the first ARP request. Meanwhile, the server D may generate a second ARP request based on the first ARP request, and send both the first ARP request and the second ARP request to the switch E through the dedicated management port D2 of the server D. In this way, the switch E may learn, based on the first ARP request and the second ARP request, that the second sublink may also process the message, and then the switch E may determine that the message is sent to the first sublink through the port E1, and may also send the message to the second sublink through the port E2. Thus, the dedicated management port D2 of the server D can obtain the message sent by the switch E through the port E2. If the message is sent to the server D, the server D can process the message; however, if the message is sent to the server C, the server D may forward the message to the server C through the shared management port D1 of the server D.
In this embodiment, if the link at a shared management port in the link is restored from disconnection to connection, the link at the dedicated management port of the server connected to the shared management port is also restored from disconnection to connection, and the first sub-link and the second sub-link are reconnected to form the complete link.
For a first sublink, a restoration connection of a dedicated management port means that the first sublink no longer exists as a separate sublink. Therefore, the server on the first sub-link may perform corresponding processing, so that the forwarding device performs ARP entry learning on the server on the first sub-link to know that the first sub-link is recovered from the disconnection to the complete link.
For the second sublink, a restoration connection sharing the management port means that the second sublink no longer exists as a separate sublink. Therefore, the server on the second sublink may perform corresponding processing, so that the forwarding device deletes the ARP entry learning performed on the server on the second sublink before, and further makes the second sublink not perform message forwarding separately.
In the following, with reference to fig. 4 and 5, when the link at a shared management port in the link is restored from disconnection to connection, how to perform the relevant processing on the server on the second sublink connected to the second port of the forwarding device is described in detail, and how to delete the learned ARP entry of the server on the second sublink by the forwarding device is also described in detail.
As one way of restoring the link at the shared management port of the server from disconnection to connection, the server can detect that the link at the own shared management port is restored from disconnection to connection, that is, that the state of the own shared management port is restored from Down to Up. In this case, the server can regenerate a special ARP request according to preset rules.
Alternatively, the special ARP request generated by the server may be a third ARP request, the source address in the third ARP request may be the MAC address of the management port of the server, and the destination address in the third ARP request is a special second broadcast address, for example 127.0.0.2. And the server may also generate a fourth ARP request whose source address may be the MAC address of the server's management port and whose destination address is a regular broadcast address.
In addition, while generating the third ARP request, the server returns from disconnection to connection based on detecting that the link at the shared management port of the server is connected, and then the server may further adjust the processing rule of the message again, that is, "whether the dedicated management port of the server is connected to the forwarding device or not, the message may be received and sent through the dedicated management port of the server" to return to the original: "if the dedicated management port of the server is determined not to be connected to the forwarding device, the message to be forwarded from the dedicated management port of the server is forwarded from the dedicated management port of the server, and if the dedicated management port of the server is determined to be connected to the forwarding device, the message to be forwarded from the dedicated management port of the server can be discarded".
After the server generates the third ARP request, the server sends the third ARP request to the next device adjacent to the server through the dedicated management port of the server. And the server may further generate a fourth ARP request that includes the MAC address of the management port of the server and has a destination address that is a regular broadcast address, and the shared management port of the server may further send the generated fourth ARP request to the previous device adjacent to the first sublink.
For the third ARP request, if the server determines that the device connected to the dedicated management port of the server is a forwarding device, that is, the next device in the neighborhood is a forwarding device, the server may discard the third ARP request and does not forward the third ARP request.
Also for the third ARP request, if the server determines that the server connected to the dedicated management port of the server is the server, that is, the next device adjacent to the server is the server, the server may send the third ARP request to the next server adjacent to the server through the dedicated management port, so that the next server adjacent to the server may generate a fourth ARP request including its own MAC address based on the third ARP request, and determine whether to forward the third ARP request downward based on determining whether to connect a forwarding device downward. In this way, the server can obtain the fourth ARP request generated and sent by the next adjacent server, and then the server can forward the fourth ARP request generated by itself and the fourth ARP request sent by the next adjacent server to the previous adjacent device through the shared management port.
So that each server on the second sub-link, except that server, can perform the same operations as the next server in the neighborhood. Then, the shared management port of each server on the second sub-link except the server may obtain the third ARP request, and the dedicated management port of each server may forward the third ARP request to the next adjacent server, or each server may discard the third ARP request and does not forward the third ARP request based on the connection between the dedicated management port of each server and the forwarding device, so that the forwarding of each server in sequence enables each server to obtain the third ARP request. Meanwhile, each server obtaining the third ARP request also adjusts the processing rule of the message to be the same as the processing rule of the server that the shared management port is disconnected from based on the third ARP request.
In addition, each server on the second sub-link other than the server is based on performing the same operation as the next server in the neighborhood. Each server on the second sub-link except the server may generate each fourth ARP request including the MAC address of the management port of each server and having a destination address of a regular broadcast address based on the obtained third ARP request, and the shared management port of each server may further send each generated fourth ARP request to the dedicated management port of the previous server. In this way, the dedicated management port of each server on the link obtains the fourth ARP request sent by each other server, and then forwards the fourth ARP request sent by each other server through the shared management port of each server, so that each server in the link obtains the fourth ARP request and forwards the fourth ARP request from the shared management port of each server, and thus the first port of the forwarding device obtains the fourth ARP request generated by each server.
In this way, the first port of the forwarding device may obtain the MAC address of the management port of each server in the second sublink according to the fourth ARP request generated by each server, and then the forwarding device may perform ARP table entry learning based on the MAC address of the management port of each server in the second sublink, so as to learn the MAC address of the management port of each server to the first port, so that the forwarding device may not send a message to the dedicated management port of the server at the second end of the link through the second port any longer, but may continue to forward the message to the server in the link through the first port.
Continuing with the previous assumption, if the server C recovers from the disconnection to the connection at the shared management port C1, the first sublink and the second sublink are merged into a complete link again.
For the second sublink, server C may send the generated third ARP request to server D through server C's dedicated management port C2, and server C may send the generated fourth ARP request to server B through server C's shared management port C1. The sharing management port D1 of server D may obtain the third ARP request, and server D may generate a fourth ARP request based on the third ARP request. The dedicated management port D2 of the server D is connected to the port E2 of the switch E, so the server D can discard the generation of the fourth ARP request, and also send the shared management port D1 of the fourth ARP request server D to the server C. In this way, the fourth ARP request of server D is forwarded to the dedicated management port B2 of server B through the shared management port C1 of server C, and the fourth ARP request of server D and the fourth ARP request of server C are forwarded to the dedicated management port a2 of server a through the shared management port B1 of server B, then the fourth ARP request of server D and the fourth ARP request of server C are forwarded to the port E1 of switch E through the shared management port a1 of server a. The switch E may learn the ARP entry according to the fourth ARP request of the server D and the fourth ARP request of the server C, and then the switch E learns the MAC address of the server D and the MAC address of the server C to the port E1, so that the message to be forwarded may be sent to the link through the port E1.
As a way of restoring the link at the shared management port of the other server before the server from disconnection to connection, the other server can generate and transmit a third ARP request containing the MAC address of the management port of the other server, and adjust the processing rule of the other server for the message. Accordingly, the shared management port of the server located on the second sublink may obtain the third ARP request through forwarding of the third ARP request by each server before the server, or obtain the third ARP request sent by the shared management port from another server that is disconnected from the shared management port through dedicated management connection between the shared management port of the server and another server that is disconnected from the shared management port.
The server can know that the shared management port of the other server is restored to connection from disconnection based on the special second broadcast address in the third ARP request, and can also know that the processing rule of the message needs to be adjusted. Therefore, the server can also restore the original state of the message received and sent by the special management port of the server no matter whether the special management port of the server is connected with the forwarding equipment or not: "if the dedicated management port of the server is determined not to be connected to the forwarding device, the message to be forwarded from the dedicated management port of the server is forwarded from the dedicated management port of the server, and if the dedicated management port of the server is determined to be connected to the forwarding device, the message to be forwarded from the dedicated management port of the server can be discarded".
Furthermore, the server can also obtain a fourth ARP request which needs to generate the MAC address of the server based on the third ARP request, so the server can replace the MAC address of the management port of the server with the MAC address of the management port of the other server in the third ARP request to obtain the fourth ARP request, and thus the server can send the fourth ARP request to the previous adjacent device through the shared management port of the server.
If the server determines that the device connected to the dedicated management port of the server is a forwarding device, that is, the next device adjacent to the dedicated management port is a forwarding device, the server may discard the third ARP request and does not forward the third ARP request.
If the server determines that the server connected to the dedicated management port of the server is the server, that is, the next device in the neighborhood is the server, the server may send the third ARP request to the next server in the neighborhood through the dedicated management port.
Third embodiment
Referring to fig. 6, an embodiment of the present application provides a message forwarding apparatus 100, where the message forwarding apparatus 100 may be applied to any one of a plurality of servers, and the message forwarding apparatus 100 includes:
a first message obtaining module 110, configured to obtain, by the server through the shared management port, a message to be forwarded, where the message is sent by the previous adjacent device.
A first packet forwarding module 120, configured to forward, by the server, the packet to be forwarded to the next adjacent device through the dedicated management port.
Optionally, the message forwarding apparatus 100 further includes:
a first message generating module 130, configured to generate, by the server, a first ARP request including an MAC address of the server if the link at the shared management port is disconnected.
A first message sending module 140, configured to send the first ARP request to the next adjacent device through the dedicated management port by the server, so that when the next adjacent device is a forwarding device, the forwarding device determines to send a message to the shared management port based on the obtained first ARP request; and when the next adjacent device is a server, the next adjacent device generates a second ARP request containing the MAC address of the next adjacent device based on the first ARP request, and forwards the first ARP request and the second ARP request downwards.
Optionally, the message forwarding apparatus 100 further includes:
a second message generating module 150, configured to generate a third ARP request and a fourth ARP request that include the MAC address of the server if the link at the shared management port is restored from disconnection to connection.
A second message sending module 160, configured to, when the next adjacent device is a forwarding device, discard the third ARP request by the server; and sending the fourth ARP request to the adjacent previous equipment through the shared management port.
The second packet sending module 160 is further configured to, when the next adjacent device is a server, send the third ARP request to the next adjacent server through the dedicated management port, so that the next adjacent server generates a fourth ARP request including its MAC address based on the third ARP request and forwards the third ARP request downward; the server also forwards the fourth ARP request generated by the server and a fourth ARP request sent by the next adjacent server to the previous adjacent device through the shared management port.
Optionally, the message forwarding apparatus 100 further includes:
a second message obtaining module 101, configured to, if a link at a shared management port of another server is disconnected, obtain, by the server through the shared management port, a first ARP request that includes an MAC address of the other server and is generated by the other server.
A third packet generating module 102, configured to generate, by the server, a second ARP request including a MAC address of the server based on the first ARP request.
A third packet sending module 103, configured to send, by the server, the first ARP request and the second ARP request to the next neighboring device through the dedicated management port, so that when the next neighboring device is a forwarding device, the forwarding device determines to send a packet to the shared management port based on the obtained first ARP request and the obtained second ARP request; and when the next adjacent equipment is a server, forwarding the first ARP request downwards by the next adjacent equipment.
A second message forwarding module 104, configured to forward, by the server, the message to be forwarded, received from the dedicated management port, from the shared management port to an adjacent previous device.
Optionally, the message forwarding apparatus 100 further includes:
a third packet obtaining module 105, configured to, when the link at the shared management port of the other server is restored from disconnection to connection, obtain, by the server, a third ARP request that includes the MAC address of the other server.
A fourth packet generating module 106, configured to generate, by the server, a fourth ARP request including the MAC address of the server based on the third ARP request, and send the fourth ARP request to the previous adjacent device through the shared management port.
A fourth message sending module 107, configured to discard the third ARP request by the server when the next device is a forwarding device.
The fourth packet sending module 107 is further configured to, when the next device is a server, forward the third ARP request to an adjacent next device through the dedicated management port by the server, so that the next device downloads the third ARP request.
It should be noted that, as those skilled in the art can clearly understand, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, embodiments of the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, embodiments of the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
In summary, the embodiments of the present application provide a message forwarding method, device, server, system, and storage medium. The method is applied to the server in the message forwarding system comprising a plurality of servers, the shared management port of the server is connected with the adjacent previous device, the special management port of the server is connected with the adjacent next device, and the method comprises the following steps: the server obtains a message to be forwarded sent by the adjacent previous device through the shared management port; the server forwards the message to be forwarded to the next adjacent device through the special management port.
The shared management port based on the server is connected with the adjacent previous device, the message to be forwarded sent by the adjacent previous device is obtained through the shared management port, and the message to be forwarded is forwarded to the adjacent next device through the dedicated management port based on the connection of the dedicated management port of the server and the adjacent next device, so that the normal forwarding of the message is realized. Meanwhile, because the shared management port and the dedicated management port of the server are respectively connected with different devices, the ports required by the connection devices of the forwarding devices in the message forwarding system can be saved, and the technical problem that the BMC needs to occupy a large amount of port resources of the forwarding devices when managing the server is solved.
The above description is only a preferred embodiment of the present application and is not intended to limit the present application, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, improvement and the like made within the spirit and principle of the present application shall be included in the protection scope of the present application. It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.
The above description is only for the specific embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present application, and shall be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (15)

1. A message forwarding method is applied to a server in a message forwarding system comprising a plurality of servers, wherein a shared management port of the server is connected with an adjacent previous device, and a dedicated management port of the server is connected with an adjacent next device, and the method comprises the following steps:
the server obtains the message to be forwarded sent by the adjacent previous device through the shared management port;
and the server forwards the message to be forwarded to the next adjacent device through the special management port.
2. The packet forwarding method according to claim 1, wherein the method further comprises:
if the link at the shared management port is disconnected, the server generates a first ARP request containing the MAC address of the server;
the server sends the first ARP request to the next adjacent equipment through the special management port, so that when the next adjacent equipment is forwarding equipment, the forwarding equipment determines to send a message to the shared management port based on the obtained first ARP request; and when the next adjacent device is a server, the next adjacent device generates a second ARP request containing the MAC address of the next adjacent device based on the first ARP request, and forwards the first ARP request and the second ARP request downwards.
3. The packet forwarding method according to claim 1, wherein the method further comprises:
if the link at the shared management port is recovered to be connected from disconnection, the server generates a third ARP request and a fourth ARP request containing the MAC address of the server;
when the next adjacent device is a forwarding device, the server discards the third ARP request; sending the fourth ARP request to the adjacent previous equipment through the shared management port;
when the next adjacent device is a server, the server sends the third ARP request to the next adjacent server through the special management port, so that the next adjacent server generates a fourth ARP request containing the MAC address of the next adjacent server based on the third ARP request and forwards the third ARP request downwards; the server also forwards the fourth ARP request generated by the server and a fourth ARP request sent by the next adjacent server to the previous adjacent device through the shared management port.
4. The packet forwarding method according to claim 1, wherein the method further comprises:
if the link at the shared management port of other servers is disconnected, the server obtains a first ARP request which is generated by the other servers and contains the MAC addresses of the other servers through the shared management port;
the server generates a second ARP request containing the MAC address of the server based on the first ARP request;
the server sends the first ARP request and the second ARP request to the next adjacent equipment through the special management port, so that when the next adjacent equipment is forwarding equipment, the forwarding equipment determines to send a message to the shared management port based on the obtained first ARP request and the obtained second ARP request; and when the next adjacent equipment is a server, forwarding the first ARP request downwards by the next adjacent equipment.
5. The packet forwarding method according to claim 4, wherein after the server sends the first ARP request and the second ARP request to the next device adjacent to the server through the dedicated management port, the method further comprises:
and the server forwards the message to be forwarded received from the special management port to the adjacent previous device from the shared management port.
6. The packet forwarding method according to claim 4, wherein the method further comprises:
when the link at the shared management port of the other server is restored from disconnection to connection, the server obtains a third ARP request containing the MAC address of the other server;
the server generates a fourth ARP request containing the MAC address of the server based on the third ARP request, and sends the fourth ARP request to the adjacent previous equipment through the shared management port;
when the next device is a forwarding device, the server discards the third ARP request;
and when the next device is a server, the server forwards the third ARP request to the next adjacent device through the special management port, so that the next device sends the third ARP request down.
7. A message forwarding apparatus, applied to a server in a message forwarding system including a plurality of servers, wherein a shared management port of the server is connected to an adjacent previous device, and a dedicated management port of the server is connected to an adjacent next device, the apparatus comprising:
a first message obtaining module, configured to obtain, by the server through the shared management port, a message to be forwarded, where the message is sent by the previous adjacent device;
and the first message forwarding module is used for the server to forward the message to be forwarded to the next adjacent device through the special management port.
8. The message forwarding device of claim 7, wherein the device further comprises:
the first message generation module is used for generating a first ARP request containing the MAC address of the server if the link at the shared management port is disconnected;
a first message sending module, configured to send the first ARP request to the next adjacent device through the dedicated management port by the server, so that when the next adjacent device is a forwarding device, the forwarding device determines to send a message to the shared management port based on the obtained first ARP request; and when the next adjacent device is a server, the next adjacent device generates a second ARP request containing the MAC address of the next adjacent device based on the first ARP request, and forwards the first ARP request and the second ARP request downwards.
9. The message forwarding device of claim 7, wherein the device further comprises:
the second message generation module is used for generating a third ARP request and a fourth ARP request which contain the MAC addresses of the servers if the links at the shared management ports are recovered to be connected from disconnection;
a second message sending module, configured to discard the third ARP request by the server when the next adjacent device is a forwarding device; sending the fourth ARP request to the adjacent previous equipment through the shared management port;
the second message sending module is further configured to, when the next adjacent device is a server, send the third ARP request to the next adjacent server through the dedicated management port, so that the next adjacent server generates a fourth ARP request including its MAC address based on the third ARP request and forwards the third ARP request downward; the server also forwards the fourth ARP request generated by the server and a fourth ARP request sent by the next adjacent server to the previous adjacent device through the shared management port.
10. The message forwarding device of claim 7, wherein the device further comprises:
the second message obtaining module is used for obtaining a first ARP request which is generated by other servers and contains the MAC addresses of other servers through the shared management port if the link at the shared management port of other servers is disconnected;
a third message generation module, configured to generate, by the server, a second ARP request including an MAC address of the server based on the first ARP request;
a third message sending module, configured to send, by the server, the first ARP request and the second ARP request to the next neighboring device through the dedicated management port, so that when the next neighboring device is a forwarding device, the forwarding device determines to send a message to the shared management port based on the obtained first ARP request and the obtained second ARP request; and when the next adjacent equipment is a server, forwarding the first ARP request downwards by the next adjacent equipment.
11. The message forwarding device of claim 10, wherein the device further comprises:
and the second message forwarding module is used for the server to forward the message to be forwarded, which is received from the dedicated management port, to the adjacent previous device from the shared management port.
12. The message forwarding device of claim 10, wherein the device further comprises:
a third message obtaining module, configured to, when a link at a shared management port of the other server is restored from disconnection to connection, obtain, by the server, a third ARP request that includes an MAC address of the other server;
a fourth message generation module, configured to generate, by the server, a fourth ARP request including an MAC address of the server based on the third ARP request, and send the fourth ARP request to an adjacent previous device through the shared management port;
a fourth message sending module, configured to discard the third ARP request by the server when the next device is a forwarding device;
and the fourth message sending module is further configured to, when the next device is a server, forward the third ARP request to an adjacent next device through the dedicated management port by the server, so that the next device downloads the third ARP request.
13. A server, characterized in that the server comprises: a host, a network card and a BMC; the network card is respectively connected with the host and the BMC, a shared management port of the server is arranged on the network card, and a special management port of the server is arranged on the BMC;
the BMC is configured to monitor a shared management port of the server and a dedicated management port of the server to perform the message forwarding method according to any one of claims 1 to 6.
14. A message forwarding system, the message forwarding system comprising: the server comprises a plurality of servers and forwarding equipment, wherein a dedicated management port of each server in the plurality of servers is connected with a shared management port of the next adjacent server to form a link, and the shared management port of the server at the first end of the link and the dedicated management port of the server at the second end of the link are both connected with the forwarding equipment;
any one of the plurality of servers configured to execute the message forwarding method according to any one of claims 1 to 6.
15. A computer-readable storage medium having computer-executable non-volatile program code, the program code causing the computer to perform the message forwarding method according to any one of claims 1 to 6.
CN201811292902.1A 2018-10-31 2018-10-31 Message forwarding method, device, server, system and storage medium Active CN109361781B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811292902.1A CN109361781B (en) 2018-10-31 2018-10-31 Message forwarding method, device, server, system and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811292902.1A CN109361781B (en) 2018-10-31 2018-10-31 Message forwarding method, device, server, system and storage medium

Publications (2)

Publication Number Publication Date
CN109361781A CN109361781A (en) 2019-02-19
CN109361781B true CN109361781B (en) 2021-07-06

Family

ID=65343616

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811292902.1A Active CN109361781B (en) 2018-10-31 2018-10-31 Message forwarding method, device, server, system and storage medium

Country Status (1)

Country Link
CN (1) CN109361781B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114244787B (en) * 2021-12-08 2023-04-11 四川安迪科技实业有限公司 Method and device for realizing high-reliability management port

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101227355A (en) * 2006-08-16 2008-07-23 环达电脑(上海)有限公司 Clustering system and system management architecture thereof
CN105897623A (en) * 2016-03-25 2016-08-24 杭州昆海信息技术有限公司 Data transmission method and apparatus
CN108259226A (en) * 2016-12-28 2018-07-06 迈络思科技有限公司 Security configuration and platform management are carried out using network is managed
CN108521341A (en) * 2018-03-23 2018-09-11 紫光华山信息技术有限公司 Message transmitting method and device

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060280195A1 (en) * 2005-06-10 2006-12-14 Dell Products L.P. Systems and methods for providing dedicated or shared network interface functionality via a single MAC
JP4659062B2 (en) * 2008-04-23 2011-03-30 株式会社日立製作所 Failover method, program, management server, and failover system
US10884759B2 (en) * 2018-10-30 2021-01-05 Hewlett Packard Enterprise Development Lp Remote deployment of operating systems

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101227355A (en) * 2006-08-16 2008-07-23 环达电脑(上海)有限公司 Clustering system and system management architecture thereof
CN105897623A (en) * 2016-03-25 2016-08-24 杭州昆海信息技术有限公司 Data transmission method and apparatus
CN108259226A (en) * 2016-12-28 2018-07-06 迈络思科技有限公司 Security configuration and platform management are carried out using network is managed
CN108521341A (en) * 2018-03-23 2018-09-11 紫光华山信息技术有限公司 Message transmitting method and device

Also Published As

Publication number Publication date
CN109361781A (en) 2019-02-19

Similar Documents

Publication Publication Date Title
US11323307B2 (en) Method and system of a dynamic high-availability mode based on current wide area network connectivity
US9608841B2 (en) Method for real-time synchronization of ARP record in RSMLT cluster
US7929420B2 (en) Method and apparatus for learning VRRP backup routers
US9219641B2 (en) Performing failover in a redundancy group
US10560550B1 (en) Automatic configuration of a replacement network device in a high-availability cluster
CN112565046B (en) Synchronizing multicast router capabilities
US10470111B1 (en) Protocol to detect if uplink is connected to 802.1D noncompliant device
US10862735B2 (en) Method and apparatus for implementing operation, administration, and maintenance function
CN108199962B (en) Address migration method and device, network equipment and readable storage medium
CN105656645A (en) Decision making method and device for fault processing of stacking system
US10581669B2 (en) Restoring control-plane connectivity with a network management entity
CN110011941B (en) Message forwarding method and device
WO2017008641A1 (en) Method of switching redundancy port and device utilizing same
EP3029883A1 (en) Network protection method and apparatus, next-ring node, and system
WO2020173424A1 (en) Message processing method, and gateway device
US9065678B2 (en) System and method for pinning virtual machine adapters to physical adapters in a network environment
WO2016124117A1 (en) Method, switching device and network controller for protecting links in software-defined network (sdn)
US9372708B2 (en) Synchronizing multicast groups
CN110380966B (en) Method for discovering forwarding path and related equipment thereof
US10680930B2 (en) Method and apparatus for communication in virtual network
CN110661705A (en) Hardware network switching engine and network fault processing system and method
US9893979B2 (en) Network topology discovery by resolving loops
CN109361781B (en) Message forwarding method, device, server, system and storage medium
CN102064956B (en) Method for regulating aging time, system and modulator-demodulator
CN113839862A (en) Method, system, terminal and storage medium for synchronizing ARP information between MCLAG neighbors

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
CB02 Change of applicant information
CB02 Change of applicant information

Address after: 310000 11/F, 466 Changhe Road, Binjiang District, Hangzhou City, Zhejiang Province

Applicant after: Xinhua Sanxin Information Technology Co., Ltd.

Address before: 310000 11/F, 466 Changhe Road, Binjiang District, Hangzhou City, Zhejiang Province

Applicant before: Huashan Information Technology Co., Ltd.

GR01 Patent grant
GR01 Patent grant