CN100496022C - Flow control method and apparatus - Google Patents

Flow control method and apparatus Download PDF

Info

Publication number
CN100496022C
CN100496022C CNB2006100783083A CN200610078308A CN100496022C CN 100496022 C CN100496022 C CN 100496022C CN B2006100783083 A CNB2006100783083 A CN B2006100783083A CN 200610078308 A CN200610078308 A CN 200610078308A CN 100496022 C CN100496022 C CN 100496022C
Authority
CN
China
Prior art keywords
flow control
data
control parameter
packet
priority
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.)
Expired - Fee Related
Application number
CNB2006100783083A
Other languages
Chinese (zh)
Other versions
CN1968192A (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.)
Huawei Technologies 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 CNB2006100783083A priority Critical patent/CN100496022C/en
Publication of CN1968192A publication Critical patent/CN1968192A/en
Application granted granted Critical
Publication of CN100496022C publication Critical patent/CN100496022C/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/50Reducing energy consumption in communication networks in wire-line communication networks, e.g. low power modes or reduced link rate

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention relates to a method for controlling flux, and relative device, wherein it comprises that: obtaining flux control parameter as system property data; comparing control parameter with preset range; controlling the sending speed of data pack via the compared result. The invention can reduce resource consumption and improve operation stability, to balance the processing ability and network bandwidth.

Description

