[go: up one dir, main page]

CN105634842B - A kind of method, apparatus and system of detection bandwidth - Google Patents

A kind of method, apparatus and system of detection bandwidth Download PDF

Info

Publication number
CN105634842B
CN105634842B CN201410596935.0A CN201410596935A CN105634842B CN 105634842 B CN105634842 B CN 105634842B CN 201410596935 A CN201410596935 A CN 201410596935A CN 105634842 B CN105634842 B CN 105634842B
Authority
CN
China
Prior art keywords
bandwidth
message
specific
forwarding device
request message
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
CN201410596935.0A
Other languages
Chinese (zh)
Other versions
CN105634842A (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.)
Qinghai Yuanteng Electronic Information Technology Co ltd
Original Assignee
Huawei 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 Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201410596935.0A priority Critical patent/CN105634842B/en
Publication of CN105634842A publication Critical patent/CN105634842A/en
Application granted granted Critical
Publication of CN105634842B publication Critical patent/CN105634842B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

本发明实施例提供一种检测带宽的方法、装置及系统,涉及计算机网络技术领域,能够快速检测带宽,且不会影响网络上正常的数据传输。该方法包括:源端设备向转发设备发送第一带宽请求报文,第一带宽请求报文的IP地址为目的端设备的IP地址;源端设备接收转发设备发送的带宽响应报文,带宽响应报文包括转发设备的IP地址和带宽;源端设备存储带宽,并生成第二带宽请求报文,第二带宽请求报文的生存时间TTL的值比第一带宽请求报文的TTL的值大一。

Embodiments of the present invention provide a method, device, and system for detecting bandwidth, which relate to the technical field of computer networks and can quickly detect bandwidth without affecting normal data transmission on the network. The method includes: the source end device sends a first bandwidth request message to the forwarding device, and the IP address of the first bandwidth request message is the IP address of the destination end device; the source end device receives the bandwidth response message sent by the forwarding device, and the bandwidth response message The packet includes the IP address and bandwidth of the forwarding device; the source device stores the bandwidth and generates a second bandwidth request packet. The time-to-live TTL value of the second bandwidth request packet is greater than the TTL value of the first bandwidth request packet one.

Description

