1. Technical Field
The present invention relates to a method of bandwidth allocation in a network and a computer-readable storage medium for storing thereof. More particularly, the present invention relates to a method of bandwidth allocation in a Resilient Packet Ring (RPR) network and a computer-readable storage medium for storing thereof.
2. Description of Related Art
The RPR is a ring based network for high-speed metropolitan area networks (MANs) and is constructed by several pairs of two unidirectional links between stations. The RPR has some noticeable properties such as spatial reuse and fair bandwidth allocation to mitigate deficiencies of some MANs, such as SONET and high-speed Ethernet. Also it can achieve high fault tolerance and bandwidth utilization. It is a superior candidate for MANs.
The spatial reuse allows a frame to be removed from the ring at its destination so that the bandwidth on next links can be re-used at the same time. Also, the fair bandwidth allocation avoids stations at upstream transmitting too many low-priority frames to cause system congestion for stations at downstream. RPR needs a congestion control to enhance the fair bandwidth division in the congestion domain, which is defined in the. IEEE 802.17. The congestion control implemented in each station should periodically generate an advertised fair rate to advertise its upstream station for regulating the added fairness eligible (FE) traffic flow defined in IEEE 802.17. The advertised fair rate should be determined referring to the local fair rate, the received fair rate, and the congestion degree of the station. The local fair rate is generated utilizing a fairness algorithm, and the received fair rate is the advertised fair rate from the downstream station.
Two key factors affect performance of the fair bandwidth allocation: congestion detection and fairness algorithm. If the congestion is detected too roughly, it would lower the network's throughput or raise frame loss. In addition, if the propagation delay is large, the short-term arriving transit FE traffic flows would be largely varied and makes the generation of local fair rate unstable. Therefore, there is a need to further improve the local fair rate assignment.
According to one embodiment of this invention, a method of bandwidth allocation in an RPR network includes the following steps: congestion degree of a present node in the RPR network is determined, wherein there is an upstream node and a downstream node of the present node in the RPR network, the present node builds connection with the upstream node and the downstream node respectively. A present local arrival rate of local traffic flows received by the present node from at least one client is obtained. An average transit rate of fairness eligible (FE) flows received by the present node from the upstream node in a past time period is obtained. A previous temporal fair rate of the present node is obtained. An effective node number for the present node is calculated according to the average transit rate, the present local arrival rate and the previous temporal fair rate. A present temporal fair rate of the present node is calculated according to the effective node number, the average transit rate and the present local traffic rate. A present local fair rate of the present node is obtained by looking up a local fair rate table according to the congestion degree of the present node and the present temporal fair rate. The present local fair rate is transmitted to the upstream node, such that transit rate transmitted by the upstream node is controlled according to the present local fair rate of the present node.
According to another embodiment of this invention, a computer-readable storage medium for storing a plurality of instructions to execute a method of bandwidth allocation in a RPR network is provided. The method of bandwidth allocation in the RPR network includes the following steps: congestion degree of a present node in the RPR network is determined, wherein there is an upstream node and a downstream node of the present node in the RPR network, the present node builds connection with the upstream node and the downstream node respectively. A present local arrival rate of local traffic flows received by the present node from at least one client is obtained. An average transit rate of FE flows received by the present node from the upstream node in a past time period is obtained. A previous temporal fair rate of the present node is obtained. An effective node number for the present node is calculated according to the average transit rate, the present local arrival rate and the previous temporal fair rate. A present temporal fair rate of the present node is calculated according to the effective node number, the average transit rate and the present local traffic rate. A present local fair rate of the present node is obtained by looking up a local fair rate table according to the congestion degree of the present node and the present temporal fair rate. The present local fair rate is transmitted to the upstream node, such that transit rate transmitted by the upstream node is controlled according to the present local fair rate of the present node.
These and other features, aspects, and advantages of the present invention will become better understood with reference to the following description and appended claims. It is to be understood that both the foregoing general description and the following detailed description are by examples, and are intended to provide further explanation of the invention as claimed.
The invention can be more fully understood by reading the following detailed description of the embodiments, with reference made to the accompanying drawings as follows:
Reference will now be made in detail to the present embodiments of the invention, examples of which are illustrated in the accompanying drawings. Wherever possible, the same reference numbers are used in the drawings and the description to refer to the same or like parts.
In step 510, congestion degree of the present node 200 in the RPR network is determined. The congestion degree of the present node 200 may be determined based on occupancy of the STQ 222 and a present transit rate of the FE flows received from the upstream node 100. In one embodiment, the congestion degree of the present node may be determined by looking up a congestion degree table according to the occupancy of the STQ and the present transit rate of the FE flows. The congestion degree table may be designed under fuzzy set theory.
Table 1 is one embodiment of the congestion degree table designed under fuzzy set theory. In Table 1, Ls(n) denotes the occupancy of STQ 222, As(n) denotes the present transit rate of the FE flows received from the upstream node 100, and Dc(n) denotes the congestion degree of the present node 200. The occupancy of STQ 222 Ls(n) is classified into Short (S) and Large (L). The present transit rate of the FE flows As(n) is classified into Low (L), Medium (M) and High (H). The congestion degree of the present node 200 Dc(n) is defined as Very Low (VL), Low (L), Medium (M), High (H) and Very High (VH). Hence, the congestion degree of the present node 200 in the RPR network can be determined (step 510) by looking up a congestion degree table according to the occupancy of the STQ and the present transit rate of the FE flows. For example, if the occupancy of STQ 222 Ls(n) is S and the present transit rate of the FE flows As(n) is L, the congestion degree of the present node 200 Dc(n) may be determined as VL after looking up Table 1. Therefore, the congestion detection may be more precisely by taking both the occupancy of the STQ 222 and the present transit rate of the FE flows received from the upstream node 100 into consideration. However, the congestion degree table may be designed under another theory, which should not be limited in this disclosure.
In step 520, a present local arrival rate of local traffic flows received by the present node 200 from at least one client 400 is obtained.
In step 530, an average transit rate of the FE flows received by the present node 200 from the upstream node 100 in a past time period is calculated. Wherein, the transit rate of the FE flows received by the present node 200 from the upstream node 100 may be recorded periodically for calculating the average transit rate (step 530). Hence, the average transit rate of the FE flows received by the present node 200 from the upstream node 100 in the past time period may be calculated as follows:
wherein Ã{tilde over (As)}(n) is the average transit rate calculated from present time n within the past time period k, and As(i) is transit rate of the FE flows received from the upstream node 100 at time i. Therefore, the propagation delay of traffic flows from further source nodes may be taken into consideration. In addition, since the transit rates in the past time period are taken into consideration, the average transit rate would not vary too much and become more stable.
In step 540, a previous temporal fair rate of the present node 200 is obtained.
In step 550, an effective node number for the present node 200 is calculated according to the average transit rate, the present local arrival rate and the previous temporal fair rate. The effective node number for the present node 200 is number of the nodes transiting data through the present node 200. Since the total transited data are-sum of the transit rate and the local arrival rate, the effective node number for the present node 200 in step 550 may be calculated as follows:
wherein, M(n) is the effective node number at present time n, Ã{tilde over (As)}(n) is the average transit rate calculated in step 530, Aa(n) is the present local arrival rate at present time n. Hence Ã{tilde over (As)}(n)+Aa(n) may be taken as total transit rate, which should be transited through the present node 200. fp(n-1) is previous temporal fair rate at previous time n-1, which can be taken as the transit rate transited by the effective nodes. Therefore, the effective node number can be calculated by the formula above.
In step 560, a present temporal fair rate of the present node is calculated according to the effective node number, the average transit rate and the present local traffic rate. Wherein, the present temporal fair rate of the present node 200 may be calculated as follows:
wherein fp(n) is the present temporal fair rate at present time n, C is available bandwidth of the present node, fp(n-1) is the previous temporal fair rate at previous time n-1, M(n) is the effective node number at present time n, Ã{tilde over (As)}(n) is the average transit rate and Aa(n) is the present local arrival rate at the present time n.
In step 570, a local fair rate table is looked up according to the congestion degree and the present temporal fair rate to obtain a present local fair rate of the present node 200 (step 580). The local fair rate table may be designed under fuzzy set theory.
Table is one embodiment of the local fair rate table designed under fuzzy set theory under fuzzy set theory. In Table 2, fl(n) denotes the present local fair rate of the present node 200. The present temporal fair rate fp(n) may be classified into Extremely Low (EL), Pretty Low (PL), Slightly Low (SL), Slightly High (SH), Pretty High (PH) and Extremely High (EH). The congestion degree of the present node 200 Dp(n) may be Very Low (VL), Low (L), Medium (M), High (H) and Very High (VH). Hence, the obtained present local fair rate of the is present node 200 fl(n) may be Extremely Low (EL), Very Low (VL), Pretty Low (PL), Low (L), Slightly Low (SL), Medium (M), Slightly High (SH), High (H), Pretty High (PH), Very High (VH) or Extremely High (EH). Hence, the present local fair rate of the present node 200 fl(n) may be obtained (step 580) by looking up the local fair rate table (step 570). For example, if the congestion degree Dc(n) determined in step 510 is L and the present temporal fair rate fp(n) calculated in step 560 is classified into EL, the present local fair rate of the present node 200 fl(n) is PL after looking up Table 2. However, the local fair rate table may be designed under another theory, which should not be limited in this disclosure. Therefore, FLFRG 250 may generate the local fair rate utilizing fuzzy set theory by step 510-step 580.
In step 590, the present local fair rate is transmitted to the upstream node 100 by the fairness control unit 210. Before step 590, the fairness control unit 210 may receive a downstream fair rate from the downstream node 300. The available bandwidth in Rinlet-0 for the present node 200 is defined as full rate of the present node 200. The fairness control unit 210 may select the smallest one from the present local fair rate, the downstream fair rate and the full rate of the present node to be transmitted to the upstream node 100. Then, the upstream node 100 may control its data transition rate according to the received fair rate, which can regulate traffic flows transited from the upstream node 100 through Ringlet-0.
In step 600, wait for another time interval to transmit next present local fair rate utilizing step 510-590. Wherein, the present temporal fair rate of the present node calculated in step 560 may be recorded as the previous temporal fair rate to be obtained (step 540) for calculating next effective node number (step 550).
Although the present invention has been described in considerable detail with reference to certain embodiments thereof, other embodiments are possible. Therefore, the spirit and scope of the appended claims should not be limited to the description of the embodiments contained herein. It will be apparent to those skilled in the art that various modifications and variations can be made to the structure of the present invention without departing from the scope or spirit of the invention. In view of the foregoing, it is intended that the present invention cover modifications and variations of this invention provided they fall within the scope of the following claims.