CN113794639B - Communication method and device - Google Patents

Communication method and device Download PDF

Info

Publication number
CN113794639B
CN113794639B CN202110984699.XA CN202110984699A CN113794639B CN 113794639 B CN113794639 B CN 113794639B CN 202110984699 A CN202110984699 A CN 202110984699A CN 113794639 B CN113794639 B CN 113794639B
Authority
CN
China
Prior art keywords
service
board
boards
capacity
opposite
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
CN202110984699.XA
Other languages
Chinese (zh)
Other versions
CN113794639A (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 Security Technologies Co Ltd
Original Assignee
New H3C Security 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 Security Technologies Co Ltd filed Critical New H3C Security Technologies Co Ltd
Priority to CN202110984699.XA priority Critical patent/CN113794639B/en
Publication of CN113794639A publication Critical patent/CN113794639A/en
Application granted granted Critical
Publication of CN113794639B publication Critical patent/CN113794639B/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
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/14Routing performance; Theoretical aspects
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The application provides a communication method and a communication device, wherein the method is applied to any service board in routing equipment and comprises the following steps: when receiving a first LLDP message of a single board type carrying an opposite terminal service board sent by any opposite terminal service board directly connected with the service board, determining the service capacity corresponding to the single board type according to the corresponding relation between the locally stored single board type and the service capacity; and determining the minimum service capacity of the service capacities corresponding to the single board types of the service boards and the determined service capacities corresponding to the single board types of all opposite-end service boards as the service capacity which is finally used by the service boards, and sending a second LLDP message carrying the service capacity which is finally used by the service boards to all the opposite-end service boards so that all the opposite-end service boards can carry out service communication with the service boards based on the service capacity which is finally used by the service boards. The method and the device can improve the communication quality between the directly connected service boards in different routing devices.

Description

Communication method and device
Technical Field
The present disclosure relates to the field of communications technologies, and in particular, to a communications method and apparatus.
Background
The single boards of the service boards in the routing equipment manufactured by the same routing equipment manufacturer or different routing equipment manufacturers may have different types, and the service capacities (for example, table entry capacities and the like) corresponding to the single boards may also be different, so that when service communication is performed between directly connected service boards in different routing equipment, the problem that part of the service cannot be processed due to inconsistent service capacities of related services easily occurs, and the communication quality is poor.
Disclosure of Invention
In order to overcome the problems in the related art, the present application provides a communication method and apparatus.
According to a first aspect of embodiments of the present application, there is provided a communication method, the method being applied to any service board in a routing device, the method comprising:
when receiving a first link layer discovery protocol (Link Layer Discovery Protocol, LLDP) message of a single board type carrying an opposite terminal service board sent by any opposite terminal service board directly connected with the service board, determining the service capacity corresponding to the single board type according to the corresponding relation between the locally stored single board type and the service capacity, wherein the service board and the opposite terminal service board are different in routing equipment;
and determining the minimum service capacity of the service capacities corresponding to the single board types of the service boards and the determined service capacities corresponding to the single board types of all opposite-end service boards as the service capacity which is finally used by the service boards, and sending a second LLDP message carrying the service capacity which is finally used by the service boards to all the opposite-end service boards so that all the opposite-end service boards can carry out service communication with the service boards based on the service capacity which is finally used by the service boards.
According to a second aspect of embodiments of the present application, there is provided a communication apparatus, the apparatus being applied to any service board in a routing device, the apparatus comprising:
a first determining module, configured to determine, when receiving a first LLDP packet carrying a board type of an opposite-end service board sent by any opposite-end service board directly connected to the service board, a service capacity corresponding to the board type according to a correspondence between a locally stored board type and a service capacity, where the service board and a routing device to which the opposite-end service board belongs are different;
and the second determining module is used for determining the minimum service capacity of the service capacities corresponding to the single board types of the service boards and the determined service capacities corresponding to the single board types of all opposite-end service boards as the service capacity finally used by the service boards, and sending a second LLDP message carrying the service capacity finally used by the service boards to all the opposite-end service boards so that all the opposite-end service boards can carry out service communication with the service boards based on the service capacity finally used by the service boards.
The technical scheme provided by the embodiment of the application can comprise the following beneficial effects:
in this embodiment of the present application, for any service board in the routing device, before performing service communication with the directly connected opposite service board (different from the routing device to which the service board belongs), the service capacity that is ultimately used by the service board is determined through an LLDP packet carrying a single board type from the opposite service board, where the service capacity is supported by the opposite service board; and then, sending an LLDP message carrying the service capacity finally used by the service board to the opposite-end service board so that the opposite-end service board can know the service capacity finally used by the service capacity and communicate with the service board based on the service capacity.
Therefore, under the condition that the service capacity between the service board and the opposite-end service board directly connected with the service board is inconsistent, the service board can enable the opposite-end service board to know the service capacity used when the opposite-end service board performs service communication by executing the communication flow, so that the opposite-end service board can perform service communication with the service board based on the service capacity, the problem that part of service cannot be processed is avoided, and the communication quality is improved.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the application.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the application and together with the description, serve to explain the principles of the application.
Fig. 1 is a schematic flow chart of a communication method according to an embodiment of the present application;
fig. 2 is a schematic structural diagram of a communication network according to an embodiment of the present application;
fig. 3 is a schematic structural diagram of a communication device according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
Reference will now be made in detail to exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. The implementations described in the following exemplary examples are not representative of all implementations consistent with the present application. Rather, they are merely examples of apparatus and methods consistent with some aspects of the present application as detailed in the accompanying claims.
The terminology used in the present application is for the purpose of describing particular embodiments only and is not intended to be limiting of the present application. As used in this application and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used herein refers to and encompasses any or all possible combinations of one or more of the associated listed items.
It should be understood that although the terms first, second, third, etc. may be used herein to describe various information, these information should not be limited by these terms. These terms are only used to distinguish one type of information from another. For example, a first message may also be referred to as a second message, and similarly, a second message may also be referred to as a first message, without departing from the scope of the present application. The word "if" as used herein may be interpreted as "at … …" or "at … …" or "responsive to a determination", depending on the context.
Next, embodiments of the present application will be described in detail.
The embodiment of the application provides a communication method, which is applied to any service board in a routing device, as shown in fig. 1, and the method can include the following steps:
s11, when receiving a first LLDP message carrying the single board type of the opposite terminal service board sent by any opposite terminal service board directly connected with the service board, determining the service capacity corresponding to the single board type according to the corresponding relation between the locally stored single board type and the service capacity.
In this step, the service board and the opposite service board belong to different routing devices.
In addition, the first LLDP message in this step is mainly used for informing the board type of the service board.
S12, determining the minimum service capacity of the service capacities corresponding to the single board types of the service boards and the determined service capacities corresponding to the single board types of all opposite-end service boards as the service capacity which is finally used by the service boards, and sending a second LLDP message carrying the service capacity which is finally used by the service boards to all opposite-end service boards so that all opposite-end service boards can carry out service communication with the service boards based on the service capacity which is finally used by the service boards.
In this step, the second LLDP message is mainly used to inform the service board of the service capacity that is ultimately used.
It should be noted that, in this embodiment of the present application, after the routing device to which the service board belongs is powered on, the service board sends, to the corresponding opposite service board, a first LLDP message carrying a board type of the service board through each interface directly connected to the opposite service board on the service board.
Correspondingly, the service board also receives, through the interfaces, a first LLDP message carrying a board type of the corresponding opposite-end service board sent by the corresponding opposite-end service board. Then, for the first LLDP message carrying the board type of the opposite-end service board and received by any interface of the interfaces, the service board can find the service capacity corresponding to the board type from the corresponding relations previously stored on the service board side, so that the service board gathers the service capacities corresponding to the board types of all the opposite-end service boards directly connected to itself, and determines the service capacity used by the service board when performing service communication (i.e., the service capacity finally used by the service board) in combination with the service capacity corresponding to the board type of itself, and notifies all the opposite-end service boards, so that the opposite-end service boards can communicate with the service board based on the service capacity finally used by the service board, thereby avoiding the problem that part of services cannot be processed and improving the communication quality.
In one example, in order to collect service capacities corresponding to the single board types of all the opposite-end service boards conveniently, the service boards may maintain an opposite-end service board information table, where the opposite-end service board information table may include information such as an interface identifier of an interface of the opposite-end service board directly connected to the service board, the single board type of the opposite-end service board, and the service capacity corresponding to the single board type of the opposite-end service board.
For example, the content of the opposite-end service board information table may be empty at the beginning, and once the service board receives, through a certain interface, a first LLDP message carrying a board type of the opposite-end service board sent by the opposite-end service board corresponding to the interface, the service board may search the service capacity corresponding to the board type from the corresponding relationship, and add the interface identifier of the interface, the board type of the opposite-end service board, and the service capacity corresponding to the searched board type to the opposite-end service board information table.
It should be further noted that, in this embodiment of the present application, it is also possible for the service board to maintain a service capacity table according to a board number of the service board, and initially, the service capacity table is empty, once the service capacity of the service board for final use is determined, the service capacity of the service board for final use is added to the service capacity table, and then the service board performs service communication with the corresponding peer service boards (i.e., all peer service boards directly connected to the service board) based on the service capacity of the service board for final use.
In addition, in order to improve the communication quality, after determining the service capacity of the service board for final use, the service board also sends a second LLDP message carrying the service capacity of the service board for final use to the corresponding opposite-end service board, and the corresponding opposite-end service board records the service capacity of the service board for final use and performs service communication with the service board based on the service capacity of the service board for final use.
In one example, in order to ensure the security of transmitting the service capacity that is ultimately used by the service board, before sending the second LLDP message carrying the service capacity that is ultimately used by the service board to the corresponding opposite service board, the service board may encrypt the service capacity that is ultimately used by the service board according to a preset encryption algorithm; and then sending a second LLDP message carrying the service capacity finally used by the service board to the corresponding opposite-end service board. In this context,
here, the preset encryption Algorithm may be various encryption algorithms commonly used in the prior art, for example, a Message-Digest-algorism (MD 5) Algorithm, etc.
Further, in the embodiment of the present application, with the change of the deployment requirement of the network where the routing device to which the service board belongs is located, the peer service board directly connected to the service board may also change, which may increase the peer service board newly, or may reduce the peer service board.
Then, for the case where the peer service board is reduced, the service board may further perform the following operations:
when the connection relation between the service board and any opposite-end service board is monitored to be disconnected, if the minimum service capacity in the service capacities corresponding to the single board types of the rest opposite-end service boards is not smaller than the service capacity finally used by the service boards, maintaining the service capacity finally used by the service boards unchanged;
if the minimum service capacity in the service capacities corresponding to the single board types of the remaining opposite-end service boards is smaller than the service capacity finally used by the service boards, the service capacity finally used by the service boards is changed into the minimum service capacity in the service capacities corresponding to the single board types of the service boards and the service capacities corresponding to the single board types of the remaining opposite-end service boards, and a second LLDP message carrying the changed service capacities is sent to the remaining opposite-end service boards, so that all the opposite-end service boards carry out service communication with the service boards based on the changed service capacities.
It should be noted that, for the service board, when the service board is monitored to be disconnected from any peer service board, relevant data about the peer service board in the peer service board information table is deleted.
For the situation that the opposite terminal service board is newly added, the service board can also execute the following operations:
when a first LLDP message carrying the single board type of the new opposite terminal service board is received, which is sent by the new opposite terminal service board directly connected with the service board, determining the service capacity corresponding to the single board type of the new opposite terminal service board according to the corresponding relation;
if the minimum service capacity in the service capacities corresponding to the single board types of all the current opposite-end service boards is not less than the service capacity finally used by the service boards, maintaining the service capacity finally used by the service boards unchanged;
if the minimum service capacity in the service capacities corresponding to the single board types of all the current opposite-end service boards is smaller than the service capacity finally used by the service boards, the service capacity finally used by the service boards is changed into the minimum service capacity in the service capacities corresponding to the single board types of the service boards and the service capacities corresponding to the single board types of all the current opposite-end service boards, and a second LLDP message carrying the changed service capacities is sent to all the current opposite-end service boards, so that all the current opposite-end service boards carry out service communication with the service boards based on the changed service capacities.
It should be noted that, for the service board, when receiving the first LLDP packet carrying the board type of the new opposite-end service board sent by the new opposite-end service board directly connected to the service board, the service capacity corresponding to the board type of the new opposite-end service board may be specifically searched from the correspondence, and the interface identifier of the corresponding interface, the board type of the new opposite-end service board, and the service capacity corresponding to the searched board type of the new opposite-end service board may be added to the opposite-end service board information table.
The above communication method is described in detail with reference to specific embodiments.
As shown in fig. 2, it is assumed that a service board A1, a service board A2, and a service board A3 are provided in a routing device 1 in a communication network; the routing equipment 2 is provided with a service board B1, a service board B2 and a service board B3; the routing device 3 is provided with a service board C1, a service board C2, and a service board C3. Wherein, the service board B1 is directly connected with the service board A1 through the interface 21, and is directly connected with the service board C1 through the interface 22; the service board B2 is directly connected with the service board A2 through an interface 23 and is directly connected with the service board C2 through an interface 24; the service board B3 is directly connected to the service board A3 through the interface 25, and is directly connected to the service board C3 through the interface 26. Of course, other routing devices and other network devices, which are not shown in fig. 2, are also included in the communication network, and will not be described in detail herein.
After the routing device 1, the routing device 2 and the routing device 3 are powered on, each service board in the three routing devices can send an LLDP message carrying respective single board types to the opposite service boards directly connected with the service boards.
Taking the service board B1 as an example, the service board B1 sends a first LLDP message of a board type carrying the service board B1 to the service board A1 through the interface 21, and sends a first LLDP message of a board type carrying the service board B1 to the service board C1 through the interface 22.
Accordingly, the service board B1 also receives the first LLDP message of the board type carrying the service board A1 sent by the service board A1 through the interface 21, and receives the LLDP message of the board type carrying the service board C1 sent by the service board C1 through the interface 22.
Then, for the first LLDP message carrying the board type of the service board A1, the service board B1 searches the service capacity corresponding to the board type of the service board a from the corresponding relationship between the locally stored board type and the service capacity; then, the service board may add the interface identifier (for example, port_ba1) of the interface 21, the board type (for example, a 11) of the service board A1, and the service capacity (for example, a 111) corresponding to the board type of the service board A1 to the initially empty opposite service board information table, where the added opposite service board information table is shown in the following table one.
Interface identification Veneer type Service capacity
Port_ba1 A11 A111
List one
Aiming at a first LLDP message carrying the single board type of the service board C1, the service board B1 searches the service capacity corresponding to the single board type of the service board C1 from the corresponding relation between the locally stored single board type and the service capacity; then, the service board may add the interface identifier (for example, port_bc1) of the interface 22, the board type (for example, C11) of the service board C1, and the service capacity (for example, C111) corresponding to the board type of the service board C1 to the opposite service board information table, where the added opposite service board information table is shown in the following table two.
Interface identification Veneer type Service capacity
Port_ba1 A11 A111
Port_bc1 C11 C111
Watch II
Thereafter, the service board B1 determines the minimum service capacity among the service capacity (e.g., B111) corresponding to the own board type, the service capacity (i.e., a 111) corresponding to the board type of the service board a, and the service capacity (i.e., C111) corresponding to the board type of the service board C as the service capacity finally used by the service board B1. For example, assuming that the smallest traffic capacity among the three is a111, the traffic board B1 determines a111 as the traffic capacity that the traffic board B1 finally uses, and adds the board numbers (e.g., 101) and a111 of the traffic board B1 to the traffic capacity table that is initially empty, and the added traffic capacity table is shown in the following table three, and the subsequent traffic board B1 performs traffic communication with the traffic board A1 and the traffic board C1 based on a111, respectively.
Plate number of service plate Service capacity for end use of service board
101 A111
Watch III
Meanwhile, the service board B1 also sends a second LLDP message carrying the service capacity finally used by the service board B1 to the service board A1 through the interface 21, so that the service board A1 records the service capacity finally used by the service board B1, and performs service communication with the service board based on the service capacity finally used by the service board B1, thereby ensuring the communication quality.
The service board B1 also sends a second LLDP message carrying the service capacity of the service board B for final use to the service board C1 through the interface 22, so that the service board C1 records the service capacity of the service board B for final use, and performs service communication with the service board C1 based on the service capacity of the service board B1 for final use, thereby ensuring communication quality.
Next, it is assumed that at a certain moment, the service board B1 monitors that its connection with the service board C1 is disconnected, in which case, the service board B1 deletes the relevant data about the service board C1 from the opposite service board information table two, as shown in the table one above; then, the service board B1 finds that the service capacity (i.e., a 111) corresponding to the board type of the remaining opposite-end service board is not smaller than the service capacity finally used by the service board B1, maintains the service capacity finally used by the service board unchanged, and continues to perform service communication with the service board A1 based on the service capacity finally used by the service board.
Subsequently, it is assumed that at another time, the service board B1 receives, through the interface 27 (not shown in fig. 2), a first LLDP packet of a board type carrying the service board D1 sent by the service board D1 (belonging to the service board in the routing device 4, not shown in fig. 2) directly connected to the service board B1, and at this time, the service board B1 searches, from the above corresponding relationship, a service capacity corresponding to the board type of the service board D1; then, the service board B1 may add the interface identifier (for example, port_bd1) of the interface 27, the board type (for example, D11) of the service board D1, and the service capacity (for example, D111 and less than a 111) corresponding to the board type of the service board D1 to the above opposite service board information table, where the added opposite service board information table is shown in the following table four.
Interface identification Veneer type Service capacity
Port_ba1 A11 A111
Port_bd1 D11 D111
Table four
Thereafter, the service board B1 finds that the smallest service capacity (i.e., D111) among the service capacities corresponding to the board types of all the current opposite-end service boards (i.e., service boards A1 and D1) is smaller than the service capacity (i.e., a 111) that is ultimately used by the service board, in which case the service board B1 changes the service capacity that is ultimately used by the service board to D111, i.e., changes a111 in the above table three to D111, and the subsequent service board B1 performs service communication with the service board A1 and the service board D1 based on D111, respectively.
Meanwhile, the service board B1 also sends a second LLDP message carrying the service capacity finally used by the service board B1 to the service board A1 through the interface 21, so that the service board A1 records the service capacity used by the service board B1, and performs service communication with the service board based on the service capacity used by the service board B1, thereby ensuring the communication quality.
The service board B1 also sends a second LLDP message carrying the service capacity that is ultimately used by the service board B to the service board D1 through the interface 27, so that the service board D1 records the service capacity that is most recently used by the service board B, and performs service communication with the service board D1 based on the service capacity that is most recently used by the service board B1, thereby ensuring communication quality.
It should be noted that, the communication flow of the opposite end service boards directly connected to the other service boards in the routing device 1, the routing device 2 and the routing device 3 is similar to the communication flow of the opposite end service boards directly connected to the service board 1, and will not be described herein.
As can be seen from the above technical solutions, in the embodiments of the present application, for any service board in the routing device, before performing service communication with the directly connected opposite service board (different from the routing device to which the service board belongs), the service capacity of the service board for final use is determined through the LLDP packet carrying the board type from the opposite service board, and the service capacity is supported by the opposite service board; and then, sending an LLDP message carrying the service capacity finally used by the service board to the opposite-end service board so that the opposite-end service board can know the service capacity finally used by the service capacity and communicate with the service board based on the service capacity.
Therefore, under the condition that the service capacity between the service board and the opposite-end service board directly connected with the service board is inconsistent, the service board can enable the opposite-end service board to know the service capacity used when the opposite-end service board performs service communication by executing the communication flow, so that the opposite-end service board can perform service communication with the service board based on the service capacity, the problem that part of service cannot be processed is avoided, and the communication quality is improved.
Based on the same inventive concept, the present application further provides a communication device, where the device is applied to any service board in the routing, and the structural schematic diagram of the device is shown in fig. 3, and specifically includes:
a first determining module 31, configured to determine, when receiving a first link layer discovery protocol LLDP message carrying a board type of an opposite-end service board sent by any opposite-end service board directly connected to the service board, a service capacity corresponding to the board type according to a correspondence between locally stored board types and service capacities, where the service boards are different from routing devices to which the opposite-end service board belongs;
and the second determining module 32 is configured to determine the minimum service capacity of the service capacities corresponding to the single board types of the service boards and the determined service capacities corresponding to the single board types of all the opposite-end service boards as the service capacity of the service boards for final use, and send a second LLDP message carrying the service capacity of the service boards for final use to all the opposite-end service boards, so that all the opposite-end service boards perform service communication with the service boards based on the service capacity of the service boards for final use.
Preferably, the apparatus further comprises:
a first maintenance module (not shown in fig. 3) configured to, when it is monitored that the connection relationship between the service board and any of the peer service boards is disconnected, maintain the service capacity that is ultimately used by the service board unchanged if the minimum service capacity of the service capacities corresponding to the types of the single boards of the remaining peer service boards is not less than the service capacity that is ultimately used by the service board;
if the minimum service capacity in the service capacities corresponding to the single board types of the remaining opposite-end service boards is smaller than the service capacity finally used by the service boards, the service capacity finally used by the service boards is changed into the minimum service capacity in the service capacities corresponding to the single board types of the service boards and the service capacities corresponding to the single board types of the remaining opposite-end service boards, and a second LLDP message carrying the changed service capacities is sent to the remaining opposite-end service boards, so that all the opposite-end service boards carry out service communication with the service boards based on the changed service capacities.
Preferably, the apparatus further comprises:
a second maintenance module (not shown in fig. 3), configured to determine, according to the correspondence, a service capacity corresponding to a board type of a new opposite-end service board when receiving a first LLDP message carrying the board type of the new opposite-end service board sent by the new opposite-end service board directly connected to the service board;
if the minimum service capacity in the service capacities corresponding to the single board types of all the current opposite-end service boards is not less than the service capacity finally used by the service boards, maintaining the service capacity finally used by the service boards unchanged;
if the minimum service capacity in the service capacities corresponding to the single board types of all the current opposite-end service boards is smaller than the service capacity finally used by the service boards, the service capacity finally used by the service boards is changed into the minimum service capacity in the service capacities corresponding to the single board types of the service boards and the service capacities corresponding to the single board types of all the current opposite-end service boards, and a second LLDP message carrying the changed service capacities is sent to all the current opposite-end service boards, so that all the current opposite-end service boards carry out service communication with the service boards based on the changed service capacities.
Preferably, the apparatus further comprises:
an encryption module (not shown in fig. 3) configured to encrypt, according to a preset encryption algorithm, the service capacity that is ultimately used by the service board before sending second LLDP messages that carry the service capacity that is ultimately used by the service board to all the opposite service boards;
the second determining module 32 is specifically configured to send a second LLDP message carrying the service capacity obtained by the encrypting module to all the peer service boards.
Preferably, the preset encryption algorithm is an MD5 message digest algorithm. As can be seen from the above technical solutions, in the embodiments of the present application, for any service board in the routing device, before performing service communication with the directly connected opposite service board (different from the routing device to which the service board belongs), the service capacity of the service board for final use is determined through the LLDP packet carrying the board type from the opposite service board, and the service capacity is supported by the opposite service board; and then, sending an LLDP message carrying the service capacity finally used by the service board to the opposite-end service board so that the opposite-end service board can know the service capacity finally used by the service capacity and communicate with the service board based on the service capacity.
Therefore, under the condition that the service capacity between the service board and the opposite-end service board directly connected with the service board is inconsistent, the service board can enable the opposite-end service board to know the service capacity used when the opposite-end service board performs service communication by executing the communication flow, so that the opposite-end service board can perform service communication with the service board based on the service capacity, the problem that part of service cannot be processed is avoided, and the communication quality is improved.
The present embodiments also provide an electronic device, as shown in fig. 4, including a processor 1 and a machine-readable storage medium 42, the machine-readable storage medium 42 storing machine-executable instructions executable by the processor 1401, the processor 41 being caused by the machine-executable instructions to: the method for realizing the communication method comprises the steps of.
The machine-readable storage medium may include random access Memory (Random Access Memory, RAM) or Non-Volatile Memory (NVM), such as at least one magnetic disk Memory. In the alternative, the machine-readable storage medium may also be at least one memory device located remotely from the foregoing processor.
The processor may be a general-purpose processor, including a central processing unit (Central Processing Unit, CPU), a network processor (Network Processor, NP), etc.; but also digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), field programmable gate arrays (Field-Programmable Gate Array, FPGA) or peer programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
In yet another embodiment provided herein, there is also provided a computer readable storage medium having stored therein a computer program which when executed by a processor implements the steps of the communication method described above.
The foregoing description of the preferred embodiments of the present invention is not intended to limit the invention to the precise form disclosed, and any modifications, equivalents, improvements and alternatives falling within the spirit and principles of the present invention are intended to be included within the scope of the present invention.