A kind of method, apparatus and system of detection bandwidth
Technical field
The present invention relates to technical field of the computer network more particularly to the method, apparatus and system of a kind of detection bandwidth.
Background technique
Detection bandwidth is carried out generally by double-end monitor method.The double-end monitor method of bandwidth are as follows: source equipment with Preset rate K0 sends detection flows to purpose end equipment, and purpose end equipment records the arrival of each data packet in detection flows Time, and counted according to the temporal characteristics that the arrival time of each data packet reaches purpose end equipment to detection flows, from And network delay is calculated according to temporal characteristics, and judge congestion whether occurs on transmission link according to network delay, and will sentence Disconnected result is sent to source equipment;Source equipment according to judging result adjust detection flows size, and with new rate K1 to Purpose end equipment sends detection flows.Above-mentioned detection process is executed repeatedly, and up to obtaining on transmission link, there is no congestions In the case of maximum stream flow, to obtain the bandwidth between source equipment and purpose end equipment.
Go out bandwidth in order to accurate detection, source equipment needs the repeatedly size of adjustment detection flows and to destination Equipment sends detection flows, causes detection process comparatively laborious, and time-consuming, and occupies a large amount of Internet resources.
Summary of the invention
The embodiment of the present invention provides the method, apparatus and system of a kind of detection bandwidth, can quick detection bandwidth, and not It will affect normal data transmission on network.
In a first aspect, the embodiment of the invention provides a kind of methods of detection bandwidth, this method comprises:
Source equipment sends the first bandwidth request message to forwarding device, and the purpose of the first bandwidth request message is because of spy FidonetFido IP address is the IP address of purpose end equipment;
The source equipment receives the bandwidth response message that the forwarding device is sent, wherein the bandwidth response message IP address and bandwidth including the forwarding device, the bandwidth are that the forwarding device is jumped with the next of the forwarding device Send out the bandwidth of equipment room;
The source equipment stores the bandwidth, and generates the second bandwidth request message, the second bandwidth request message Life span TTL value it is bigger by one than the value of the TTL of the first bandwidth request message.
With reference to first aspect, in the first possible implementation of the first aspect, the first bandwidth request message It is User Datagram Protocol UDP type message with the second bandwidth request message, the UDP type message includes specific first end Slogan, the specific first end slogan identify that the UDP type message is bandwidth request message for the forwarding device, or The first bandwidth request message and the second bandwidth request message are transmission control protocol TCP type message, the TCP type report Text includes specific second end slogan, and the specific second end slogan identifies the TCP type message for the forwarding device For bandwidth request message;
If the bandwidth response message is UDP type message, the UDP type message includes specific third port number, institute It states specific third port number and identifies that the UDP type message is bandwidth response message for the source equipment;
If the bandwidth response message is TCP type message, the TCP type message includes specific 4th port numbers, institute It states specific 4th port numbers and identifies that the TCP type message is bandwidth response message for the source equipment.
Second aspect, the embodiment of the present invention provide a kind of method of detection bandwidth, this method comprises:
Forwarding device receives the first bandwidth request message that source equipment is sent, the purpose of the first bandwidth request message Internet protocol IP address is the IP address of purpose end equipment, the value etc. of the life span TTL of the first bandwidth request message Yu Yi, the first bandwidth request message include specific first end slogan or specific second end slogan;
The forwarding device is according to the specific first end slogan or the specific second end slogan, described in confirmation First bandwidth request message is bandwidth request message;
The forwarding device is to the source equipment transmission bandwidth response message, wherein the bandwidth response message includes The IP address and bandwidth of the forwarding device, the bandwidth are that the next-hop forwarding of the forwarding device and the forwarding device is set Bandwidth between standby.
In conjunction with second aspect, in the first possible implementation of the second aspect,
The first bandwidth request message is User Datagram Protocol UDP type message, and the UDP type message includes the spy Fixed first end slogan, the specific first end slogan identify that the UDP type message is asked for bandwidth for the forwarding device It seeks message or the first bandwidth request message is transmission control protocol TCP type message, the TCP type message includes described Specific second end slogan, the specific second end slogan identify that the TCP type message is bandwidth for the forwarding device Request message;
If the bandwidth response message is UDP type message, the UDP type message includes specific third port number, institute It states specific third port number and identifies that the UDP type message is bandwidth response message for the source equipment;
If the bandwidth response message is TCP type message, the TCP type message includes specific 4th port numbers, institute It states specific 4th port numbers and identifies that the TCP type message is bandwidth response message for the source equipment.
The third aspect, the embodiment of the present invention provide a kind of source equipment, which includes:
Sending module, for sending the first bandwidth request message, the mesh of the first bandwidth request message to forwarding device Internet protocol IP address be purpose end equipment IP address;
Receiving module, the bandwidth response message sent for receiving the forwarding device, wherein the bandwidth response message IP address and bandwidth including the forwarding device, the bandwidth are that the forwarding device is jumped with the next of the forwarding device Send out the bandwidth of equipment room;
Execution module for storing the bandwidth, and generates the second bandwidth request message, the second bandwidth request message Life span TTL value it is bigger by one than the value of the TTL of the first bandwidth request message.
In conjunction with the third aspect, in the first possible implementation of the third aspect, the first bandwidth request message It is User Datagram Protocol UDP type message with the second bandwidth request message, the UDP type message includes specific first end Slogan, the specific first end slogan identify that the UDP type message is bandwidth request message for the forwarding device, or The first bandwidth request message and the second bandwidth request message are transmission control protocol TCP type message, the TCP type report Text includes specific second end slogan, and the specific second end slogan identifies the TCP type message for the forwarding device For bandwidth request message;
If the bandwidth response message is UDP type message, the UDP type message includes specific third port number, institute It states specific third port number and identifies that the UDP type message is bandwidth response message for the source equipment;
If the bandwidth response message is TCP type message, the TCP type message includes specific 4th port numbers, institute It states specific 4th port numbers and identifies that the TCP type message is bandwidth response message for the source equipment.
Fourth aspect, the embodiment of the present invention provide a kind of forwarding device, which includes:
Receiving module, for receiving the first bandwidth request message of source equipment transmission, the first bandwidth request message Purpose Internet protocol IP address be purpose end equipment IP address, the life span TTL of the first bandwidth request message Value be equal to one, the first bandwidth request message includes specific first end slogan or specific second end slogan;
Confirmation module, for confirming institute according to the specific first end slogan or the specific second end slogan Stating the first bandwidth request message is bandwidth request message;
Sending module, for the source equipment transmission bandwidth response message, wherein the bandwidth response message includes The IP address and bandwidth of the forwarding device, the bandwidth are that the next-hop forwarding of the forwarding device and the forwarding device is set Bandwidth between standby.
In conjunction with fourth aspect, in the first possible implementation of the fourth aspect,
The first bandwidth request message is User Datagram Protocol UDP type message, and the UDP type message includes the spy Fixed first end slogan, the specific first end slogan identify that the UDP type message is asked for bandwidth for the forwarding device It seeks message or the first bandwidth request message is transmission control protocol TCP type message, the TCP type message includes described Specific second end slogan, the specific second end slogan identify that the TCP type message is bandwidth for the forwarding device Request message;
If the bandwidth response message is UDP type message, the UDP type message includes specific third port number, institute It states specific third port number and identifies that the UDP type message is bandwidth response message for the source equipment;
If the bandwidth response message is TCP type message, the TCP type message includes specific 4th port numbers, institute It states specific 4th port numbers and identifies that the TCP type message is bandwidth response message for the source equipment.
5th aspect, the embodiment of the present invention provide a kind of system of detection bandwidth, which includes having such as the third aspect Any one of described in source equipment and multiple forwarding devices as described in any one of fourth aspect.
The present invention provides the method, apparatus and system of a kind of detection bandwidth, sends the to forwarding device by source equipment One bandwidth request message carrys out the bandwidth between detection source end equipment and purpose end equipment, and source equipment receives what forwarding device was sent Bandwidth response message judges whether forwarding device is purpose end equipment.When forwarding device is not purpose end equipment, source equipment Bandwidth in memory bandwidth response message, and generate the second bandwidth request message, the value of the TTL of the second bandwidth request message is than the The value of the TTL of one bandwidth request message is big by one;When forwarding device is purpose end equipment, source equipment obtain purpose end equipment with The bandwidth of source equipment room.With this solution, since source equipment can pass through bandwidth response Receive message source equipment and mesh End equipment between all forwarding devices bandwidth, i.e., message transmit by way of obtain source equipment and purpose end equipment Between bandwidth, additional bandwidth will not be occupied.Therefore, when can solve through double-end monitor method detection bandwidth, volume is occupied The problem of outer bandwidth, and can quick detection bandwidth, and will not influence normal data transmission on network.
Detailed description of the invention
In order to illustrate the technical solution of the embodiments of the present invention more clearly, required use in being described below to embodiment Attached drawing be briefly described, it should be apparent that, drawings in the following description are only some embodiments of the invention, for this For the those of ordinary skill of field, without creative efforts, it can also be obtained according to these attached drawings others Attached drawing.
Fig. 1 is a kind of flow diagram one of the method for detection bandwidth provided in an embodiment of the present invention;
Fig. 2 is a kind of flow diagram two of the method for detection bandwidth provided in an embodiment of the present invention;
Fig. 3 is a kind of network link schematic diagram provided in an embodiment of the present invention;
Fig. 4 is a kind of structural schematic diagram one for source equipment that present invention implementation provides;
Fig. 5 is a kind of structural schematic diagram one for forwarding device that present invention implementation provides;
Fig. 6 is a kind of structural schematic diagram two of source equipment provided in an embodiment of the present invention;
Fig. 7 is a kind of structural schematic diagram two of forwarding device provided in an embodiment of the present invention;
Fig. 8 is a kind of structural schematic diagram of the system for detection bandwidth that present invention implementation provides.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention is clearly retouched It states, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.Based on the present invention In embodiment, every other implementation obtained by those of ordinary skill in the art without making creative efforts Example, shall fall within the protection scope of the present invention.
Embodiment one
The embodiment of the present invention provides a kind of method of detection bandwidth, is as shown in Figure 1 the flow diagram of this method, specifically Include:
S101, source equipment send the first bandwidth request message to forwarding device.
Purpose Internet Protocol (English: Internet Protocol, abbreviation: IP) address of first bandwidth request message For the IP address of purpose end equipment.Forwarding device is other in addition to source equipment on source equipment network link detected Equipment, including all forwarding devices passed through between source equipment and purpose end equipment and purpose end equipment.In real network chain On the road, forwarding device can be router or three-tier switch.
It should be noted that in the first bandwidth request message including the first bandwidth request message life span (English: Time to Live, abbreviation: TTL).First bandwidth request message is User Datagram Protocol (English: User Datagram Protocol, abbreviation: UDP) type message, UDP type message includes specific first end slogan, and specific first end slogan is for turning Hair equipment identification UDP type message be bandwidth request message or the first bandwidth request message be transmission control protocol (it is English: Transmission Control Protocol, abbreviation: TCP) type message, TCP type message includes specific second end slogan, Specific second end slogan is bandwidth request message for forwarding device identification TCP type message.
First bandwidth request message is packaged in IP data packet, and the source IP address of IP data packet is the IP of source equipment Address, the purpose IP address of IP data packet are the IP address of purpose end equipment.In detection source end equipment between purpose end equipment Bandwidth when, first bandwidth request message that source equipment is sent, the value of ttl field is 1, source equipment send second A bandwidth request message, the value of ttl field are 2, successively plus one, until source equipment receives the bandwidth response of purpose end equipment Message.The embodiment of the present invention is not intended to limit the first bandwidth request message is which bandwidth request message that source equipment is sent.
S102, source equipment receive the bandwidth response message that forwarding device is sent.
Bandwidth response message is also packaged in IP data packet, bandwidth response message include forwarding device IP address and Bandwidth, bandwidth of the bandwidth between forwarding device and the next-hop forwarding device of forwarding device.
Specifically, the next-hop forwarding device of forwarding device refers to can find down from the routing table of forwarding device One jumps forwarding device, is stored between forwarding device and the next-hop forwarding device of forwarding device in the routing table of forwarding device Bandwidth.
Bandwidth response message can be UDP type message or internet control message protocol (English: Internet Control Message Protocol, abbreviation: ICMP) type message.Bandwidth response message can also be other type of messages, Such as TCP type message.
If bandwidth response message is UDP type message, the bandwidth carried in bandwidth response message is forwarding device and forwarding Bandwidth between all next-hop forwarding devices of equipment.Since the byte number of UDP type message payload is more, it is set in forwarding In the case that standby next-hop includes multiple forwarding devices, forwarding device and forwarding can be carried in UDP type bandwidth response message Bandwidth in the next-hop of equipment between each forwarding device.Wherein, UDP type message further includes specific third port number, specific Third port number for source equipment identification UDP type message be bandwidth response message.
If bandwidth response message is ICMP type message, the bandwidth carried in bandwidth response message is forwarding device and forwarding Bandwidth between any one next-hop forwarding device of equipment.Due to the limitation of ICMP type message payload, ICMP type bandwidth response Message can only carry the bandwidth between forwarding device and any one next-hop forwarding device of forwarding device.Wherein, TCP type message Including specific 4th port numbers, specific 4th port numbers are bandwidth response message for source equipment identification TCP type message.
Illustratively, it is assumed that the next-hop forwarding device recorded in the routing table of forwarding device A, A is B, C and D, if band Wide response message is UDP type message, then in the bandwidth response message that forwarding device A is sent the bandwidth that carries be forwarding device A to B, the bandwidth of A to C and A to D;If bandwidth response message is ICMP type message, the bandwidth carried in bandwidth response message is to turn Send out the bandwidth of equipment A to B perhaps A to C or A to D.
S103, source equipment memory bandwidth, and generate the second bandwidth request message.
The value of the life span TTL of second bandwidth request message is bigger by one than the value of the TTL of the first bandwidth request message.
Further, bandwidth request message (refers specifically to the first bandwidth request message and the second band in embodiments of the present invention Wide request message) be UDP type message, which includes specific first end slogan, and specific first end slogan is used for Forwarding device identifies that UDP type message is bandwidth request message or bandwidth request message is TCP type message, and TCP type message includes Specific second end slogan, the specific second end slogan are bandwidth request message for forwarding device identification TCP type message. If bandwidth response message is UDP type message, UDP type message includes specific third port number, specific third port number with Identify that UDP type message is bandwidth response message in source equipment;If bandwidth response message is TCP type message, TCP type message packet Specific 4th port numbers are included, specific 4th port numbers are bandwidth response message for source equipment identification TCP type message.
In embodiments of the present invention, specific first end slogan, specific second end slogan, specific third port number and Specific 4th port numbers are that source equipment and forwarding device are preset, and UDP type message is bandwidth request report for identification Text or bandwidth response message, the specific port numbers can be any one reserved port numbers, so-called reserved any one A port numbers refer to be normally applied program need not port numbers.Illustratively, can preset first end slogan is 30000, when forwarding device receives the UDP type message that port numbers are 30000, so that it may determine that the message is bandwidth request report Text, can also preset third port number is 30001, when source equipment receives the UDP type message that port numbers are 30001, It is assured that the message is bandwidth response message.
First end slogan and third port number can be set as identical port numbers, also can be set as different ports Number;Second end slogan and the 4th port numbers can be set as identical port numbers, also can be set as different port numbers.Due to The end of first end slogan and/or third port number and the message that second end slogan and/or the 4th port numbers are different agreement type Slogan, therefore they cannot be identical port numbers.
You need to add is that can be the mark (English in icmp packet if bandwidth response message is ICMP type message Text: code) one new value of field definition is bandwidth response message for identifying the icmp packet.
Specifically, if it is purpose end equipment that source equipment, which judges forwarding device not, source equipment memory bandwidth, and generate Second bandwidth request message, the value of the value of the life span TTL of the second bandwidth request message than the TTL of the first bandwidth request message It is big by one.
Illustratively, if the IP address of forwarding device is different from the IP address of purpose end equipment, source equipment is judged Forwarding device is not purpose end equipment, to obtain the bandwidth in the bandwidth response message of forwarding device return, and stores the band It is wide.Then the second bandwidth request message is generated, the TTL of the value of the TTL of the second bandwidth request message than the first bandwidth request message Value it is big by one.
After source equipment generates the second bandwidth request message, the second bandwidth request message is carried out and the first bandwidth request report The identical operation of text sends the second bandwidth request message (at this point, source equipment sends the second bandwidth request report to forwarding device The process of text is identical as step S101, i.e., the second bandwidth request message at this time is equal to the first bandwidth request report in S101 Text).After source equipment sends the second bandwidth request message, if the received bandwidth response message of source equipment is not also that destination is set The bandwidth response message that preparation is sent, then source equipment continues to generate third bandwidth request message, the TTL of third bandwidth request message Value it is bigger by one than the value of the TTL of the second bandwidth request message, and to forwarding device send third bandwidth request message, so follow Ring, until source equipment receives the bandwidth response message of purpose end equipment transmission.
Again specifically, source equipment obtains purpose end equipment if source equipment judges that forwarding device is purpose end equipment With the bandwidth of source equipment room.
Illustratively, when the IP address of forwarding device is identical as the IP address of purpose end equipment, then source equipment judges The forwarding device is purpose end equipment out.So far, source equipment has been got between source equipment and purpose end equipment Each bandwidth jumping forwarding device and returning.
Need to obtain due to source equipment is bandwidth between source equipment and purpose end equipment, and purpose end equipment is sent out The bandwidth carried in the bandwidth response message sent is the band between purpose end equipment and the next-hop forwarding device of purpose end equipment Width, the bandwidth are unnecessary to source equipment.Therefore, optionally, what the bandwidth response message that purpose end equipment is sent carried Bandwidth can be bandwidth or the transmission of purpose end equipment between purpose end equipment and the next-hop forwarding device of purpose end equipment Bandwidth response message can not also carry bandwidth, or set 0 for the bandwidth field in bandwidth response message.
Optionally, each jump forwarding device between the available source equipment of source equipment and purpose end equipment returns Bandwidth, and the smallest bandwidth is chosen as the bandwidth bottleneck on the network link between source equipment and purpose end equipment.To So that the occupied bandwidth of business datum transmitted on network link between the source equipment and purpose end equipment is small as far as possible Minimum bandwidth in this section of chain road, the probability to malfunction when reducing business data transmission.
The present invention provides a kind of method of detection bandwidth, sends the first bandwidth request report to forwarding device by source equipment Text carrys out the bandwidth between detection source end equipment and purpose end equipment, and source equipment receives the bandwidth response report that forwarding device is sent Text.When forwarding device is not purpose end equipment, bandwidth in source equipment memory bandwidth response message, and generate the second bandwidth The value of request message, the TTL of the second bandwidth request message is bigger by one than the value of the TTL of the first bandwidth request message;Work as forwarding device When being exactly purpose end equipment, source equipment obtains the bandwidth of purpose end equipment and source equipment room.With this solution, due to source Equipment can be that is, logical by the bandwidth of all forwarding devices between bandwidth response Receive message source equipment and purpose end equipment The mode for crossing message transmitting obtains bandwidth between source equipment and purpose end equipment, will not occupy additional bandwidth.Therefore, may be used Extra bandwidth is occupied when solving the problem of through double-end monitor method detection bandwidth, can quick detection bandwidth, and will not shadow Ring normal data transmission on network.
Embodiment two
The embodiment of the present invention provides a kind of method of detection bandwidth, is illustrated in figure 2 the flow diagram of this method, specifically Include:
S201, forwarding device receive the first bandwidth request message that source equipment is sent.
The purpose IP address of first bandwidth request message is the IP address of purpose end equipment, and the first bandwidth request message is When UDP type message, UDP type message includes specific first end slogan, and specific first end slogan identifies UDP for forwarding device When type message is bandwidth request message or the first bandwidth request message is TCP type message, TCP type message includes specific Two-port netwerk number, specific second end slogan is bandwidth request message for forwarding device identification TCP type message, and the first bandwidth is asked The value for seeking TTL in message is one.When the value of TTL in the first bandwidth request message is greater than for the moment, forwarding device asks the first bandwidth Ask the processing of message same as the prior art, i.e., forwarding device subtracts one to the value of TTL in the first bandwidth request message, and to forwarding The next-hop forwarding device of equipment sends the first bandwidth request message.
S202, forwarding device confirm that the first bandwidth is asked according to specific first end slogan or specific second end slogan Seeking message is bandwidth request message.
Bandwidth request message is the message of UDP type, which includes specific first end slogan, specific first Port numbers are bandwidth request message for forwarding device identification UDP type message;Or bandwidth request message is TCP type message, TCP Type message includes specific second end slogan, and specific second end slogan is asked for forwarding device identification TCP type message for bandwidth Seek message.
S203, forwarding device are to source equipment transmission bandwidth response message.
It should be noted that being said since value of the value equal to one, TTL-1 of the TTL of the first bandwidth request message is zero The time-to-live of bright first bandwidth request message is over, and forwarding device will abandon the first bandwidth request message, and to source Equipment transmission bandwidth response message.Wherein, bandwidth response message includes the IP address and bandwidth of forwarding device, and bandwidth is that forwarding is set Bandwidth between the standby next-hop forwarding device with forwarding device.
First bandwidth request message be UDP type message perhaps TCP type message bandwidth response message be UDP type message or ICMP type message;If bandwidth response message is UDP type message, the bandwidth carried in bandwidth response message is forwarding device and turns Send out the bandwidth between each next-hop forwarding device of equipment;If bandwidth response message is ICMP type message, bandwidth response message Bandwidth of the bandwidth of middle carrying between forwarding device and any one next-hop forwarding device of forwarding device, specifically, with reality Apply identical described in example one, details are not described herein.
If bandwidth response message is UDP type message, UDP type message further includes specific second end slogan, specific the Two-port netwerk number is bandwidth response message for source equipment identification UDP type message;If bandwidth response message is TCP type message, TCP type message includes specific 4th port numbers, and specific 4th port numbers are bandwidth for source equipment identification TCP type message Response message.
In embodiments of the present invention, specific first end slogan, specific second end slogan, specific third port number and Specific 4th port numbers are that source equipment and forwarding device are preset, and UDP type message and TCP type message are for identification Bandwidth request message or bandwidth response message, which can be any one reserved port numbers, so-called pre- Any one port numbers stayed refer to be normally applied program need not port numbers.Illustratively, first end can be preset Slogan is 30000, when forwarding device receives the UDP type message that port numbers are 30000, so that it may determine that the message is asked for bandwidth Message is sought, can also preset third port number is 30001, when source equipment receives the UDP type message that port numbers are 30001 When, so that it may determine that the message is bandwidth response message.
Specific first end slogan and specific third port number can be set as identical port numbers, also can be set as Different port numbers;Specific second end slogan and specific 4th port numbers can be set as identical port numbers, can also be with It is set as different port numbers.Since first end slogan and/or third port number are with second end slogan and/or the 4th port numbers The port numbers of the message of different agreement type, therefore they cannot be identical port numbers.
You need to add is that can be the mark (English in icmp packet if bandwidth response message is ICMP type message Text: code) one new value of field definition is bandwidth response message for identifying the icmp packet.
Illustratively, in network link as shown in Figure 3, source equipment is A, and purpose end equipment is D, this sentences source Equipment, forwarding device are all router and bandwidth request message and bandwidth response message is all that UDP type message is illustrated.
Bandwidth request message and bandwidth response message all include head and payload.It include source IP address in the IP head of message, Purpose IP address and TTL.It further include specific source port number and destination port in UDP if message is UDP type message Number, wherein the payload of bandwidth request message and bandwidth response message newly defines.
Illustratively, the format of the payload of the bandwidth request message of UDP type is as shown in table 1:
Table 1
Wherein, the type field is set as 1, indicates that the message is bandwidth request message, specifically in the present embodiment, the bandwidth Request message is the first bandwidth request message and the second bandwidth request message.Code field is used to indicate the band of router A request Wide type, if Code field is 0, what router A was requested is the bandwidth of forward path;If Code field is 1, router A What is requested is the bandwidth of reverse path, wherein the bandwidth of forward path refers to the bandwidth by source equipment to purpose end equipment, The bandwidth of reverse path refers to the bandwidth by purpose end equipment to source equipment, the generally feelings in the routing symmetry of network link Under condition, the bandwidth of forward path and the bandwidth of reverse path are identical.Reserved field is reserved field, is usually arranged as 0.Unused field temporarily without limitation, can extend for follow-up business and be used, be usually arranged as 0.
When bandwidth response message is UDP type message, the format of the payload of UDP type message is as shown in table 2:
Table 2
Wherein, the type field is set as 2, indicates that the message is bandwidth response message.Code field is for indicating router A The bandwidth types of request, if Code field is 0, what router A was requested is the bandwidth of forward path;If Code field is 1, What router A was requested is the bandwidth of reverse path.Out Interface Number field indicates the next-hop routing of router The number of device.Reserved field is reserved field, is usually arranged as 0.
Optionally, Port ID1-Port IDn field is outgoing interface device numbering, when the next-hop of router has multiple set When standby, they can be numbered, outgoing interface number field occupies two bytes as can be seen from Table 2, than directly returning The IP address for returning multiple next-hop outgoing interfaces saves data space.Specifically, in the present embodiment, outgoing interface equipment is exactly to turn Send out the next hop router of equipment.Utilization field be outgoing interface bandwidth availability ratio, value range be 0 to 100 it Between, indicate the bandwidth availability ratio of some outgoing interface, i.e., the bandwidth that business datum occupies the outgoing interface accounts for the outgoing interface band width in physical Ratio.Bandwidth Size field is amount of bandwidth, indicates some outgoing interface band width in physical.
In the present embodiment, source IP address is the IP address of router A, and purpose IP address is the IP address of router D, Code field is 0, and source port number and destination slogan are both configured to 30000.
Specific bandwidth detection process is as follows:
Router A sends the first bandwidth request message of TTL=1 to router B, and router B receives router A transmission After first bandwidth request message, the value of TTL is subtracted one, finds TTL-1=0, and judge that purpose IP address is not local IP address; Due to TTL-1=0, so router B abandons the message and searches routing table, the bandwidth of all next hop routers is obtained, is sealed Router A is sent in bandwidth response message.
After router A receives the bandwidth response message of router B transmission, judges the IP address of router B, it is found that it is not Purpose end equipment, then store router B IP address and router B to each next hop router bandwidth;Then road The first bandwidth request message of TTL=2 is sent from device A to router B.
After router B receives the first bandwidth request message of router A transmission, subtract one to the value of TTL, discovery TTL-1 is not It is 0, routing table is then searched according to the purpose IP address in the first bandwidth request message, determines its next hop router C, and will First bandwidth request message is transmitted to next hop router C.
After router C receives the first bandwidth request message of router B transmission, subtract one to the value of TTL, finds TTL-1= 0, and judge that purpose IP address is not local IP address;Due to TTL-1=0, so router C abandons the message, and road is searched By table, the bandwidth of all next-hop outgoing interfaces is obtained, is encapsulated in bandwidth response message, router A is sent to.
After router A receives the bandwidth response message of router C transmission, judges the IP address of router C, it is found that it is not Purpose end equipment, then store router C IP address and router C to each next hop router bandwidth;Then road The first bandwidth request message of TTL=3 is sent from device A to router B.
After router B receives the first bandwidth request message of router A transmission, subtract one to the value of TTL, at this time TTL=2, It is not 0, routing table is then searched according to the purpose IP address in the first bandwidth request message, determines its next hop router C, And the first bandwidth request message is sent to next hop router C.
After router C receives the first bandwidth request message of router B transmission, subtract one to the value of TTL, at this time TTL=1, It is not 0, routing table is then searched according to the purpose IP address in the first bandwidth request message, determines its next hop router D, And the first bandwidth request message is sent to next hop router D.
After router D receives the first bandwidth request message of router C transmission, subtract one to the value of TTL, find TTL=0, And judge that purpose IP address is exactly local IP address;Due to TTL=0, so router D abandons the message, and routing table is searched, The bandwidth for obtaining all next-hop outgoing interfaces, is encapsulated in bandwidth response message, is sent to router A.
After router A receives the bandwidth response message of purpose end equipment router D transmission, it is found that the bandwidth response message is What purpose end equipment was sent, then judge that the first bandwidth request message has arrived at purpose end equipment, then stops sending first band Wide request message.So far, router A obtains all bandwidth on the network link between router A and router D, thus The bandwidth bottleneck on network link can be judged according to each bandwidth for jumping forwarding device.
Again illustrative, in network link as shown in Figure 3, source equipment is A, and purpose end equipment is D, this sentences source End equipment, forwarding device are all router and bandwidth request message is UDP type message, bandwidth response message be ICMP type message into Row explanation.
Bandwidth request message and bandwidth response message all include head and payload, include source IP address in head, destination IP Location and TTL.The bandwidth response message of ICMP type is also packaged in IP data packet, wherein UDP type bandwidth request message with it is upper State identical described in embodiment, the payload of ICMP type bandwidth response message newly defines.
Illustratively, the format of the payload of the bandwidth response message of ICMP type is as shown in table 3:
Table 3
Wherein, the type field indicates the type of ICMP timeout packet, identical as the type field in existing icmp packet. Code field indicates the type code of ICMP timeout packet, and in the prior art, Code=0 indicates that life cycle is during transmission 0, Code=1 indicates that life cycle is 0 during datagram assembling, and the present invention defines raw during Code=2 expression obtains bandwidth Cycle of deposit is 0, therefore, in embodiments of the present invention, Code=2.Bandwidth Size field is amount of bandwidth, indicates routing Bandwidth between device and any one next hop router.
In the present embodiment, source IP address is the IP address of router A, and purpose IP address is the IP address of router D.
The specific bandwidth detection process and the source equipment of above-described embodiment, forwarding device of the present embodiment are all router And bandwidth response message is identical for the detection process of UDP type message, difference is that the bandwidth response message of the present embodiment is ICMP Type message, the bandwidth carried in bandwidth response message are the bandwidth between router and any one next hop router, and It is not the bandwidth that the bandwidth carried as UDP type bandwidth response message is some router Yu its each next hop router.
Preferably, the bandwidth that ICMP type message returns can be the most small band between router and all next hop routers It is wide.
The present invention provides a kind of method of detection bandwidth, receives source equipment by forwarding device and sends the first bandwidth request Message, and to source equipment transmission bandwidth response message, wherein bandwidth response message includes the IP address and band of forwarding device Width, bandwidth of the bandwidth between forwarding device and the next-hop forwarding device of forwarding device.With this solution, due to forwarding device energy Enough to source equipment transmission bandwidth response message, so that source equipment passes through bandwidth response Receive message source equipment to destination The bandwidth of all forwarding devices between equipment obtains between source equipment and purpose end equipment in such a way that message transmits Bandwidth, additional bandwidth will not be occupied.Therefore, when can solve through double-end monitor method detection bandwidth, extra band is occupied Wide problem, can quick detection bandwidth, and will not influence normal data transmission on network.
Embodiment three
The embodiment of the present invention provides a kind of source equipment, is illustrated in figure 4 the structural schematic diagram of the source equipment, comprising:
Sending module 10, for sending the first bandwidth request message, the purpose of the first bandwidth request message to forwarding device IP address is the IP address of purpose end equipment.
Receiving module 11, for receiving the bandwidth response message of forwarding device transmission, wherein bandwidth response message includes turning Send out the IP address and bandwidth of equipment, bandwidth of the bandwidth between forwarding device and the next-hop forwarding device of forwarding device.
Execution module 12 is used for memory bandwidth, and generates the second bandwidth request message, the TTL of the second bandwidth request message Value it is bigger by one than the value of the TTL of the first bandwidth request message.
It should be noted that the first bandwidth request message and the second bandwidth request message are UDP type message, UDP type message Including specific first end slogan, specific first end slogan is bandwidth request message for forwarding device identification UDP type message, Or first bandwidth request message and the second bandwidth request message be TCP type message, TCP type message includes specific second port Number, specific second end slogan is bandwidth request message for forwarding device identification TCP type message.
If bandwidth response message is UDP type message, UDP type message includes specific third port number, specific third Port numbers are bandwidth response message for source equipment identification UDP type message;If bandwidth response message is TCP type message, TCP Type message includes specific 4th port numbers, and specific 4th port numbers are rung for source equipment identification TCP type message for bandwidth Answer message.
The embodiment of the present invention provides a kind of source equipment, which sends the first bandwidth request message to forwarding device Carry out the bandwidth between detection source end equipment and purpose end equipment, which receives the bandwidth response report that forwarding device is sent Text judges whether the forwarding device is purpose end equipment.When forwarding device is not purpose end equipment, the source equipment storage tape Bandwidth in wide response message, and the second bandwidth request message is generated, the value of the TTL of the second bandwidth request message is than the first bandwidth The value of the TTL of request message is big by one;When forwarding device is purpose end equipment, which obtains purpose end equipment and source The bandwidth of equipment room.With this solution, since source equipment can pass through bandwidth response Receive message source equipment to destination The bandwidth of all forwarding devices between equipment obtains between source equipment and purpose end equipment in such a way that message transmits Bandwidth, additional bandwidth will not be occupied.Therefore, when can solve through double-end monitor method detection bandwidth, extra band is occupied Wide problem, and can quick detection bandwidth, and will not influence normal data transmission on network.
Example IV
The embodiment of the present invention provides a kind of forwarding device, is illustrated in figure 5 the structural schematic diagram of the forwarding device, comprising:
Receiving module 20, for receiving the first bandwidth request message of source equipment transmission, the first bandwidth request message IP address is the IP address of purpose end equipment, and the value of the TTL of the first bandwidth request message is equal to one, the first bandwidth request message packet Include specific first end slogan or specific second end slogan.
When first bandwidth request message is UDP type message, UDP type message includes specific first end slogan, and specific the One end slogan is bandwidth request message for forwarding device identification UDP type message or the first bandwidth request message is TCP type report Wen Shi, TCP type message include specific second end slogan, and specific second end slogan identifies TCP type message for forwarding device For bandwidth request message.
Confirmation module 21, for confirming the first bandwidth according to specific first end slogan or specific second end slogan Request message is bandwidth request message.
Sending module 22 is used for source equipment transmission bandwidth response message, wherein bandwidth response message includes that forwarding is set Standby IP address and bandwidth, bandwidth of the bandwidth between forwarding device and the next-hop forwarding device of forwarding device.
It should be noted that if bandwidth response message is UDP type message, then UDP type message includes specific third port Number, specific third port number is bandwidth response message for source equipment identification UDP type message;If bandwidth response message is TCP type message, then TCP type message includes specific 4th port numbers, and specific 4th port numbers identify TCP for source equipment Type message is bandwidth response message.
A kind of forwarding device provided in an embodiment of the present invention, the forwarding device receive the first bandwidth that source equipment is sent and ask Seek message, and to source equipment transmission bandwidth response message, wherein bandwidth response message includes the IP address and band of forwarding device Width, bandwidth of the bandwidth between forwarding device and the next-hop forwarding device of forwarding device.With this solution, due to forwarding device energy Enough to source equipment transmission bandwidth response message, so that source equipment passes through bandwidth response Receive message source equipment to destination The bandwidth of all forwarding devices between equipment obtains between source equipment and purpose end equipment in such a way that message transmits Bandwidth, additional bandwidth will not be occupied.Therefore, when can solve through double-end monitor method detection bandwidth, extra band is occupied Wide problem, and can quick detection bandwidth, and will not influence normal data transmission on network.
Embodiment five
As shown in fig. 6, the embodiment of the present invention provides a kind of source equipment, which may include: 30 He of processor Communication interface 31.
Processor 30 can be central processing unit (English: central processing unit, abbreviation: CPU) or network Processor (English: network processor, abbreviation: NP).
If processor 30 is CPU, which further includes memory 32, for storing program code, and by the journey Sequence code transfer gives the processor 30, and processor 30 is executed instruction according to program code.Memory 32 may include that volatibility is deposited Reservoir (English: volatile memory), such as random access memory (English: random-access memory, abbreviation: RAM);Memory 32 also may include nonvolatile memory (English: non-volatile memory), such as read-only storage Device (English: read-only memory, abbreviation: ROM), flash memory (English: flash memory), hard disk (English: Hard disk drive, abbreviation: HDD) or solid state hard disk (English: solid-state drive, abbreviation: SSD);Memory 32 It can also include the combination of the memory of mentioned kind.It is total by system between processor 30, memory 32 and communication interface 31 Line 33 connects and completes mutual communication.
Communication interface 31 can be by optical transceiver, electric transceiver, wireless transceiver or any combination thereof realization.For example, light Transceiver can be Small Form-Factor Pluggable (English: small form-factor pluggable transceiver, abbreviation: SFP) transceiver (English: transceiver), enhancing Small Form-Factor Pluggable (English: enhanced small form-factor Pluggable, abbreviation: SFP+) transceiver or 10 gigabit Small Form-Factor Pluggables (English: 10 Gigabit small form- Factor pluggable, abbreviation: XFP) transceiver.Electric transceiver can be Ethernet (English: Ethernet) network interface Controller (English: network interface controller, abbreviation: NIC).Wireless transceiver can be wireless network and connect Mouth controller (English: wireless network interface controller, abbreviation: WNIC).
Specifically, the processor 30, for sending the first bandwidth request message to forwarding device by communication interface 31, The purpose IP address of first bandwidth request message is the IP address of purpose end equipment.The processor 30, is also used to pass through communication Interface 31 receive forwarding device send bandwidth response message, wherein bandwidth response message include forwarding device IP address and Bandwidth, bandwidth of the bandwidth between forwarding device and the next-hop forwarding device of forwarding device;The processor 30, is also used to obtain The bandwidth of purpose end equipment and source equipment room;The processor 30 is also used to for bandwidth being stored in memory 32, and generates The value of second bandwidth request message, the TTL of the second bandwidth request message is bigger by one than the value of the TTL of the first bandwidth request message.
The bandwidth and control processor 30 that the memory 32 is used in memory bandwidth response message complete the above process Software program, so that processor 30 completes the above process by executing the software program.
It should be noted that the first bandwidth request message and the second bandwidth request message are User Datagram Protocol UDP type Message, UDP type message include specific first end slogan, and specific first end slogan identifies UDP type message for forwarding device It is transmission control protocol TCP type message for bandwidth request message or the first bandwidth request message and the second bandwidth request message, TCP type message includes specific second end slogan, and specific second end slogan is bandwidth for forwarding device identification TCP type message Request message.
If bandwidth response message is UDP type message, UDP type message includes specific third port number, specific third Port numbers are bandwidth response message for source equipment identification UDP type message;If bandwidth response message is TCP type message, TCP Type message includes specific 4th port numbers, and specific 4th port numbers are rung for source equipment identification TCP type message for bandwidth Answer message.
A kind of source equipment provided in an embodiment of the present invention sends the first bandwidth request to forwarding device by source equipment Message carrys out the bandwidth between detection source end equipment and purpose end equipment, and source equipment receives the bandwidth response report that forwarding device is sent Text judges whether the forwarding device is purpose end equipment.When forwarding device is not purpose end equipment, source equipment memory bandwidth Bandwidth in response message, and the second bandwidth request message is generated, the value of the TTL of the second bandwidth request message is asked than the first bandwidth Ask the value of the TTL of message big by one;When forwarding device is purpose end equipment, source equipment obtains purpose end equipment and source equipment Between bandwidth.With this solution, since source equipment can pass through bandwidth response Receive message source equipment to purpose end equipment Between all forwarding devices bandwidth, i.e., obtain band between source equipment and purpose end equipment in such a way that message transmits Width will not occupy additional bandwidth.Therefore, when can solve through double-end monitor method detection bandwidth, extra bandwidth is occupied Problem, and can quick detection bandwidth, and will not influence normal data transmission on network.
Embodiment six
As shown in fig. 7, the embodiment of the present invention provides a kind of forwarding device, which may include: 40 He of processor Communication interface 41.
Processor 40 can be CPU or NP.
If processor 40 is CPU, which further includes memory 42 and hardware chip 43.Wherein, memory 42 are transferred to the processor 40 for storing program code, and by the program code, and processor 40 refers to according to program code execution It enables.Memory 42 may include volatile memory, such as RAM;Memory 42 also may include nonvolatile memory, such as ROM, flash memory, HDD or SSD;Memory 42 can also include the combination of the memory of mentioned kind.Processor 40 is deposited It connects by system bus 43 between reservoir 42 and communication interface 41 and completes mutual communication.
Communication interface 41 can be by optical transceiver, electric transceiver, wireless transceiver or any combination thereof realization.For example, light Transceiver can be SFP transceiver, SFP+ transceiver or XFP transceiver.Electric transceiver can be Ethernet NIC.Wireless receiving and dispatching Device can be WNIC.
Specifically, hardware chip 43 is used to receive the first bandwidth request report that source equipment is sent by communication interface 41 Text, the purpose IP address of the first bandwidth request message are the IP address of purpose end equipment, and according to the first bandwidth request message Port numbers confirm that the first bandwidth request message is bandwidth request message, when the value of the TTL of the first bandwidth request message is not equal to For the moment, 43 down hop forwarding device of hardware chip forwards the bandwidth request message, when the value of the TTL of the first bandwidth request message Equal to for the moment, hardware chip 43 forwards the bandwidth request message to CPU;Processor 40 is also used to as TTL-1=0, by logical Believe interface 42 to source equipment transmission bandwidth response message, wherein bandwidth response message includes the IP address and band of forwarding device Width, bandwidth of the bandwidth between forwarding device and the next-hop forwarding device of forwarding device.
It should be noted that the first bandwidth request message is User Datagram Protocol UDP type message, the UDP type message Including the specific first end slogan, the specific first end slogan identifies the UDP type report for the forwarding device Text is bandwidth request message or the first bandwidth request message is transmission control protocol TCP type message, the TCP type report Text includes the specific second end slogan, and the specific second end slogan identifies the TCP type for the forwarding device Message is bandwidth request message.
It should be noted that if bandwidth response message is UDP type message, then UDP type message includes specific third port Number, specific third port number is bandwidth response message for source equipment identification UDP type message;If bandwidth response message is TCP type message, then TCP type message includes specific 4th port numbers, and specific 4th port numbers identify TCP for source equipment Type message is bandwidth response message.
When the forwarding device includes NP, NP can complete CPU, memory and hardware chip in the present embodiment all Function, details are not described herein.
A kind of forwarding device provided in an embodiment of the present invention receives the first bandwidth that source equipment is sent by forwarding device Request message, and to source equipment transmission bandwidth response message, wherein bandwidth response message include forwarding device IP address and Bandwidth, bandwidth of the bandwidth between forwarding device and the next-hop forwarding device of forwarding device.With this solution, due to forwarding device It can be to source equipment transmission bandwidth response message, so that source equipment passes through bandwidth response Receive message source equipment to purpose The bandwidth of all forwarding devices between end equipment, i.e., obtained in such a way that message transmits source equipment and purpose end equipment it Between bandwidth, additional bandwidth will not be occupied.Therefore, it when can solve through double-end monitor method detection bandwidth, occupies additional The problem of bandwidth, and can quick detection bandwidth, and will not influence normal data transmission on network.
Embodiment seven
The embodiment of the present invention provides a kind of system of detection bandwidth.
Specifically, the system of the detection bandwidth includes the source equipment as described in embodiment three and multiple such as example IVs Described in forwarding device or the detection bandwidth system include the source equipment as described in embodiment five and it is multiple strictly according to the facts Apply forwarding device described in example six.
Illustratively, the networking mode of the system of the detection bandwidth can be as shown in Figure 8.
A kind of system of detection bandwidth provided in an embodiment of the present invention sends first band to forwarding device by source equipment Wide request message, and the bandwidth response message of forwarding device transmission is received, when forwarding device is not purpose end equipment, source is set Bandwidth in standby memory bandwidth response message, and generate the second bandwidth request message, the value ratio of the TTL of the second bandwidth request message The value of the TTL of first bandwidth request message is big by one;When forwarding device when purpose end equipment, source equipment obtains purpose end equipment With the bandwidth of source equipment room.With this solution, since source equipment can be arrived by bandwidth response Receive message source equipment The bandwidth of all forwarding devices between purpose end equipment obtains source equipment in such a way that message transmits and sets with destination Bandwidth between standby, will not occupy additional bandwidth.Therefore, it when can solve through double-end monitor method detection bandwidth, occupies The problem of extra bandwidth, and can quick detection bandwidth, and will not influence normal data transmission on network.
Finally, it should be noted that the above embodiments are merely illustrative of the technical solutions of the present invention, rather than its limitations;Although Present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that: it still may be used To modify the technical solutions described in the foregoing embodiments or equivalent replacement of some of the technical features; And these are modified or replaceed, and so that corresponding technical solution is departed from the scope of the technical solutions of the embodiments of the present invention.

