CN108667732A - A kind of message forwarding method and device - Google Patents
A kind of message forwarding method and device Download PDFInfo
- Publication number
- CN108667732A CN108667732A CN201810495311.8A CN201810495311A CN108667732A CN 108667732 A CN108667732 A CN 108667732A CN 201810495311 A CN201810495311 A CN 201810495311A CN 108667732 A CN108667732 A CN 108667732A
- Authority
- CN
- China
- Prior art keywords
- data message
- message
- forwarding
- address
- data
- 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.)
- Pending
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L45/00—Routing or path finding of packets in data switching networks
- H04L45/74—Address processing for routing
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L45/00—Routing or path finding of packets in data switching networks
- H04L45/28—Routing or path finding of packets in data switching networks using route fault recovery
Abstract
This application provides a kind of message forwarding method and device, it is related to message forwarding field, the method is applied to router, and router includes drive module and application module, the method includes:Drive module is after receiving data message, if detecting, data message is the target data message of preset message template description, by data message forwarding to application module;Application module obtains forwarding address corresponding with data message, is packaged processing to data message according to forwarding address, and obtained encapsulation of data message is transmitted to drive module after receiving data message;Drive module is after receiving encapsulation of data message, according to forwarding address forwarding data packets.In message repeating process, the data message of drive module forwarding needs not move through ETH modules and IP modules, also, without carrying out validity checking when drive module forwarding encapsulation of data message, the problem of alleviating the forwarding speed bottleneck of data message, improves message forward efficiency.
Description
Technical field
This application involves remote control technology fields, in particular to a kind of message forwarding method and device.
Background technology
Router device can forward the data message when receiving data message based on hardware, can also be based on soft
Part forwards the data message.
Router device in the method based on software forward message, for the application module needed in router device into
The message of row processing, traditional message forwarding process are needed by following module, and detailed process is as follows:Drive module (i.e. DRV moulds
Block) agreement (Internet Protocol, IP) module-for interconnecting between-ethernet module (i.e. ETH modules)-network applies mould
Block-IP module-ETH modules and DRV modules.
In traditional message repeating process, modules are required to be based on itself preconfigured message characteristic information pair
The incoming message of other modules carries out validity checking, is only confirming that the incoming message of other modules is legal, could be by message
It is sent to next node module.This will make above-mentioned message forwarding process lead to the problem of the forwarding speed bottleneck of message, into
And cause network obstructed, so as to cause the low problem of forward efficiency.
Invention content
In view of this, the embodiment of the present application is designed to provide a kind of message forwarding method and device, drive module energy
It is enough directly to be communicated with application module, ETH modules and IP modules are needed not move through, the forwarding speed bottleneck for alleviating message is asked
Topic, improves message forward efficiency.
In a first aspect, the embodiment of the present application provides a kind of message forwarding method, it is applied to router, the router packet
Drive module and application module are included, the method includes:
The drive module is after receiving data message, if detecting, the data message is that preset message template is retouched
The target data message stated then gives the data message forwarding to the application module;
The application module obtains forwarding address corresponding with the data message after receiving the data message,
Processing is packaged to the data message according to the forwarding address, and obtained encapsulation of data message is transmitted to the drive
Dynamic model block;
The drive module forwards the datagram after receiving the encapsulation of data message, according to the forwarding address
Text.
Second aspect, the embodiment of the present application also provides a kind of apparatus for forwarding message, including:
Drive module, for after receiving data message, the data message to be preset message template if detecting
The target data message of description, then by the data message forwarding to application module;
Application module, for after receiving the data message, obtaining forwarding address corresponding with the data message,
Processing is packaged to the data message according to the forwarding address, and obtained encapsulation of data message is transmitted to the drive
Dynamic model block;
The drive module is additionally operable to after receiving the encapsulation of data message, and institute is forwarded according to the forwarding address
State data message.
A kind of message forwarding method and device provided by the embodiments of the present application, drive module can be directly by application module senses
Application module is given on the data message of interest, application module obtains the forwarding address of the data message received and is based on this turn
Hair address is packaged the data message, and obtained encapsulation of data message is transmitted directly to drive module, to drive
Dynamic model block directly forwards the encapsulation of data message.In the repeating process of above-mentioned entire data message, drive module is to application module
The message of forwarding needs not move through ETH modules and IP modules, meanwhile, drive module forward application module encapsulation after message when also without
Validity checking need to be carried out, message is alleviated by ETH modules and IP module are transmitted and the validity checking of each module
It is the problem of forwarding speed bottleneck of caused data message, very big to improve message forward efficiency.
To enable the above objects, features, and advantages of the application to be clearer and more comprehensible, preferred embodiment cited below particularly, and coordinate
Appended attached drawing, is described in detail below.
Description of the drawings
It, below will be to needed in the embodiment attached in order to illustrate more clearly of the technical solution of the embodiment of the present application
Figure is briefly described, it should be understood that the following drawings illustrates only some embodiments of the application, therefore is not construed as pair
The restriction of range for those of ordinary skill in the art without creative efforts, can also be according to this
A little attached drawings obtain other relevant attached drawings.
Fig. 1 shows the structural schematic diagram for the router that the embodiment of the present application is provided.
Fig. 2 shows a kind of flow charts for message forwarding method that the embodiment of the present application is provided.
Fig. 3 shows the flow chart for another message forwarding method that the embodiment of the present application is provided.
Fig. 4 shows a kind of structural schematic diagram for apparatus for forwarding message that the embodiment of the present application is provided.
Fig. 5 shows the structural schematic diagram for the computer equipment 40 that one embodiment of the application is provided.
Specific implementation mode
To keep the purpose, technical scheme and advantage of the embodiment of the present application clearer, below in conjunction with the embodiment of the present application
Middle attached drawing, technical solutions in the embodiments of the present application are clearly and completely described, it is clear that described embodiment is only
It is some embodiments of the present application, instead of all the embodiments.The application being usually described and illustrated herein in the accompanying drawings is real
Applying the component of example can be arranged and designed with a variety of different configurations.Therefore, below to the application's for providing in the accompanying drawings
The detailed description of embodiment is not intended to limit claimed scope of the present application, but is merely representative of the selected reality of the application
Apply example.Based on embodiments herein, institute that those skilled in the art are obtained without making creative work
There is other embodiment, shall fall in the protection scope of this application.
Fig. 1 is a kind of structural schematic diagram of router provided by the embodiments of the present application, as shown in Figure 1, the router packet
Include drive module 10, application module 20 and interface board 30;Wherein, multiple interfaces 40 are provided on interface board 30.It is connect in interface 40
After receiving data message, drive module 10 can perceive the data message that interface 40 receives, and directly to application module 20
Forward the 20 interested data message of application module.In the embodiment of the present application, above application module can be tunnel modules
(specific such as generalized routing protocol encapsulation gre tunneling module), tunnel modules after receiving oneself interested data message,
The data message can be handled, it then will treated that data message is directly forwarded to drive module 10 is forwarded.This
In tunnel modules to there are many processing modes of oneself interested data message, as checked the letter carried in data message
Whether breath is correct, alternatively, the new data format for being different from the data format of the data message Reseals the data
Message.The drive module 10 in the embodiment of the present application is described in the datagram for perceiving interface 40 and receiving below by embodiment
The flow of 20 forwarding data packets of literary backward application module.
As shown in Fig. 2, for a kind of message forwarding method that the application first embodiment provides, it is applied to router, it is described
Router includes drive module and application module, the method includes:
S101, the drive module are after receiving data message, if detecting, the data message is preset message
The target data message of template description, then give the data message forwarding to the application module.
In the embodiment of the present application, user configures the interested target data message of the application module on application module first
Message template, the standard message feature (application module here of at least one target data message is stored in the message template
The interested target data message message that i.e. application module can be handled), after the completion of the message template configuration, by institute
It states message template and is handed down to drive module.Here, above-mentioned standard message characteristic include but not limited to one kind in following information or
It is a variety of:Five-tuple information, offset information and incoming interface information.
Drive module stores the message template after receiving the message template that application module issues.Work as drive module
After perceiving interface to data message, it is primarily based on message template and judges the data message whether application module is interested
Data message, if so, the data message is directly forwarded to the application module.If it is not, drive module directly abandons
The data message.
For example, the standard message characteristic information in the message template that application module issues can be as follows:Between purpose network
Address agreement (Internet Protocol, IP) of interconnection:5.5.0.2, protocol number:100 (complete, such as IP according to offset
100) and incoming interface it is that message, which deviates 30 bytes,:ten 2/0/1.Drive module detects the data after receiving data message
Whether incoming interface information, purpose IP address and the protocol number of message are respectively ten 2/0/1,5.5.0.2 and 100, if so, will
Application module is sent on the data message is direct.
S102, the application module obtain forwarding corresponding with the data message after receiving the data message
Address is packaged processing to the data message according to the forwarding address, and obtained encapsulation of data message is transmitted to
The drive module.
In the embodiment of the present application, the number that application module is directed to the data message received is different, obtains and the data
The mode of the corresponding forwarding address of message is also different.Wherein, the forwarding address includes the purpose thing of the target data message
Manage address (Media Access Control or Medium Access Control, MAC) and outgoing interface information.
The application module also handles the data message and (such as checks the number after receiving the data message
It is whether correct or Reseal the data message according to the data information in message), after the completion of the data message is handled, according to
The forwarding address of acquisition is assembled treated data message, and after the completion of message assembly, it is direct that encapsulation of data message will be obtained
It is transmitted to drive module, in this way, effectively reducing the transmission number of nodes and validity checking quantity of data message, improves report
The whole forward efficiency of text.
S103, the drive module are after receiving the encapsulation of data message, according to forwarding address forwarding
Data message.
In the embodiment of the present application, drive module directly forwards the encapsulation of data message after receiving encapsulation of data message,
Without carrying out legitimate verification to receiving encapsulation of data message, reduces drive module in the prior art and need to ETH moulds
The message that block is sent carries out the step of validity checking, further improves whole message forward efficiency.
Wherein, drive module directly forwards the flow of the encapsulation of data message as follows:Drive module is receiving encapsulation
After data message, the encapsulation of data message is parsed with being applied the data message after resume module and the forwarding of the data message
Location, then, for drive module according to the obtained forwarding address of parsing, forwarding parses the application module treated data message.
A kind of message forwarding method provided by the embodiments of the present application, drive module can be directly interested by application module
Application module is given on data message, application module obtains the forwarding address of the data message received and is based on the forwarding address
The data message is packaged, and obtained encapsulation of data message is transmitted directly to drive module, so as to drive module
Directly forward the encapsulation of data message.In the repeating process of above-mentioned entire data message, drive module is forwarded to application module
Message needs not move through ETH modules and IP modules, meanwhile, without progress when drive module forwards the message after application module encapsulation
Validity checking alleviates message by ETH modules and IP module are transmitted and the validity checking of each module is brought
Data message forwarding speed bottleneck the problem of, it is very big to improve message forward efficiency.
Further, as shown in figure 3, in message forwarding method provided by the embodiments of the present application, the preset message mould
The standard message feature that at least one target data message is stored in plate and the target word where the standard message feature
Section;The drive module detects the target data message that the data message is the preset message module description, including:
The object message feature that aiming field in S201, the extraction data message carries.
In the embodiment of the present application, drive module after receiving data message, without parse the data message but directly
Message matching is carried out, needs to carry out the forward efficiency that packet parsing also improves message compared with the prior art.
In specific implementation mode, the message matching method that drive module carries out is as follows:Drive module first looks for the data
Then aiming field in message extracts the object message feature that the aiming field carries.For example, being ten for incoming interface
2/0/1, the data message that purpose IP address is 5.5.0.2 and protocol number is 100, drive module take after being deviated according to position offset
Go out incoming interface data ten 2/0/1, destination address data 5.5.0.2 and the agreement number 100 of the data message.
S202, the object message feature is compared with the standard message feature, if the object message feature
Match with the standard message feature, it is determined that the data message is the target data of the preset message template description
Message.
In the embodiment of the present application, in incoming interface data, destination address data and the agreement number for taking out the data message
According to later, if detecting, the incoming interface of the data message be ten 2/0/1, destination address is 5.5.0.2, protocol number 100,
It then determines that the data message is the interested target data message of the application module, and application will be given on the data message
Module,
Further, in the message forwarding method provided in the embodiment of the present application, the data message carries purposeful net
The Protocol IP address interconnected between network;The number that application module is directed to the data message received is different, obtains and the data
The mode of the corresponding forwarding address of message is also different.
The first, for the data message received for the first time, the method that application module obtains forwarding address is as follows:Work as detection
To the data message be receive for the first time the first data message (the first data message herein be in order to distinguish second and
The second data message received later) when, then according to the purpose IP address of first data message, in preset forwarding table
Forwarding address corresponding with the destination IP address is searched in.
Here, preset forwarding-table item includes:Forwarding table (Forwarding Info Base, FIB) table and it is bordered by Table A DJ
Table.Wherein, purpose IP address and target MAC (Media Access Control) address corresponding with the target ip address are stored in fib table;It is deposited in ADJ tables
Contain purpose IP address and outgoing interface information corresponding with the target ip address.
In message forwarding method provided by the embodiments of the present application, the data message carries incoming interface information and destination IP
Address;The application module further includes after obtaining corresponding with data message forwarding address:
The fast-turn construction forwarding-table item of the data message is established, the data message is included at least in the fast-turn construction forwarding-table item
Incoming interface information, purpose IP address and forwarding address.
Here, in fast-turn construction forwarding-table item can also include other message characteristics, as at least one of five-tuple information its
His information (such as source IP address, source port address, destination interface address and protocol number) and offset information.It needs to illustrate
It is that other message characteristics that fast-turn construction forwarding-table item includes are not limited to the feature of the example above.
Second, for the data message that non-first time (namely second and after) receives, application module obtains forwarding
The method of address is as follows:When it is the non-data message received for the first time to detect the data message, from the data message
The corresponding fast-turn construction forwarding-table item of incoming interface information in, with searching corresponding with the purpose IP address of data message forwarding
Location.
Here, the second data message that application module is directed to second and receives later, from second data message
The corresponding fast-turn construction forwarding-table item of incoming interface information in, search the mesh to match with the purpose IP address of second data message
Mark purpose IP address;Then, it according to the target purpose IP address found, is searched and the mesh from the fast-turn construction forwarding-table item
Mark the corresponding forwarding address of purpose IP address.
It should be noted that if there is also other message characteristics in addition to purpose IP address in fast-turn construction forwarding-table item, then
Application module can also search second datagram by other message characteristics of the second data message from fast-turn construction forwarding-table item
The forwarding address of text.
In the embodiment of the present application, application module corresponds to the data message after it successfully forwarded data message, by foundation
Fast-turn construction forwarding-table item, for subsequently received data message, if the message characteristic for including is corresponding with its incoming interface information
Message characteristic in fast-turn construction forwarding-table item matches, then application module directly extracts the data message from fast-turn construction forwarding-table item
Forwarding address information, and the data message is forwarded based on forwarding address Information encapsulation, when reducing inquiry fib table and ADJ tables
Between, further improve message forward efficiency.
Further, in message forwarding method provided by the embodiments of the present application, the application module establishes the datagram
After the fast-turn construction forwarding-table item of text, further include:
When receiving the Interface down notification message for carrying target incoming interface information, enter with the target if detecting
The corresponding target fast-turn construction forwarding-table item of interface message, then delete the target fast-turn construction forwarding-table item.
Here, after the interface board failure of router or certain interface faults, it is logical that application module can receive interface fault
Know message, the target incoming interface information of faulty interface is carried in the Interface down notification message.When the interface board of router
Failure or certain interface faults and after restarting, the routing table corresponding to interface restarted may change, this is allowed for
The forwarding-table item (including fib table and ADJ tables) generated based on the routing table can also change, therefore, the correspondence stored originally
Possibly the data message from the incoming interface restarted can not be forwarded in the fast-turn construction forwarding-table item of incoming interface information, therefore, using mould
Block is receiving Interface down notification message, can inquire from multiple fast-turn construction forwarding-table items and be taken with the Interface down notification message
The incoming interface information of the target incoming interface information match of band enters to connect if detecting with the target incoming interface information match
Message ceases, then deletes the corresponding fast-turn construction forwarding-table item of the incoming interface information.
Meanwhile drive module is inquired again after receiving the data message from the interface restarted based on new road
The forwarding-table item established by table obtains the forwarding address of the data message, and then forwards the data message based on the forwarding address,
The problem of avoiding appearance mistake forwarding.The fast-turn construction forwarding corresponding to the data message of the interface restarted also is re-established simultaneously
List item further improves message forward efficiency to reduce inquiry fib table and ADJ table times.
Message forwarding method provided by the embodiments of the present application reduces in message repeating process, biography between modules
The validity checking of successive number and respond module alleviates the forwarding speed bottleneck problem of message, improves message forwarding effect
Rate.Meanwhile application module issues the standard feature information of target data message to drive module, can't influence other datagrams
Literary normal forwarding.In addition, the module number passed through by reducing data message, solves reduced module and is led since itself is busy
The low problem of the forward efficiency of cause.
As shown in figure 4, for a kind of apparatus for forwarding message that the application second embodiment provides, for executing first embodiment
A kind of message forwarding method provided, described device include:
Drive module 10, for after receiving data message, the data message to be preset message mould if detecting
The target data message of plate description, then by the data message forwarding to application module 20;
Application module 20, for after receiving the data message, obtaining forwarding ground corresponding with the data message
Location is packaged processing to the data message according to the forwarding address, and obtained encapsulation of data message is transmitted to drive
Dynamic model block 10;
Drive module 10 is additionally operable to after receiving the encapsulation of data message, according to forwarding address forwarding
Data message.
Optionally, be stored in the preset message template standard message feature of at least one target data message with
And the aiming field where the standard message feature;Drive module 10, is specifically used for:
Extract the object message feature that the aiming field in the data message carries;
The object message feature is compared with the standard message feature, if the object message feature with it is described
Standard message feature matches, it is determined that the data message is the target data message of the preset message template description.
Optionally, the data message carries the Protocol IP address interconnected between purposeful network;
Application module 20, specifically for when it is the data message received for the first time to detect the data message, according to
The purpose IP address of the data message searches forwarding ground corresponding with the destination IP address in preset forwarding-table item
Location.
Optionally, the data message carries incoming interface information and purpose IP address;
Application module 20, is additionally operable to establish the fast-turn construction forwarding-table item of the data message, in the fast-turn construction forwarding-table item extremely
Include incoming interface information, purpose IP address and the forwarding address of the data message less;
Application module 20, specifically for detect the data message be the non-data message received for the first time when, from
In the corresponding fast-turn construction forwarding-table item of incoming interface information of the data message, the purpose IP address pair with the data message is searched
The forwarding address answered.
Optionally, further include the incoming interface information of the target data message in the fast-turn construction forwarding-table item;
Application module 20 is additionally operable to when receiving the Interface down notification message for carrying target incoming interface information, if
It detects target fast-turn construction forwarding-table item corresponding with the target incoming interface information, then deletes the target fast-turn construction forwarding-table item.
A kind of apparatus for forwarding message provided by the embodiments of the present application, drive module can be directly interested by application module
Application module is given on data message, application module obtains the forwarding address of the data message received and is based on the forwarding address
The data message is packaged, and obtained encapsulation of data message is transmitted directly to drive module, so as to drive module
Directly forward the encapsulation of data message.In the repeating process of above-mentioned entire data message, drive module is forwarded to application module
Message needs not move through ETH modules and IP modules, meanwhile, without progress when drive module forwards the message after application module encapsulation
Validity checking alleviates message by ETH modules and IP module are transmitted and the validity checking of each module is brought
Data message forwarding speed bottleneck the problem of, it is very big to improve message forward efficiency.
In addition, apparatus for forwarding message provided by the embodiments of the present application, application module are issued to drive module including number of targets
According to the message template of the standard feature information of message, other data messages can't be influenced and normally forwarded.In addition, by reducing number
According to the module number that message passes through, efficiently solve reduced module due to itself it is busy caused by forward efficiency is low asks
Topic.
Fig. 5 is the structural schematic diagram for the computer equipment 40 that one embodiment of the application provides, as shown in figure 5, for executing
Message forwarding method in Fig. 2, the equipment include memory 401, processor 402 and are stored on the memory 401 and can be
The computer program run on the processor 402, wherein above-mentioned processor 402 is realized above-mentioned when executing above computer program
The step of message forwarding method.
Specifically, above-mentioned memory 401 and processor 402 can be general memory and processor, do not do have here
Body limits, and when the computer program of 402 run memory 401 of processor storage, is able to carry out above-mentioned message forwarding method.
Corresponding to the message forwarding method in Fig. 2, the embodiment of the present application also provides a kind of computer readable storage medium,
It is stored with computer program on the computer readable storage medium, which executes above-mentioned message when being run by processor
The step of retransmission method.
Specifically, which can be general storage medium, such as mobile disk, hard disk, on the storage medium
Computer program when being run, be able to carry out above-mentioned message forwarding method.
The apparatus for forwarding message that the embodiment of the present application is provided can be equipment on specific hardware or be installed on equipment
On software or firmware etc..The technique effect of the device that the embodiment of the present application is provided, realization principle and generation and aforementioned side
Method embodiment is identical, and to briefly describe, device embodiment part does not refer to place, can refer in corresponding in preceding method embodiment
Hold.It is apparent to those skilled in the art that for convenience and simplicity of description, the system of foregoing description, device
With the specific work process of unit, the corresponding process in above method embodiment can be referred to, details are not described herein.
In embodiment provided herein, it should be understood that disclosed device and method, it can be by others side
Formula is realized.The apparatus embodiments described above are merely exemplary, for example, the division of the unit, only one kind are patrolled
Volume function divides, formula that in actual implementation, there may be another division manner, in another example, multiple units or component can combine or can
To be integrated into another system, or some features can be ignored or not executed.Another point, shown or discussed is mutual
Coupling, direct-coupling or communication connection can be INDIRECT COUPLING or communication link by some communication interfaces, device or unit
It connects, can be electrical, machinery or other forms.
The unit illustrated as separating component may or may not be physically separated, aobvious as unit
The component shown may or may not be physical unit, you can be located at a place, or may be distributed over multiple
In network element.Some or all of unit therein can be selected according to the actual needs to realize the mesh of this embodiment scheme
's.
In addition, each functional unit in embodiment provided by the present application can be integrated in a processing unit, also may be used
It, can also be during two or more units be integrated in one unit to be that each unit physically exists alone.
It, can be with if the function is realized in the form of SFU software functional unit and when sold or used as an independent product
It is stored in a computer read/write memory medium.Based on this understanding, the technical solution of the application is substantially in other words
The part of the part that contributes to existing technology or the technical solution can be expressed in the form of software products, the meter
Calculation machine software product is stored in a storage medium, including some instructions are used so that a computer equipment (can be
People's computer, server or network equipment etc.) execute each embodiment the method for the application all or part of step.
And storage medium above-mentioned includes:USB flash disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), arbitrary access are deposited
The various media that can store program code such as reservoir (RAM, Random Access Memory), magnetic disc or CD.
It should be noted that:Similar label and letter indicate similar terms in following attached drawing, therefore, once a certain Xiang Yi
It is defined, then it further need not be defined and explained in subsequent attached drawing in a attached drawing, in addition, term " the
One ", " second ", " third " etc. are only used for distinguishing description, are not understood to indicate or imply relative importance.
Finally it should be noted that:Embodiment described above, the only specific implementation mode of the application, to illustrate the application
Technical solution, rather than its limitations, the protection domain of the application is not limited thereto, although with reference to the foregoing embodiments to this Shen
It please be described in detail, it will be understood by those of ordinary skill in the art that:Any one skilled in the art
In the technical scope that the application discloses, it can still modify to the technical solution recorded in previous embodiment or can be light
It is readily conceivable that variation or equivalent replacement of some of the technical features;And these modifications, variation or replacement, do not make
The essence of corresponding technical solution is detached from the spirit and scope of the embodiment of the present application technical solution.The protection in the application should all be covered
Within the scope of.Therefore, the protection domain of the application should be based on the protection scope of the described claims.
Claims (10)
1. a kind of message forwarding method, which is characterized in that be applied to router, the router include drive module and apply mould
Block, the method includes:
The drive module is after receiving data message, if detecting, the data message is the description of preset message template
Target data message then gives the data message forwarding to the application module;
The application module obtains forwarding address corresponding with the data message after receiving the data message, according to
The forwarding address is packaged processing to the data message, and obtained encapsulation of data message is transmitted to the driving mould
Block;
The drive module forwards the data message after receiving the encapsulation of data message, according to the forwarding address.
2. message forwarding method according to claim 1, which is characterized in that be stored in the preset message template to
The standard message feature and the aiming field where the standard message feature of a few target data message;The driving mould
Block detects the target data message that the data message is the preset message module description, including:
Extract the object message feature that the aiming field in the data message carries;
The object message feature is compared with the standard message feature, if the object message feature and the standard
Message characteristic matches, it is determined that the data message is the target data message of the preset message template description.
3. message forwarding method according to claim 1 or 2, which is characterized in that the data message carries purposeful net
The Protocol IP address interconnected between network;The application module obtains forwarding address corresponding with the data message, including:
When it is the data message received for the first time to detect the data message, according to the destination IP of the data message
Forwarding address corresponding with the destination IP address is searched in location in preset forwarding-table item.
4. message forwarding method according to claim 1 or 2, which is characterized in that the data message carries incoming interface
Information and purpose IP address;The application module further includes after obtaining corresponding with data message forwarding address:
The fast-turn construction forwarding-table item of the data message is established, entering for the data message is included at least in the fast-turn construction forwarding-table item
Interface message, purpose IP address and forwarding address;
The application module obtains forwarding address corresponding with the data message, further includes:
When it is the non-data message received for the first time to detect the data message, from the incoming interface information of the data message
In corresponding fast-turn construction forwarding-table item, forwarding address corresponding with the purpose IP address of the data message is searched.
5. message forwarding method according to claim 4, which is characterized in that the application module establishes the data message
Fast-turn construction forwarding-table item after, further include:
When receiving the Interface down notification message for carrying target incoming interface information, if detecting and the target incoming interface
The corresponding target fast-turn construction forwarding-table item of information, then delete the target fast-turn construction forwarding-table item.
6. a kind of apparatus for forwarding message, which is characterized in that including:
Drive module, for after receiving data message, the data message to describe for preset message template if detecting
Target data message, then by the data message forwarding to application module;
Application module, for after receiving the data message, obtaining forwarding address corresponding with the data message, according to
The forwarding address is packaged processing to the data message, and obtained encapsulation of data message is transmitted to the driving mould
Block;
The drive module is additionally operable to after receiving the encapsulation of data message, and the number is forwarded according to the forwarding address
According to message.
7. apparatus for forwarding message according to claim 6, which is characterized in that be stored in the preset message template to
The standard message feature and the aiming field where the standard message feature of a few target data message;The driving mould
Block is specifically used for:
Extract the object message feature that the aiming field in the data message carries;
The object message feature is compared with the standard message feature, if the object message feature and the standard
Message characteristic matches, it is determined that the data message is the target data message of the preset message template description.
8. the apparatus for forwarding message described according to claim 6 or 7, which is characterized in that the data message carries purposeful net
The Protocol IP address interconnected between network;
The application module, specifically for when it is the data message received for the first time to detect the data message, according to institute
The purpose IP address for stating data message searches forwarding address corresponding with the destination IP address in preset forwarding-table item.
9. the apparatus for forwarding message described according to claim 6 or 7, which is characterized in that the data message carries incoming interface
Information and purpose IP address;
The application module, is additionally operable to establish the fast-turn construction forwarding-table item of the data message, in the fast-turn construction forwarding-table item at least
Incoming interface information, purpose IP address and forwarding address including the data message;
The application module, specifically for detect the data message be the non-data message received for the first time when, from institute
In the corresponding fast-turn construction forwarding-table item of incoming interface information for stating data message, search corresponding with the purpose IP address of the data message
Forwarding address.
10. apparatus for forwarding message according to claim 9, which is characterized in that
The application module is additionally operable to when receiving the Interface down notification message for carrying target incoming interface information, if inspection
Target fast-turn construction forwarding-table item corresponding with the target incoming interface information is measured, then deletes the target fast-turn construction forwarding-table item.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810495311.8A CN108667732A (en) | 2018-05-22 | 2018-05-22 | A kind of message forwarding method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810495311.8A CN108667732A (en) | 2018-05-22 | 2018-05-22 | A kind of message forwarding method and device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN108667732A true CN108667732A (en) | 2018-10-16 |
Family
ID=63777515
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810495311.8A Pending CN108667732A (en) | 2018-05-22 | 2018-05-22 | A kind of message forwarding method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108667732A (en) |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110134086A (en) * | 2019-05-17 | 2019-08-16 | 温州大学 | Realize the data collection and control device of middleware function in a kind of digitlization workshop |
CN111367943A (en) * | 2018-12-26 | 2020-07-03 | 中兴通讯股份有限公司 | Data transmission verification method, system, computer equipment and storage medium |
CN112333806A (en) * | 2020-11-11 | 2021-02-05 | 大连金盛义电子科技有限公司 | Tunnel wireless redundant relay ring network system unit and system |
CN113271266A (en) * | 2021-04-21 | 2021-08-17 | 锐捷网络股份有限公司 | Message forwarding method and device for heterogeneous switching chip |
CN114500654A (en) * | 2022-02-23 | 2022-05-13 | 石家庄通合电子科技股份有限公司 | Data forwarding device, power module and data forwarding method |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102299862A (en) * | 2011-09-22 | 2011-12-28 | 北京傲天动联技术有限公司 | Quick forwarding equipment and method for two-layer tunnel |
US20140321265A1 (en) * | 2013-04-29 | 2014-10-30 | Telefonaktiebolaget L M Ericsson (Publ) | Fast traffic recovery in vrrp based routers |
CN104639443A (en) * | 2015-02-16 | 2015-05-20 | 杭州华三通信技术有限公司 | Method and device for rapidly forwarding message |
CN106161227A (en) * | 2016-06-27 | 2016-11-23 | 杭州华三通信技术有限公司 | A kind of message forwarding method and device |
CN106254433A (en) * | 2016-07-28 | 2016-12-21 | 杭州迪普科技有限公司 | A kind of method and device setting up TCP communication connection |
CN106878138A (en) * | 2017-01-18 | 2017-06-20 | 新华三技术有限公司 | A kind of message transmitting method and device |
-
2018
- 2018-05-22 CN CN201810495311.8A patent/CN108667732A/en active Pending
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102299862A (en) * | 2011-09-22 | 2011-12-28 | 北京傲天动联技术有限公司 | Quick forwarding equipment and method for two-layer tunnel |
US20140321265A1 (en) * | 2013-04-29 | 2014-10-30 | Telefonaktiebolaget L M Ericsson (Publ) | Fast traffic recovery in vrrp based routers |
CN104639443A (en) * | 2015-02-16 | 2015-05-20 | 杭州华三通信技术有限公司 | Method and device for rapidly forwarding message |
CN106161227A (en) * | 2016-06-27 | 2016-11-23 | 杭州华三通信技术有限公司 | A kind of message forwarding method and device |
CN106254433A (en) * | 2016-07-28 | 2016-12-21 | 杭州迪普科技有限公司 | A kind of method and device setting up TCP communication connection |
CN106878138A (en) * | 2017-01-18 | 2017-06-20 | 新华三技术有限公司 | A kind of message transmitting method and device |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111367943A (en) * | 2018-12-26 | 2020-07-03 | 中兴通讯股份有限公司 | Data transmission verification method, system, computer equipment and storage medium |
CN110134086A (en) * | 2019-05-17 | 2019-08-16 | 温州大学 | Realize the data collection and control device of middleware function in a kind of digitlization workshop |
CN112333806A (en) * | 2020-11-11 | 2021-02-05 | 大连金盛义电子科技有限公司 | Tunnel wireless redundant relay ring network system unit and system |
CN113271266A (en) * | 2021-04-21 | 2021-08-17 | 锐捷网络股份有限公司 | Message forwarding method and device for heterogeneous switching chip |
CN113271266B (en) * | 2021-04-21 | 2024-03-22 | 锐捷网络股份有限公司 | Message forwarding method and device of heterogeneous switching chip |
CN114500654A (en) * | 2022-02-23 | 2022-05-13 | 石家庄通合电子科技股份有限公司 | Data forwarding device, power module and data forwarding method |
CN114500654B (en) * | 2022-02-23 | 2024-03-22 | 石家庄通合电子科技股份有限公司 | Data forwarding device, power module and data forwarding method |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108667732A (en) | A kind of message forwarding method and device | |
CN103401726B (en) | Network path detection method and device, system | |
CN103581021B (en) | The method and apparatus of business detection under software defined network | |
CN105939239B (en) | Data transmission method and device of virtual network card | |
CN101778113B (en) | Method for detection of RP state in multicast network, device, RP device and multicast system | |
CN104079571B (en) | A kind of method and device for recognizing Android simulator | |
CN107517119B (en) | Virtual network detection method and device in VPC environment | |
CN106878181A (en) | A kind of message transmitting method and device | |
CN107147655A (en) | A kind of network dual stack parallel process model and its processing method | |
WO2017000790A1 (en) | Gateway device network connectivity response method and device | |
CN109379241A (en) | A kind of routing information determines method and device | |
CN107547346A (en) | A kind of message transmitting method and device | |
CN107623757A (en) | Entry updating method and apparatus | |
CN104038384A (en) | Tracking and tracing system based on GBF and working method thereof | |
CN107547400B (en) | Virtual machine migration method and device | |
CN106507414A (en) | Message forwarding method and device | |
CN109005082A (en) | Method and device for capturing Ethernet message by using CRC (Cyclic redundancy check) field | |
US9800490B2 (en) | Testing by simulation using variations of real-time traffic | |
US20200344129A1 (en) | Determining network topology based on packet traffic | |
CN102299862A (en) | Quick forwarding equipment and method for two-layer tunnel | |
CN104969521A (en) | Data sending and processing method and router | |
CN105592169A (en) | Terminal identification method and terminal identification device | |
US20220174081A1 (en) | Monitoring of abnormal host | |
CN104869062A (en) | Data packet forwarding method and device | |
US11949646B2 (en) | Correlating protocol data units transiting networks with differing addressing schemes |
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 | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20181016 |