Claims (8)

1. A communication method, wherein the method is applied to any service board in a routing device, the method comprising:
when receiving a first Link Layer Discovery Protocol (LLDP) message which is sent by any opposite-end service board directly connected with the service board and carries the single board type of the opposite-end service board, determining the service capacity corresponding to the single board type according to the corresponding relation between the locally stored single board type and the service capacity, wherein the service board and the routing equipment to which the opposite-end service board belongs are different;
and determining the minimum service capacity of the service capacities corresponding to the single board types of the service boards and the determined service capacities corresponding to the single board types of all opposite-end service boards as the service capacity which is finally used by the service boards, and sending a second LLDP message carrying the service capacity which is finally used by the service boards to all the opposite-end service boards so that all the opposite-end service boards can carry out service communication with the service boards based on the service capacity which is finally used by the service boards.
2. The method according to claim 1, wherein the method further comprises:
when a first LLDP message carrying the single board type of the new opposite terminal service board is received, which is sent by the new opposite terminal service board directly connected with the service board, determining the service capacity corresponding to the single board type of the new opposite terminal service board according to the corresponding relation;
if the minimum service capacity in the service capacities corresponding to the single board types of all the current opposite-end service boards is not less than the service capacity finally used by the service boards, maintaining the service capacity finally used by the service boards unchanged;
if the minimum service capacity in the service capacities corresponding to the single board types of all the current opposite-end service boards is smaller than the service capacity finally used by the service boards, the service capacity finally used by the service boards is changed into the minimum service capacity in the service capacities corresponding to the single board types of the service boards and the service capacities corresponding to the single board types of all the current opposite-end service boards, and a second LLDP message carrying the changed service capacities is sent to all the current opposite-end service boards, so that all the current opposite-end service boards carry out service communication with the service boards based on the changed service capacities.
3. The method of claim 1, wherein before sending the second LLDP message carrying the service capacity for end use of the service board to all of the peer service boards, the method further comprises:
encrypting the service capacity finally used by the service board according to a preset encryption algorithm;
the sending of the second LLDP message carrying the service capacity used by the service board to all the opposite terminal service boards specifically includes:
and sending second LLDP messages carrying the encrypted service capacity to all opposite terminal service boards.
4. A method according to claim 3, wherein the predetermined encryption algorithm is an MD5 information summarization algorithm.
5. A communication apparatus, the apparatus being applied to any service board in a routing device, the apparatus comprising:
a first determining module, configured to determine, when receiving a first link layer discovery protocol LLDP message carrying a board type of an opposite-end service board sent by any opposite-end service board directly connected to the service board, a service capacity corresponding to the board type according to a correspondence between locally stored board types and service capacities, where the service boards are different from routing devices to which the opposite-end service board belongs;
and the second determining module is used for determining the minimum service capacity of the service capacities corresponding to the single board types of the service boards and the determined service capacities corresponding to the single board types of all opposite-end service boards as the service capacity finally used by the service boards, and sending a second LLDP message carrying the service capacity finally used by the service boards to all the opposite-end service boards so that all the opposite-end service boards can carry out service communication with the service boards based on the service capacity finally used by the service boards.
6. The apparatus of claim 5, wherein the apparatus further comprises:
the second maintenance module is used for determining the service capacity corresponding to the single board type of the new opposite terminal service board according to the corresponding relation when receiving a first LLDP message which is directly connected with the service board and is sent by the new opposite terminal service board and carries the single board type of the new opposite terminal service board;
if the minimum service capacity in the service capacities corresponding to the single board types of all the current opposite-end service boards is not less than the service capacity finally used by the service boards, maintaining the service capacity finally used by the service boards unchanged;
if the minimum service capacity in the service capacities corresponding to the single board types of all the current opposite-end service boards is smaller than the service capacity finally used by the service boards, the service capacity finally used by the service boards is changed into the minimum service capacity in the service capacities corresponding to the single board types of the service boards and the service capacities corresponding to the single board types of all the current opposite-end service boards, and a second LLDP message carrying the changed service capacities is sent to all the current opposite-end service boards, so that all the current opposite-end service boards carry out service communication with the service boards based on the changed service capacities.
7. The apparatus of claim 5, wherein the apparatus further comprises:
the encryption module is used for encrypting the service capacity finally used by the service board according to a preset encryption algorithm before sending second LLDP messages carrying the service capacity finally used by the service board to all opposite-end service boards;
the second determining module is specifically configured to send a second LLDP packet carrying the service capacity obtained by the encrypting module to all the peer service boards.
8. The apparatus of claim 7, wherein the predetermined encryption algorithm is an MD5 information summarization algorithm.
CN202110984699.XA 2021-08-25 2021-08-25 Communication method and device Active CN113794639B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110984699.XA CN113794639B (en) 2021-08-25 2021-08-25 Communication method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110984699.XA CN113794639B (en) 2021-08-25 2021-08-25 Communication method and device