Claims (9)

1.一种检测带宽的方法,其特征在于,包括:1. a method for detecting bandwidth, is characterized in that, comprises: 源端设备向转发设备发送第一带宽请求报文,所述第一带宽请求报文的目的因特网协议IP地址为目的端设备的IP地址;The source end device sends a first bandwidth request message to the forwarding device, and the destination Internet Protocol IP address of the first bandwidth request message is the IP address of the destination end device; 所述源端设备接收所述转发设备发送的带宽响应报文,其中,所述带宽响应报文包括所述转发设备的IP地址和带宽大小字段,所述带宽大小字段为带宽大小,所述带宽大小用于表示所述转发设备与所述转发设备的下一跳转发设备间的带宽;The source device receives a bandwidth response packet sent by the forwarding device, where the bandwidth response packet includes the IP address of the forwarding device and a bandwidth size field, where the bandwidth size field is the bandwidth size, and the bandwidth The size is used to represent the bandwidth between the forwarding device and the next-hop forwarding device of the forwarding device; 所述源端设备存储所述带宽大小,并生成第二带宽请求报文,所述第二带宽请求报文的生存时间TTL的值比所述第一带宽请求报文的TTL的值大一。The source device stores the bandwidth size, and generates a second bandwidth request packet, where the time-to-live TTL value of the second bandwidth request packet is one greater than the TTL value of the first bandwidth request packet. 2.根据权利要求1所述的检测带宽的方法,其特征在于,2. the method for detecting bandwidth according to claim 1, is characterized in that, 所述第一带宽请求报文和所述第二带宽请求报文为用户数据报协议UDP型报文,所述UDP型报文包括特定的第一端口号,所述特定的第一端口号用于所述转发设备识别所述UDP型报文为带宽请求报文,或者所述第一带宽请求报文和所述第二带宽请求报文为传输控制协议TCP型报文,所述TCP型报文包括特定的第二端口号,所述特定的第二端口号用于所述转发设备识别所述TCP型报文为带宽请求报文;The first bandwidth request message and the second bandwidth request message are User Datagram Protocol UDP-type messages, and the UDP-type message includes a specific first port number, and the specific first port number is used Because the forwarding device identifies that the UDP-type message is a bandwidth request message, or the first bandwidth request message and the second bandwidth request message are Transmission Control Protocol TCP-type messages, the TCP-type message The file includes a specific second port number, and the specific second port number is used by the forwarding device to identify the TCP type message as a bandwidth request message; 若所述带宽响应报文为UDP型报文,则所述UDP型报文包括特定的第三端口号,所述特定的第三端口号用于所述源端设备识别所述UDP型报文为带宽响应报文;If the bandwidth response message is a UDP-type message, the UDP-type message includes a specific third port number, and the specific third port number is used by the source device to identify the UDP-type message is the bandwidth response message; 若所述带宽响应报文为TCP型报文,则所述TCP型报文包括特定的第四端口号,所述特定的第四端口号用于所述源端设备识别所述TCP型报文为带宽响应报文。If the bandwidth response message is a TCP-type message, the TCP-type message includes a specific fourth port number, and the specific fourth port number is used for the source device to identify the TCP-type message It is the bandwidth response message. 3.一种检测带宽的方法,其特征在于,包括:3. A method for detecting bandwidth, comprising: 转发设备接收源端设备发送的第一带宽请求报文,所述第一带宽请求报文的目的因特网协议IP地址为目的端设备的IP地址,所述第一带宽请求报文的生存时间TTL的值等于一,所述第一带宽请求报文包括特定的第一端口号或者特定的第二端口号;The forwarding device receives the first bandwidth request message sent by the source end device, the destination IP address of the first bandwidth request message is the IP address of the destination end device, and the time-to-live of the first bandwidth request message is TTL The value is equal to one, and the first bandwidth request packet includes a specific first port number or a specific second port number; 所述转发设备根据所述特定的第一端口号或者所述特定的第二端口号,确认所述第一带宽请求报文为带宽请求报文;The forwarding device confirms that the first bandwidth request packet is a bandwidth request packet according to the specific first port number or the specific second port number; 所述转发设备向所述源端设备发送带宽响应报文,其中,所述带宽响应报文包括所述转发设备的IP地址和带宽大小字段,所述带宽大小字段为带宽大小,所述带宽大小用于表示所述转发设备与所述转发设备的下一跳转发设备间的带宽。The forwarding device sends a bandwidth response message to the source device, where the bandwidth response message includes the IP address of the forwarding device and a bandwidth size field, where the bandwidth size field is a bandwidth size, and the bandwidth size It is used to indicate the bandwidth between the forwarding device and the next-hop forwarding device of the forwarding device. 4.根据权利要求3所述的检测带宽的方法,其特征在于,4. The method for detecting bandwidth according to claim 3, wherein, 所述第一带宽请求报文为用户数据报协议UDP型报文,所述UDP型报文包括所述特定的第一端口号,所述特定的第一端口号用于所述转发设备识别所述UDP型报文为带宽请求报文,或者所述第一带宽请求报文为传输控制协议TCP型报文,所述TCP型报文包括所述特定的第二端口号,所述特定的第二端口号用于所述转发设备识别所述TCP型报文为带宽请求报文;The first bandwidth request message is a User Datagram Protocol UDP-type message, and the UDP-type message includes the specific first port number, and the specific first port number is used by the forwarding device to identify the The UDP-type message is a bandwidth request message, or the first bandwidth request message is a transmission control protocol TCP-type message, and the TCP-type message includes the specific second port number, the specific first port number. The two port numbers are used by the forwarding device to identify the TCP-type message as a bandwidth request message; 若所述带宽响应报文为UDP型报文,则所述UDP型报文包括特定的第三端口号,所述特定的第三端口号用于所述源端设备识别所述UDP型报文为带宽响应报文;If the bandwidth response message is a UDP-type message, the UDP-type message includes a specific third port number, and the specific third port number is used by the source device to identify the UDP-type message is the bandwidth response message; 若所述带宽响应报文为TCP型报文,则所述TCP型报文包括特定的第四端口号,所述特定的第四端口号用于所述源端设备识别所述TCP型报文为带宽响应报文。If the bandwidth response message is a TCP-type message, the TCP-type message includes a specific fourth port number, and the specific fourth port number is used for the source device to identify the TCP-type message It is the bandwidth response message. 5.一种源端设备,其特征在于,包括:5. A source device, comprising: 发送模块,用于向转发设备发送第一带宽请求报文,所述第一带宽请求报文的目的因特网协议IP地址为目的端设备的IP地址;A sending module, configured to send a first bandwidth request message to the forwarding device, where the destination Internet Protocol IP address of the first bandwidth request message is the IP address of the destination device; 接收模块,用于接收所述转发设备发送的带宽响应报文,其中,所述带宽响应报文包括所述转发设备的IP地址和带宽大小字段,所述带宽大小字段为带宽大小,所述带宽大小用于表示所述转发设备与所述转发设备的下一跳转发设备间的带宽;A receiving module, configured to receive a bandwidth response message sent by the forwarding device, wherein the bandwidth response message includes an IP address of the forwarding device and a bandwidth size field, where the bandwidth size field is a bandwidth size, and the bandwidth The size is used to represent the bandwidth between the forwarding device and the next-hop forwarding device of the forwarding device; 执行模块,用于存储所述带宽大小,并生成第二带宽请求报文,所述第二带宽请求报文的生存时间TTL的值比所述第一带宽请求报文的TTL的值大一。An execution module, configured to store the bandwidth size and generate a second bandwidth request message, where the time-to-live TTL value of the second bandwidth request message is one greater than the TTL value of the first bandwidth request message. 6.根据权利要求5所述的源端设备,其特征在于,6. The source device according to claim 5, wherein, 所述第一带宽请求报文和所述第二带宽请求报文为用户数据报协议UDP型报文,所述UDP型报文包括特定的第一端口号,所述特定的第一端口号用于所述转发设备识别所述UDP型报文为带宽请求报文,或者所述第一带宽请求报文和所述第二带宽请求报文为传输控制协议TCP型报文,所述TCP型报文包括特定的第二端口号,所述特定的第二端口号用于所述转发设备识别所述TCP型报文为带宽请求报文;The first bandwidth request message and the second bandwidth request message are User Datagram Protocol UDP-type messages, and the UDP-type message includes a specific first port number, and the specific first port number is used Because the forwarding device identifies that the UDP-type message is a bandwidth request message, or the first bandwidth request message and the second bandwidth request message are Transmission Control Protocol TCP-type messages, the TCP-type message The file includes a specific second port number, and the specific second port number is used by the forwarding device to identify the TCP type message as a bandwidth request message; 若所述带宽响应报文为UDP型报文,则所述UDP型报文包括特定的第三端口号,所述特定的第三端口号用于所述源端设备识别所述UDP型报文为带宽响应报文;If the bandwidth response message is a UDP-type message, the UDP-type message includes a specific third port number, and the specific third port number is used by the source device to identify the UDP-type message is the bandwidth response message; 若所述带宽响应报文为TCP型报文,则所述TCP型报文包括特定的第四端口号,所述特定的第四端口号用于所述源端设备识别所述TCP型报文为带宽响应报文。If the bandwidth response message is a TCP-type message, the TCP-type message includes a specific fourth port number, and the specific fourth port number is used for the source device to identify the TCP-type message It is the bandwidth response message. 7.一种转发设备,其特征在于,包括:7. A forwarding device, characterized in that, comprising: 接收模块,用于接收源端设备发送的第一带宽请求报文,所述第一带宽请求报文的目的因特网协议IP地址为目的端设备的IP地址,所述第一带宽请求报文的生存时间TTL的值等于一,所述第一带宽请求报文包括特定的第一端口号或者特定的第二端口号;A receiving module, configured to receive a first bandwidth request message sent by the source device, the destination Internet Protocol IP address of the first bandwidth request message is the IP address of the destination device, and the existence of the first bandwidth request message The value of the time TTL is equal to one, and the first bandwidth request packet includes a specific first port number or a specific second port number; 确认模块,用于根据所述特定的第一端口号或者所述特定的第二端口号,确认所述第一带宽请求报文为带宽请求报文;A confirmation module, configured to confirm that the first bandwidth request message is a bandwidth request message according to the specific first port number or the specific second port number; 发送模块,用于向所述源端设备发送带宽响应报文,其中,所述带宽响应报文包括所述转发设备的IP地址和带宽大小字段,所述带宽大小字段为带宽大小,所述带宽大小用于表示所述转发设备与所述转发设备的下一跳转发设备间的带宽。A sending module, configured to send a bandwidth response message to the source device, wherein the bandwidth response message includes the IP address of the forwarding device and a bandwidth size field, where the bandwidth size field is a bandwidth size, and the bandwidth The size is used to represent the bandwidth between the forwarding device and the next-hop forwarding device of the forwarding device. 8.根据权利要求7所述的转发设备,其特征在于,8. The forwarding device according to claim 7, wherein, 所述第一带宽请求报文为用户数据报协议UDP型报文,所述UDP型报文包括所述特定的第一端口号,所述特定的第一端口号用于所述转发设备识别所述UDP型报文为带宽请求报文,或者所述第一带宽请求报文为传输控制协议TCP型报文,所述TCP型报文包括所述特定的第二端口号,所述特定的第二端口号用于所述转发设备识别所述TCP型报文为带宽请求报文;The first bandwidth request message is a User Datagram Protocol UDP-type message, and the UDP-type message includes the specific first port number, and the specific first port number is used by the forwarding device to identify the The UDP-type message is a bandwidth request message, or the first bandwidth request message is a transmission control protocol TCP-type message, and the TCP-type message includes the specific second port number, the specific first port number. The two port numbers are used by the forwarding device to identify the TCP-type message as a bandwidth request message; 若所述带宽响应报文为UDP型报文,则所述UDP型报文包括特定的第三端口号,所述特定的第三端口号用于所述源端设备识别所述UDP型报文为带宽响应报文;If the bandwidth response message is a UDP-type message, the UDP-type message includes a specific third port number, and the specific third port number is used by the source device to identify the UDP-type message is the bandwidth response message; 若所述带宽响应报文为TCP型报文,则所述TCP型报文包括特定的第四端口号,所述特定的第四端口号用于所述源端设备识别所述TCP型报文为带宽响应报文。If the bandwidth response message is a TCP-type message, the TCP-type message includes a specific fourth port number, and the specific fourth port number is used for the source device to identify the TCP-type message It is the bandwidth response message. 9.一种检测带宽的系统,其特征在于,包括具有如权利要求5或6所述的源端设备,以及多个如权利要求7或8所述的转发设备。9 . A system for detecting bandwidth, comprising a source device as claimed in claim 5 or 6 and a plurality of forwarding devices as claimed in claim 7 or 8 . 10 .
CN201410596935.0A 2014-10-29 2014-10-29 A kind of method, apparatus and system of detection bandwidth Active CN105634842B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410596935.0A CN105634842B (en) 2014-10-29 2014-10-29 A kind of method, apparatus and system of detection bandwidth

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410596935.0A CN105634842B (en) 2014-10-29 2014-10-29 A kind of method, apparatus and system of detection bandwidth

Publications (2)

Publication Number Publication Date
CN105634842A CN105634842A (en) 2016-06-01
CN105634842B true CN105634842B (en) 2019-01-11

Family

ID=56049376

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410596935.0A Active CN105634842B (en) 2014-10-29 2014-10-29 A kind of method, apparatus and system of detection bandwidth

Country Status (1)

Country Link
CN (1) CN105634842B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109005116B (en) * 2017-06-07 2020-07-24 华为技术有限公司 A message forwarding method and device
CN110493829B (en) * 2019-08-07 2023-05-02 重庆金美通信有限责任公司 WEB interface request self-adaptive feedback method based on wireless link state
CN111835589B (en) * 2020-06-30 2022-07-12 新华三信息安全技术有限公司 Link quality detection method, path selection method and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1770711A (en) * 2005-11-18 2006-05-10 史文勇 Method and system for measuring bottleneck bandwidth and remanent bandwidth
CN1878165A (en) * 2005-06-08 2006-12-13 华为技术有限公司 Method for detecting label switching path connectivity
CN103825775A (en) * 2013-12-31 2014-05-28 广东工业大学 Multi-hop wireless network available bandwidth real-time detection method for adaptively detecting packet length

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2002065661A1 (en) * 2001-02-12 2002-08-22 Maple Optical Systems, Inc. System and method for fast-rerouting of data in a data communication network

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1878165A (en) * 2005-06-08 2006-12-13 华为技术有限公司 Method for detecting label switching path connectivity
CN1770711A (en) * 2005-11-18 2006-05-10 史文勇 Method and system for measuring bottleneck bandwidth and remanent bandwidth
CN103825775A (en) * 2013-12-31 2014-05-28 广东工业大学 Multi-hop wireless network available bandwidth real-time detection method for adaptively detecting packet length

Also Published As

Publication number Publication date
CN105634842A (en) 2016-06-01

Similar Documents

Publication Publication Date Title
CN113691448B (en) SRv6 method for forwarding message in service chain, SFF and SF device
JP6527880B2 (en) System and method for software defined routing of traffic within and between autonomous systems with improved flow routing, scalability and security
US20170195205A1 (en) Method, apparatus, and system for implementing delay measurement
US20170118108A1 (en) Real Time Priority Selection Engine for Improved Burst Tolerance
US9485172B2 (en) Data transmitting device, data transmitting method and non-transitory computer-readable storage medium
US20170201435A1 (en) Switch, controller, system, and link quality detection method
US9548930B1 (en) Method for improving link selection at the borders of SDN and traditional networks
EP3387803A1 (en) Router with optimized statistical functionality
WO2016058245A1 (en) Processing method and apparatus for operation, administration and maintenance (oam) message
EP3065360A1 (en) Traffic cleaning method and device, and computer storage medium
US10009282B2 (en) Self-protecting computer network router with queue resource manager
US9736066B2 (en) Method, apparatus and system for establishing optical bypass
CN111147372B (en) Downlink message sending and forwarding method and device
CN107294743B (en) Network path detection method, controller and network equipment
JP6443864B2 (en) Method, apparatus and system for implementing packet loss detection
EP4344137A2 (en) Fast forwarding re-convergence of switch fabric multi-destination packets triggered by link failures
WO2015184771A1 (en) Method and node device for operation, administration, and maintenance of service function chaining
CN102891803A (en) Congestion processing method and network device
CN105634842B (en) A kind of method, apparatus and system of detection bandwidth
CN105515816A (en) Processing method and apparatus for detection level information
CN104852855A (en) Congestion control method, device and equipment
TWI543567B (en) Device for multipath routing of packets in computer networking and method thereof
US9124524B2 (en) System and method for priority based flow control between nodes
US10270680B2 (en) Avoiding routing interruption during transition to a virtual entity
CN110830373B (en) Method and device for realizing QOS service quality differentiation of service in SDN network

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right

Effective date of registration: 20211202

Address after: 215010 room 704, building 5, No. 556, Changjiang Road, high tech Zone, Suzhou, Jiangsu

Patentee after: SUZHOU YUDESHUI ELECTRICAL TECHNOLOGY Co.,Ltd.

Address before: 518129 Bantian HUAWEI headquarters office building, Longgang District, Guangdong, Shenzhen

Patentee before: HUAWEI TECHNOLOGIES Co.,Ltd.

TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20221228

Address after: No. 8, Xingbo 7th Road, Boxing Economic Development Zone, Boxing County, Binzhou City, Shandong Province, 256599

Patentee after: Shandong Rongzhi Industry Guidance Fund Co.,Ltd.

Address before: 215010 room 704, building 5, No. 556, Changjiang Road, high tech Zone, Suzhou, Jiangsu

Patentee before: SUZHOU YUDESHUI ELECTRICAL TECHNOLOGY Co.,Ltd.

TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20240419

Address after: Room 11607, 16th Floor, Office Building 1, No. 76 Xichuan South Road, Chengxi District, Xining City, Qinghai Province, 810000

Patentee after: Qinghai Yuanteng Electronic Information Technology Co.,Ltd.

Country or region after: China

Address before: No. 8, Xingbo 7th Road, Boxing Economic Development Zone, Boxing County, Binzhou City, Shandong Province, 256599

Patentee before: Shandong Rongzhi Industry Guidance Fund Co.,Ltd.

Country or region before: China

TR01 Transfer of patent right