A kind of method of flow control and device
Technical field
The present invention relates to technical field of data transmission, relate in particular to a kind of method and device of flow control.
Background technology
In the very high communication system of a real-time and reliability requirement, satisfy the reliable of transmission, need carry out flow control to different business.
In existing technical scheme, a kind of method of flow control is a constant transmissions speed, as leaking the bucket control mode.Leak bucket and be equivalent to a buffering area, the burst transfer circulation can be turned to mild transport stream, guarantee that user's transport stream is observed the regulation of user when connecting.When queue full, grouping is dropped, and formation speed in accordance with regulations sends grouping to network.
Adopt this mode can guarantee the reliability of system, but shortcoming is also apparent in view, can not reasonably uses resource exactly exist in traffic carrying capacity when changing, no matter data volume is much, always send data with constant rate of speed.Can not be real-time network traffics be controlled according to network condition, congested if network occurs, still send with schedule speed, cause packet loss too high, postpone excessive.If when traffic carrying capacity is bigger, speed is provided with and too smallly data stacking then can occurs too much and the situation of packet loss.
Another kind of prior art has realized the dynamic adjustment of network traffics, the transmission respectively of multipriority.Such as sliding window protocol, can carry out flow control by dynamic adjustment window size.
Transmission control protocol (TCP:Transmission Control Protocol) uses window technique to improve flow control, so that communicating pair can make full use of bandwidth.Sliding window allows transmit leg to send a plurality of data segments before the affirmation of receiving the recipient.Window size determined before receiving that the destination is confirmed, once the maximum number of the data segment that can transmit.Window is big more, and the data segment that main frame once can transmit is just many more.Behind the data segment of the big peanut of main frame transmission window, just must wait and receive affirmation, just can descend the data segment of face again.Window technique has improved utilization of network bandwidth greatly.
The size of window is variable during communicating pair connects, and communicating pair can dynamically be revised window size through consultation.In each of TCP confirmed, except the sequence number of the next data segment pointing out to wish to receive, also comprise a window advertisement, pointed out in the announcement that the recipient can also receive how many data segments, i.e. recipient's buffer size again.If the announcement value increases, the also corresponding increase of window size; The announcement value reduces, and window size is also corresponding to be reduced.
The method that network traffics are dynamically adjusted is often only considered the control of speed, has ignored the balance of system resource, when improving network traffics, too high speed makes the expensive source of system handles institute excessive, causes the unsteadiness of system's operation, influences the processing of other business.Also might cause the system resource deficiency and produce chain reaction: application layer data is handled failure, and socket (socket) buffering area sends and congestion situation etc. occurs.
Summary of the invention
The technical problem to be solved in the present invention provides a kind of method and device of flow control, and this method and device can be accomplished the reasonable equilibrium of the system processing power and the network bandwidth, is guaranteeing the normal data that send under the operational efficiency prerequisite of system.
For solving the problems of the technologies described above, the objective of the invention is to be achieved through the following technical solutions, a kind of method of flow control comprises step: 1) obtain the flow control parameter, described flow control parameter comprises system performance information; 2) described flow control parameter and preset range are compared; 3) result according to described comparison controls the maximum that unit interval one-level data buffer zone writes the secondary data buffer area data volume; Described one-level data buffer zone is used to receive data and in the unit interval a certain amount of data is write the secondary data buffering area; Described secondary data buffering area is used to receive the data that write from the one-level data buffer zone and all sends in the described unit interval.
Preferably, described flow control parameter has different priority; Result according to described comparison in the described step 3) controls the transmission rate of packet according to the priority orders of each flow control parameter successively.
Preferably, the described flow control parameter of obtaining comprises also and obtains network performance data that described network performance data has the priority that is lower than system performance information.
Preferably, described system performance information comprises: system's CPU occupancy and/or memory usage.
Preferably, in the described step 3) transmission rate of packet being controlled is that peak rate to packet sends is adjusted.
Preferably, described to peak rate adjustment be according to described comparative result exceed or the amount that is lower than preset range in proportion or fixed step size adjust.
Preferably, the described flow control parameter of obtaining also comprises the feedback data of obtaining the flow receiving terminal, and described feedback data comprises the congestion ratio and/or the packet loss of flow receiving terminal; This feedback data has the priority that is lower than system performance information.
The device of a kind of flow control provided by the invention comprises: statistic unit, be used to obtain the flow control parameter, and described flow control parameter comprises system performance information; Comparing unit is used for described flow control parameter and preset range are compared; The speed adjustment unit is used for according to the result of described comparison the transmission rate of packet being controlled.
Preferably, also comprise: parameter set unit is used to be provided with the priority of each flow control parameter of obtaining and the preset range that compares with the flow control parameter.
Preferably, described statistic unit also is used to obtain network performance data, and described network performance data has the priority that is lower than system performance information.
Preferably, comprising: the one-level data buffer zone is used to receive data and in the unit interval a certain amount of data is write the secondary data buffering area; The secondary data buffering area is used to receive the data that write from the one-level data buffer zone and all sends in the described unit interval; Described speed adjustment unit is the maximum that control unit interval one-level data buffer zone can write the secondary data buffer area data volume to the control of transmission rate.
Preferably, described one-level data buffer zone is made up of some different priorities formations;
Described parameter set unit also is used for being provided with the ratio that each each priority query's packet of unit interval one-level data buffer zone writes the secondary data buffering area.
Adopt technique scheme, beneficial technical effects of the present invention is:
1) the present invention is by obtaining the flow control parameter that comprises system performance information, and more described performance data and preset range, the speed that sends according to comparative result control data bag.Solved too high transmission rate make system handles excessive, the problem that causes system's fluctuation of service in expensive source.Guaranteed the operational efficiency of system when data send.
2) on the basis in system performance information remains on normal range (NR), the flow control parameter of obtaining can also comprise network performance data, and network performance data and preset range compared, adjust the speed that packet sends according to the comparative result dynamic smoothing, better utilization Internet resources, guarantee system's traveling comfort.
3) the present invention to the control of transmission rate be comparative result according to flow control parameter and preset range exceed or the amount that is lower than preset range in proportion or fixed step size peak rate is adjusted.Accomplished the reasonably quantitative adjustment of the peak rate that data are sent, made adjustment more accurate, rapider.
Description of drawings
Fig. 1 is the flow chart of the method for the embodiment of the invention one flow control;
Fig. 2 is the flow chart of the method for the embodiment of the invention two flows control;
Fig. 3 is the flow chart of the method for the embodiment of the invention three flow controls;
Fig. 4 is the structure chart of the device of flow control of the present invention;
Fig. 5 is the structure chart of the device of the embodiment of the invention four flow controls;
Fig. 6 is for using the CPU usage figure under test 1 situation that the present invention carries out;
Fig. 7 is for using the CPU usage figure under test 2 situations that the present invention carries out;
Fig. 8 is for using the CPU usage figure under test 3 situations that the present invention carries out.
Embodiment
The invention provides a kind of method and device of flow control, be applied to technical field of data transmission.The basic thought of this method and device is: obtain the flow control parameter, described flow control parameter comprises system performance information; Described flow control parameter and preset range are compared; Result according to described comparison controls the transmission rate of packet.The big more consume system resources of data package transmission velocity also increases thereupon, and the while may cause congested, and the reduction data package transmission velocity can reduce the consumption to system resource, and the present invention has guaranteed the reasonable equilibrium of the system processing power and the network bandwidth.Described flow control parameter can also comprise network performance data, by network performance data the control of transmission rate is had the priority that is lower than system performance information.Below flow control methods of the present invention and device are described in detail.
Embodiment one, a kind of method of flow control, and flow chart comprises step as shown in Figure 1:
Step a1 obtains system's CPU (CPU:Central Processing Unit) occupancy.
Described system performance information, it is the software and hardware parameter of system's operational outfit, what present embodiment adopted is the occupancy of system CPU, can also be the data that memory usage etc. can reflect system operation situation, equipment difference, the software and hardware parameter of obtaining also can be different, for example, can also be some device specific system performance information, the parameter of specifically obtaining be construed as limiting the invention.
Step a2 checks whether described CPU usage exceeds corresponding preset range, is, then turns to step a3; , then do not turn to step a4.
Step a3 reduces the peak rate that packet sends, and turns to step a4.
Described peak rate is the maximum that each packet sends unit interval, by to the adjustment of the peak rate speed of control data bag transmission indirectly.The present invention emphasizes is by obtaining the speed that system performance information control data bag sends, and specifically which kind of control mode is the speed that packet is sent adopt be not construed as limiting the invention.
Step a4 finishes this adjustment.
Can reach the purpose that take of control transmission task by the control data packet sending speed to system resource.Solved too high transmission rate make system handles excessive, the problem that causes system's fluctuation of service in expensive source, guaranteed the operational efficiency of system when data send.
Embodiment two, a kind of method of flow control, and flow chart comprises step as shown in Figure 2:
Step b1 obtains the actual speed rate that CPU usage and packet send.
The actual speed rate that described packet sends is the Mean Speed of the actual transmission of packet of statistics in the time cycle of presetting.
In the present embodiment, network performance data is the actual speed rate that packet sends.Described network performance data can also comprise that congestion ratio and/or packet loss etc. help the parameter of judgment data bag status transmission.
Step b2 checks whether described CPU usage exceeds corresponding preset range, is, then turns to step b4; , then do not turn to step b3.
Step b3 checks that described actual speed rate whether outside corresponding preset range, is then to turn to step b5; , then do not turn to step b6.
Step b4 reduces the peak rate that packet sends, and turns to step b6.
Step b5 adjusts the peak rate that packet sends, and turns to step b6.
Described adjustment is specially, if described actual speed rate is higher than the corresponding preset range upper limit, the described peak rate that then raises if described actual speed rate is lower than corresponding preset range lower limit, then reduces described peak rate.
Described being used for compares corresponding preset range with actual speed rate, rising or the reduction of carrying out equivalent along with the rising or the reduction of peak rate.
Step b6 finishes this adjustment.
Embodiment two is the step of obtaining network performance data and adjusting according to the peak rate that network performance data sends packet that increases with the difference of embodiment one.Keep under the normal prerequisite in systematic function, by the network performance data that basis is obtained, dynamic smoothing is adjusted the speed that packet sends, and has accomplished assurance system traveling comfort, has rationally utilized Internet resources simultaneously again.
Embodiment three, a kind of method of flow control, and flow chart comprises step as shown in Figure 3:
Step s1 obtains system performance information and the network performance data added up in the time cycle of presetting.
In the present embodiment, carried out data statistics in per 1 second, the data of statistics comprise the actual speed rate that average CPU usage, congestion ratio, packet loss and the packet of this transformation task send.
In the present embodiment, per 10 milliseconds of unit interval as the transmission data, the packet number that rate value sent with the unit interval is represented.Being understandable that, the definition of rate value unit is not limited thereto kind of a mode, also can be figure place, byte number or code element number that time per unit sends data.
Actual speed rate is in the 1s measurement period, and each unit interval (10 milliseconds) sends the mean value of packet number.
Step s2 checks whether the CPU usage of obtaining surpasses corresponding threshold value, is then to turn to rapid s3; , then do not turn to step s4.
Be understandable that the corresponding preset range that is used in the present embodiment comparing with CPU usage, congestion ratio, packet loss delimited with threshold value separately.Consider upper-layer service handle consume the CPU time, it is 20% that the shared CPU threshold value of this task is set.
Step s3, the percentage that exceeds the shared threshold value of amount of respective threshold according to described CPU usage is taked corresponding reduction value to peak rate, and turns to step s11.CPU usage herein is the high-priority traffic Control Parameter, to the high priority that is controlled to be of peak rate.
It is as shown in table 1 that the high-priority traffic Control Parameter exceeds the peak rate adjusted value of percentage correspondence of the shared threshold value of amount of default respective threshold.CPU usage is as the high-priority traffic Control Parameter, and is bigger to the adjusting range of peak rate.
Wherein, peak rate is the maximum that each unit interval (10 milliseconds) sends the packet number.
Among this routine embodiment, it is 100 (being that peak rate is/10 milliseconds of 100 bags) that the number maximum of initially giving out a contract for a project is set.
Step s4 checks whether the congestion ratio of obtaining exceeds corresponding threshold value, is then to turn to step s6; , then do not turn to step s5.In the present embodiment, congestion ratio threshold value 0.1% is set.
Step s5 checks whether the packet loss that obtains exceeds corresponding threshold value, is then to turn to step s6; , then do not turn to step s7.In the present embodiment, it is 0.05% that the packet loss threshold value is set.
Step s6, the percentage that exceeds the shared respective threshold of amount of respective threshold according to described congestion ratio or packet loss is taked corresponding reduction value to peak rate, and turns to step s11.Congestion ratio herein and packet loss are medium priority flow control parameter, to the medium priority that is controlled to be of peak rate.
It is as shown in table 1 that medium priority flow control parameter exceeds the peak rate adjusted value of percentage correspondence of the shared threshold value of amount of default respective threshold.Congestion ratio and packet loss are compared with the high-priority traffic Control Parameter as medium priority flow control parameter, and be less relatively to the adjusted value of peak rate.
In the present embodiment, the computing formula that CPU usage, congestion ratio and packet loss exceed the shared threshold percentage of amount of respective threshold is:
Percentage=(flow control parameter-threshold value of obtaining)/threshold value * 100%
Table 1
0<percentage≤10% 10%<percentage≤20% Percentage〉20%
The peak rate degradation value of high-priority traffic Control Parameter correspondence -3 -5 -7
The peak rate degradation value of medium priority flow control parameter correspondence -1 -3 -5
Peak rate and actual speed rate that step s7, comparing data bag send obtain difference, and check that described difference whether greater than the higher limit of the difference range of presetting, is then to turn to step s8; , then do not turn to step s9.
Wherein, because peak rate and actual speed rate calculate with the number that sends packet in the unit interval, so its difference also is the packet number.
Step s8 takes corresponding reduction value and turns to step s11 peak rate according to described difference.
Step s9, whether the difference of checking described peak rate and actual speed rate is then to turn to step s10 less than the lower limit of preset difference value scope; , then do not turn to step s11.
Step s10 takes corresponding lift-off value and turns to step s11 peak rate according to described difference.
The actual speed rate of obtaining is the low-priority traffic Control Parameter, and to the low priority that is controlled to be of peak rate, described difference is as shown in table 2 with corresponding peak rate adjusted value.Difference 15 is the lower limit of preset difference value scope, and difference 35 is the higher limit of preset difference value scope, and difference shows that less than 15 current network conditions is good, needs the rising peak rate, and difference is more little, and peak rate rising amplitude is big more; In case difference surpasses 35 then show that network condition is relatively poor, needs to reduce peak rate; Difference is big more, and it is big more that peak rate reduces amplitude.Difference thinks that transmission rate is tending towards a stable state in 15 to 35 scope, peak rate is not adjusted, and guarantee that so also speed tends towards stability after the adjusting of a period of time, thereby CPU usage tends towards stability also.
Table 2
Difference range Adjust size
0≤difference<5 +15
5≤difference<10 +9
10≤difference<15 +3
Difference〉45 -3
40<difference≤45 -2
35<difference≤40 -1
Wherein, there is no absolute order for the difference of described peak rate and actual speed rate and the judgement and the adjustment of preset range higher limit or lower limit, further, determining step for described difference and higher limit and lower limit is also inessential, also can be directly corresponding relation by difference inquiry difference and peak rate adjusted value obtain adjusted value, but this kind mode has increased the access times of his-and-hers watches 2, system resource is taken bigger, does not advise adopting.
What the comparative result of described peak rate and actual speed rate adopted in the present embodiment is both differences, is understandable that, described comparative result also can be both ratio.As long as can according to the result who relatively draws can be corresponding default the adjusted value to peak rate.
Step s11 finishes this adjustment.
The present invention is for the height of flow control parameter priority and can being provided with of corresponding adjustment strategy, and the priority that is provided with also is not limited to above three, can different priority be set to satisfy user's demand respectively according to different flow control parameters.
Present embodiment is that the comparative result according to flow control parameter and preset range exceeds or the amount fixed step size that is lower than preset range is adjusted peak rate.Described fixed step size is adjusted, and is according to corresponding its corresponding peaks speed adjusted value of described comparative result.Equally, also can adopt proportionally peak rate is adjusted, the described ratio of adjusting according to corresponding its corresponding peaks speed of comparative result that is adjusted in proportion.Mode to the quantitative adjustment of peak rate is not construed as limiting the invention.By above-mentioned adjustment mode, accomplished the rationally quantitative adjustment of the peak rate that data are sent, make adjustment more accurate, rapider.
The above execution mode description of this invention is only considered by the statistics local data flow that data send to be controlled, be understandable that, the present invention can also set up handshake mechanism with the flow receiving terminal, and feedback local terminal statistics obtains the feedback data of flow receiving terminal for the flow receiving terminal simultaneously.Described feedback data can comprise CPU usage, congestion ratio, packet loss and the actual transmission rate etc. of flow receiving terminal.By obtaining described feedback data statistics the Local Data transmission rate is adjusted accordingly.On the present embodiment basis, these feedback data can be judged as the flow control parameter of medium priority, adjust the peak rate that packet sends, to adapt to flow receiving terminal situation.
Device to a kind of flow control provided by the invention is described in detail below.
Seeing also Fig. 4, is the structure chart of the device of flow control of the present invention, comprising:
Statistic unit 310 is used to obtain the flow control parameter, and described flow control parameter comprises system performance information;
Comparing unit 320 is used for described flow control parameter and preset range are compared;
Speed adjustment unit 330 is used for according to the result of described comparison the transmission rate of packet being controlled.
Embodiment four, and a kind of device of flow control, structure chart comprise as shown in Figure 5:
One-level data buffer zone 100 is divided into some different priorities formations, is used to receive data and in the unit interval a certain amount of data is write secondary data buffering area 200.
Secondary data buffering area 200 is used to receive the data that write from one-level data buffer zone 100 and all sends in the described unit interval.
Being understandable that secondary data buffering area 200 can be a socket buffer, can also be other buffering areas that are used to send data.
Statistic unit 310 is used to obtain the flow control parameter, and described flow control parameter comprises system performance information.
Comparing unit 320 is used for described flow control parameter and preset range are compared.
Speed adjustment unit 330 is used for according to comparative result the transmission rate of packet being controlled.Described control is the peak rate that the control data bag sends, and promptly controls the maximum that unit interval one-level data buffer zone can write the secondary data buffer area data volume.
Parameter set unit 340, be used to be provided with each flow control parameter of obtaining priority and with the parameter area of the comparison of flow control parameter; Also be used for being provided with the ratio that each unit interval one-level data buffer zone 100 each priority query's packet writes secondary data buffering area 200.
Need to prove that the upper-layer service module writes the data packet one-level data buffer zone 100, when writing data,, write the data packet corresponding priorities formation in the one-level data buffer zone 100 according to the priority of data packets field.When one-level data buffer zone 100 write secondary data buffering area 200 with data, the ratio that each priority query that is provided with according to parameter set unit 340 writes secondary data buffering area 200 write data.
But the control method among the said apparatus application of aforementioned embodiment one to embodiment three is carried out flow control, is example with the method among the embodiment three below, describes the control procedure of this device in detail:
At first the user can be provided with relevant parameter in parameter set unit 340 as required, needs the parameter that is provided with consistent among described parameter and the embodiment three.Statistic unit 310 obtains the system performance information and the network performance data of statistics in the time cycle of presetting after the system start-up.In the present embodiment, carried out data statistics in per 1 second, the data of statistics comprise the average CPU usage of this transformation task, actual transmission rate, packet loss, congestion ratio.Comparing unit 320 checks whether the average CPU usage that statistic unit 310 obtains surpasses corresponding threshold value, be, then speed adjustment unit 330 percentage that exceeds the shared threshold value of amount of respective threshold according to described CPU usage is taked corresponding reduction value to peak rate, and finishes this adjustment; Not, then comparing unit 320 checks whether the congestion ratio that statistic unit 310 obtains exceeds corresponding threshold value, be that then speed adjustment unit 330 percentage that exceeds the shared threshold value of amount of respective threshold according to described congestion ratio is taked corresponding reduction value to peak rate, and finishes this adjustment; Not, then comparing unit 320 checks whether the packet loss that statistic unit 310 obtains exceeds corresponding threshold value, be that then speed adjustment unit 330 percentage that exceeds the shared threshold value of amount of respective threshold according to described packet loss is taked corresponding reduction value to peak rate, and finishes this adjustment; Not, then the peak rate and the actual speed rate that send of comparing unit 320 comparing data bags obtains difference, and checks that described difference whether greater than the higher limit of the difference range of presetting, is, then peak rate is taked corresponding reduction value, and finish local the adjustment according to described difference; Not, then comparing unit 320 check described peak rates and actual speed rate difference whether less than the lower limit of preset difference value scope, be that then speed adjustment unit 330 is taked corresponding lift-off value according to described difference to peak rate, and finishes this adjustment; , then directly do not finish this adjustment.
In order to further specify actual effect of the present invention, provide based on above-mentioned application examples the explanation of carrying out actual test and comparing with different pieces of information below with prior art.
Test 1: network condition is good, the socket buffer size is 96Kbytes, packet size average out to 320bytes, time per unit (10 milliseconds) number of giving out a contract for a project maximum is initially 100, after dynamically adjusting, be stable at 62, the actual number of giving out a contract for a project is stable at 29, sees also Fig. 6, and CPU usage is stable at 15%.Transmission rate is stable at 7.11Mbps, and packet loss and congestion ratio all are 0.
Test 2: network condition is relatively poor, and the socket buffer size is 96Kbytes, packet size average out to 170bytes, and time per unit (10 milliseconds) number of giving out a contract for a project maximum is initially 100.See also Fig. 7, slight fluctuations appears in CPU usage, is stable at 18%~19%, does not surpass threshold value 20%.Time per unit is given out a contract for a project the number maximum through dynamically being stable at 90 after the adjustment, and the actual number of giving out a contract for a project is stable at 56, and transmission rate is stable at 7.23Mbps.Congested and packet drop appears in the test, through dynamically reducing the number maximum of giving out a contract for a project, have influence on the actual number of giving out a contract for a project, thereby reduction transmission rate, prevent worse congested or packet drop, in case network condition obtains taking a turn for the better, the number maximum of will giving out a contract for a project is automatically heightened, the actual number of giving out a contract for a project also increases thereupon, thereby has raise transmission rate.Whole process has embodied the present invention in the improvement that guarantees under the systematic function prerequisite network rate.
Test 3: adopt the leakage bucket control mode of prior art, network condition is good, and the socket buffer size is 96Kbytes, packet size average out to 320bytes.With test 1 data consistent, time per unit (10 milliseconds) number of giving out a contract for a project maximum is fixed as 100, and the fluctuation of the actual transmission of time per unit packet number is bigger, roughly is in 16 to 24 scopes, and transmission rate is in 3.80 to 6.20Mbps.See also Fig. 8, the CPU usage fluctuation is bigger, is between 10% to 15%.Contrast test 1, the good stability of a system of the present invention and transmission rate as can be seen faster.
As table 3, table 4,9 groups of tests have been carried out respectively, table 3 is for adopting the prior art test data, be that the number maximum of giving out a contract for a project each unit interval is fixed, without dynamic adjusting data, each unit interval, there was fluctuation in the actual number of giving out a contract for a project, and the transmission rate existence is unstable, and some combination speed is lower, the CPU usage fluctuation is bigger.Table 4 is for using test data of the present invention, no matter initially give out a contract for a project number what, the size of giving out a contract for a project, after dynamically adjusting, the maximum of the number of giving out a contract for a project and actual value all tend towards stability, and guarantee higher transmission rate and stable CPU usage.
Table 3
The number of initially giving out a contract for a project maximum/10 milliseconds The packet size The actual number of giving out a contract for a project/10 milliseconds Transmission rate (Mbps) CPU usage
100 100 93 7.10 20%
100 170 56 7.22 18%
100 320 16~24 3.80~6.21 10%~15%
200 100 68~88 5.10~6.80 14%~17%
200 170 29 3.90 11%
200 320 11 2.70~3.00 8%
400 100 28~48 1.90~2.10 8%~10%
400 170 20 2.57~2.63 8%~9%
400 320 11 2.84~2.89 8%
Table 4
The number of initially giving out a contract for a project maximum/10 milliseconds The packet size Adjusted number maximum/10 millisecond of giving out a contract for a project The actual number of giving out a contract for a project/10 milliseconds Transmission rate (Mbps) CPU usage
100 100 127 94 7.15 19%
100 170 90 56 7.23 17%
100 320 61 29 7.11 15%
200 100 128 94 7.15 19%
200 170 90 56 7.23 17%
200 320 62 29 7.10 15%
400 100 127 94 7.14 19%
400 170 91 56 7.22 17%
400 320 61 29 7.10 15%
More than the method and the device of a kind of flow control provided by the present invention is described in detail, used specific case herein principle of the present invention and execution mode are set forth, the explanation of above embodiment just is used for helping to understand method of the present invention and core concept thereof; Simultaneously, for one of ordinary skill in the art, according to thought of the present invention, the part that all can change in specific embodiments and applications, in sum, this description should not be construed as limitation of the present invention.

Claims (11)

1. the method for a flow control is characterized in that, comprises step:
1) obtain the flow control parameter, described flow control parameter comprises system performance information;
2) described flow control parameter and preset range are compared;
3) result according to described comparison controls the transmission rate of packet, specifically comprises: the result according to described comparison controls the maximum that unit interval one-level data buffer zone writes the secondary data buffer area data volume; Described one-level data buffer zone is used to receive data and in the unit interval a certain amount of data is write the secondary data buffering area; Described secondary data buffering area is used to receive the data that write from the one-level data buffer zone and all sends in the described unit interval.
2. the method for flow control as claimed in claim 1, it is characterized in that: described flow control parameter has different priority;
Result according to described comparison in the described step 3) controls the transmission rate of packet according to the priority orders of each flow control parameter successively.
3. the method for flow control as claimed in claim 2 is characterized in that: the described flow control parameter of obtaining comprises also and obtains network performance data that described network performance data has the priority that is lower than system performance information.
4. the method for flow control as claimed in claim 1 is characterized in that, described system performance information comprises: system's CPU occupancy and/or memory usage.
5. as the method for any described flow control of claim 1 to 4, it is characterized in that: in the described step 3) transmission rate of packet being controlled is that peak rate to packet sends is adjusted.
6. the method for flow control as claimed in claim 5 is characterized in that: described to peak rate adjustment be according to described comparative result exceed or the amount that is lower than preset range in proportion or fixed step size adjust.
7. the method for flow control as claimed in claim 6, it is characterized in that: the described flow control parameter of obtaining also comprises the feedback data of obtaining the flow receiving terminal, and described feedback data comprises the congestion ratio and/or the packet loss of flow receiving terminal; This feedback data has the priority that is lower than system performance information.
8. the device of a flow control is characterized in that, comprising:
The one-level data buffer zone is used to receive data and in the unit interval a certain amount of data is write the secondary data buffering area;
The secondary data buffering area is used to receive the data that write from the one-level data buffer zone and all sends in the described unit interval;
Statistic unit is used to obtain the flow control parameter, and described flow control parameter comprises system performance information;
Comparing unit is used for described flow control parameter and preset range are compared;
The speed adjustment unit is used for according to the result of described comparison the transmission rate of packet being controlled, and specifically comprise: the result according to described comparison controls the maximum that unit interval one-level data buffer zone writes the secondary data buffer area data volume.
9. the device of flow control as claimed in claim 8 is characterized in that, also comprises:
Parameter set unit is used to be provided with the priority of each flow control parameter of obtaining and the preset range that compares with the flow control parameter.
10. the device of flow control as claimed in claim 9 is characterized in that:
The flow control parameter that described statistic unit obtains also comprises network performance data, and described network performance data has the priority that is lower than system performance information.
11. the device of flow control as claimed in claim 9 is characterized in that:
Described one-level data buffer zone is made up of some different priorities formations;
Described parameter set unit also is used for being provided with the ratio that each each priority query's packet of unit interval one-level data buffer zone writes the secondary data buffering area.
CNB2006100783083A 2006-05-09 2006-05-09 Flow control method and apparatus Expired - Fee Related CN100496022C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CNB2006100783083A CN100496022C (en) 2006-05-09 2006-05-09 Flow control method and apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CNB2006100783083A CN100496022C (en) 2006-05-09 2006-05-09 Flow control method and apparatus

Publications (2)

Publication Number Publication Date
CN1968192A CN1968192A (en) 2007-05-23
CN100496022C true CN100496022C (en) 2009-06-03

Family

ID=38076749

Family Applications (1)

Application Number Title Priority Date Filing Date
CNB2006100783083A Expired - Fee Related CN100496022C (en) 2006-05-09 2006-05-09 Flow control method and apparatus

Country Status (1)

Country Link
CN (1) CN100496022C (en)

Families Citing this family (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101350764B (en) * 2007-07-20 2011-03-16 中国科学院声学研究所 Network flow control method
CN101257459B (en) * 2008-04-08 2010-08-18 北京星网锐捷网络技术有限公司 Data packet processing method and device
CN102348235B (en) * 2010-08-03 2015-06-10 中兴通讯股份有限公司 Method and base transceiver station for controlling utilization rate of central processing unit (CPU)
CN101938484B (en) * 2010-09-09 2013-05-15 奇智软件(北京)有限公司 Distributed flow control method and system
CN102905313B (en) * 2011-07-27 2014-12-10 无锡物联网产业研究院 Network data collection method and device of wireless sensor
CN102378065A (en) * 2011-10-19 2012-03-14 江西省南城县网信电子有限公司 Method and system for configuring buffer area at streaming media server side based on MPEG (Moving Picture Experts Group)-4
CN102752076B (en) * 2012-06-20 2016-08-10 华为技术有限公司 Control method that data send and device and computer system
CN102724123B (en) * 2012-06-27 2015-04-29 青岛上锋科技有限公司 Network traffic control method and network traffic control device
CN103812687B (en) * 2012-11-15 2017-12-15 华为技术有限公司 The means of defence and equipment of processor
CN103840910A (en) * 2012-11-22 2014-06-04 深圳市腾讯计算机系统有限公司 Data transmission control method and apparatus
CN104426796A (en) * 2013-08-21 2015-03-18 中兴通讯股份有限公司 Congestion avoiding method and apparatus of router
CN104967635B (en) * 2014-05-22 2017-04-19 腾讯科技(深圳)有限公司 Data transmission method and apparatus thereof
CN106506392B (en) * 2016-12-19 2019-11-26 深圳创维数字技术有限公司 A kind of network congestion processing method and device
CN110601872A (en) * 2019-08-06 2019-12-20 联想(北京)有限公司 Transmission method and device and storage medium
CN110474811B (en) * 2019-08-21 2022-09-23 杭州安恒信息技术股份有限公司 Debugging method, debugging system and related device for network performance
CN112019448B (en) * 2020-10-29 2021-02-19 北京安盟信息技术股份有限公司 Reliability control method and system based on unidirectional data transmission
CN112346867B (en) * 2020-11-06 2024-05-14 平安科技(深圳)有限公司 Configuration method and device of sliding window, computer equipment and storage medium
CN115903714B (en) * 2023-01-06 2023-06-20 济南市计量检定测试院 Industrial pollution source emission whole process monitoring and adjusting device and method

Also Published As

Publication number Publication date
CN1968192A (en) 2007-05-23

Similar Documents

Publication Publication Date Title
CN100496022C (en) Flow control method and apparatus
RU2407246C2 (en) Method and device to dedicate bandwidth in wireless communication system
US8090814B2 (en) Method for determining distribution of a shared resource among a plurality of nodes in a network
WO2005015854A1 (en) Distributed quality-of-service management system
US20020141353A1 (en) Method and device for improving a data throughput
CN102710389B (en) Method and user equipment for transmitting uplink data
CN102934403A (en) Controlling data transmission over a network
Le Improving the performance of multipath congestion control over wireless networks
CN105764091A (en) Method of effectively utilizing wireless bandwidth
Zhu et al. An efficient priority-driven congestion control algorithm for data center networks
JP5533270B2 (en) Gateway device and packet buffer management method in gateway device
Gomez et al. Havana: Supporting application and channel dependent QoS in wireless packet networks
Chiang et al. Jointly optimal congestion control and power control in wireless multihop networks
CN106922030A (en) The processing method and processing device of scheduling
CN103107949A (en) Network relay device, control method for network relay device
CN100544307C (en) The method and system of load control
Xia et al. Active queue management with dual virtual proportional integral queues for TCP uplink/downlink fairness in infrastructure WLANs
CN102739508A (en) Method and system for data transmission of high-speed network
JP2009212632A (en) Communication equipment and communication method
CN1859064A (en) Method for distributing channel resources
FI115096B (en) Method for controlling a terminal device
CN102668470B (en) Method and allocation unit for allocating a communication pipe in a communication network
Cai et al. D-OLIA: The packet loss differentiation based opportunistic linked-increases algorithm for MPTCP in wireless heterogeneous network
Sood et al. Hybrid Congestion Control Mechanism in Software Defined Networks
Han et al. Receive buffer pre-division based flow control for MPTCP

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20090603