Publications (2)

Publication Number Publication Date
CN113794639A CN113794639A (en) 2021-12-14
CN113794639B true CN113794639B (en) 2023-04-25

Family

ID=78876547

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110984699.XA Active CN113794639B (en) 2021-08-25 2021-08-25 Communication method and device

Country Status (1)

Country Link
CN (1) CN113794639B (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101695029A (en) * 2009-10-22 2010-04-14 成都市华为赛门铁克科技有限公司 Data backup method, active-standby switching method and communication system as well as related equipment
CN106875170A (en) * 2016-07-22 2017-06-20 阿里巴巴集团控股有限公司 A kind of method and device for business processing of intermediate business system
CN110430135A (en) * 2019-07-08 2019-11-08 新华三信息安全技术有限公司 A kind of message processing method and device

Family Cites Families (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050049937A1 (en) * 2000-08-16 2005-03-03 Aaron Sanders Business method and processing system
MXPA03003656A (en) * 2000-10-26 2005-01-25 Wave7 Optics Inc Method and system for processing downstream packets of an optical network.
CN101005376A (en) * 2007-01-09 2007-07-25 华为技术有限公司 Device and method for realizing service plate main control plate communication
WO2010020151A1 (en) * 2008-08-18 2010-02-25 成都市华为赛门铁克科技有限公司 A method, apparatus and system for packet processing
CN102916909B (en) * 2012-10-11 2015-07-22 福建星网锐捷网络有限公司 Collocation method and device of AC card bandwidth and core device
CN103838298B (en) * 2012-11-21 2017-09-29 京信通信***(中国)有限公司 A kind of backboard, equipment and corresponding preparation method
CN104104592B (en) * 2013-04-12 2017-09-12 华为技术有限公司 Message processing method, apparatus and system
CN104604182B (en) * 2013-08-13 2018-01-19 华为技术有限公司 Service channel collocation method and optical line terminal and EPON
CN106330782B (en) * 2015-06-30 2020-06-26 中兴通讯股份有限公司 Port capacity allocation method and device and switch service board card
CN105939279B (en) * 2015-08-19 2019-02-19 杭州迪普科技股份有限公司 Flow processing method and device
CN106341338B (en) * 2016-09-09 2019-09-17 杭州迪普科技股份有限公司 A kind of retransmission method and device of message
CN106453092B (en) * 2016-11-07 2019-06-14 锐捷网络股份有限公司 A kind of route renewing method and device
CN106533882B (en) * 2016-11-18 2019-12-06 杭州迪普科技股份有限公司 Message processing method and device
CN106789652B (en) * 2016-12-29 2019-11-12 杭州迪普科技股份有限公司 Service shunting method and device
CN110912796B (en) * 2018-09-15 2022-03-11 华为技术有限公司 Communication method, device and system
CN111371666B (en) * 2018-12-26 2021-12-31 华为技术有限公司 Method, device and system for processing message
CN112135319A (en) * 2019-06-24 2020-12-25 中兴通讯股份有限公司 Bandwidth control method, device, equipment and computer readable storage medium
CN110784345B (en) * 2019-10-17 2022-11-01 杭州迪普科技股份有限公司 Network traffic processing method and device, electronic equipment and machine-readable storage medium

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101695029A (en) * 2009-10-22 2010-04-14 成都市华为赛门铁克科技有限公司 Data backup method, active-standby switching method and communication system as well as related equipment
CN106875170A (en) * 2016-07-22 2017-06-20 阿里巴巴集团控股有限公司 A kind of method and device for business processing of intermediate business system
CN110430135A (en) * 2019-07-08 2019-11-08 新华三信息安全技术有限公司 A kind of message processing method and device

Also Published As

Publication number Publication date
CN113794639A (en) 2021-12-14

Similar Documents

Publication Publication Date Title
US8838703B2 (en) Method and system for message processing
US20040221207A1 (en) Proxy response apparatus
CN113839862B (en) Method, system, terminal and storage medium for synchronizing ARP information between MCLAG neighbors
US10693967B2 (en) Data connection establishment method, server, and mobile terminal
CN111327650A (en) Data transmission method, device, equipment and storage medium
CN112218342A (en) Method, device and system for realizing core network sub-slice disaster tolerance
CN113507431B (en) Message management method, device, equipment and machine-readable storage medium
CN106850268B (en) device and method for realizing linear protection switching
CN113794639B (en) Communication method and device
CN112491951A (en) Request processing method, server and storage medium in peer-to-peer network
CN114189471B (en) Cross-equipment link aggregation group active-standby configuration method, system, terminal and storage medium
CN1330147C (en) Automatic discovering method of resilient packet ring (RPR) equipment
US20200341968A1 (en) Differential Update of Local Cache from Central Database
CN108418709B (en) Port aggregation method and device
CN110912837A (en) VSM system-based main/standby switching method and device
CN111405025A (en) Data transmission method and device, transmission equipment and readable storage medium
US20230106077A1 (en) Distributed Storage System, Exception Handling Method Thereof, and Related Apparatus
CN105634789A (en) Method of collector for associating device and log collection system
CN115086173B (en) Reliability guarantee method and device in network upgrading process
US11606274B1 (en) Method for operations of virtual machines in monitoring cloud activities, system, and device applying the method
CN113992566B (en) Message broadcasting method and device
CN111641698B (en) Data statistical method, system, equipment and storage medium
WO2018090381A1 (en) Connecting device between accessing terminals and radio communication device
CN117729117A (en) Multi-computer cluster topological relation determination method, device, electronic equipment and storage medium
CN107733669B (en) SNMP server management method and system based on request ID

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant