TWI523463B - Network system and load balancing method - Google Patents

Network system and load balancing method Download PDF

Info

Publication number
TWI523463B
TWI523463B TW102120753A TW102120753A TWI523463B TW I523463 B TWI523463 B TW I523463B TW 102120753 A TW102120753 A TW 102120753A TW 102120753 A TW102120753 A TW 102120753A TW I523463 B TWI523463 B TW I523463B
Authority
TW
Taiwan
Prior art keywords
controller
packet
flow
nodes
packet flow
Prior art date
Application number
TW102120753A
Other languages
Chinese (zh)
Other versions
TW201448529A (en
Inventor
劉得彥
Original Assignee
英業達股份有限公司
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 英業達股份有限公司 filed Critical 英業達股份有限公司
Priority to TW102120753A priority Critical patent/TWI523463B/en
Publication of TW201448529A publication Critical patent/TW201448529A/en
Application granted granted Critical
Publication of TWI523463B publication Critical patent/TWI523463B/en

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Description

網路系統及負載平衡方法 Network system and load balancing method

本案是有關於一種電子系統及一種負載平衡方法。特別是一種網路系統及一種負載平衡方法。 This case is about an electronic system and a load balancing method. In particular, it is a network system and a load balancing method.

隨著資訊科技的快速進展,各種型態的網路已被廣泛地應用在人們的生活當中,諸如區域網路、網際網路、以及資料中心網路等。 With the rapid advancement of information technology, various types of networks have been widely used in people's lives, such as regional networks, the Internet, and data center networks.

在部份網路當中(例如資料中心網路),為避免單一鏈結(link)失效而導致封包無法傳輸,多設置有冗餘鏈結(redundancy links)。而為充份利用網路中的頻寬,當前技術可採用等價多路徑(equal cost multiple path)路由方法,以將網路中的流量平均分配到所有鏈結。然而,網路中普遍存在壅塞(congestion)的問題,即是特定鏈結上的資料傳輸量過大,接近相應連接埠的支援速度,而使節點處理不及,導致資料遺失或延遲。而當前的等價多路徑路由中並無解決或避免壅塞的機制,是以如何設計一種負載平衡方法,在特定鏈結發生壅塞時或發生壅塞前,使其上的資料傳輸量下降,而避免資料遺失或延遲、並提昇網路的可靠度是 網路技術中的重要議題。 In some networks (such as the data center network), in order to avoid the failure of a single link, the packets cannot be transmitted, and redundant links are set. To fully utilize the bandwidth in the network, the current technology can employ an equal cost multiple path routing method to evenly distribute traffic across the network to all links. However, there is a widespread congestion problem in the network, that is, the amount of data transmission on a particular link is too large, close to the support speed of the corresponding port, and the node can't handle it, resulting in data loss or delay. However, there is no mechanism for solving or avoiding congestion in the current equivalent multipath routing. How to design a load balancing method to reduce the amount of data transmission on a particular link before it is blocked or before congestion occurs, and avoid Loss or delay of data and improve the reliability of the network is Important issues in network technology.

本發明的一態樣為一種負載平衡方法。根據本發明一實施例,負載平衡方法應用於一網路系統,其中該網路系統包括複數個節點以及一控制器,每一該些節點包括至少一連接埠,該些節點中的相鄰兩者透過該些連接埠形成複數個鏈結。該負載平衡方法包括:該些節點分別傳送一識別資訊以及該些節點之該連接埠的一支援速度至該控制器;該控制器接收該識別資訊以建構出一網路拓樸,並接收該些節點之該連接埠的該支援速度;該控制器監控流過該些節點之該連接埠之一封包流的一封包流流量,並根據該些節點之該連接埠之該封包流的該封包流流量,以判斷該封包流是否為一重載封包流;該控制器分別監控該些節點之該連接埠之一平均流量;當該些節點之該連接埠中的一者之該平均流量超過一壅塞門檻值,且流過該平均流量超過該壅塞門檻值之連接埠的該封包流為該重載封包流時該控制器根據流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流以及該網路拓樸,進行一最短路徑演算法,以得到一新傳輸路徑,其中被計算的該些連接埠中不包括該平均流量超過該壅塞門檻值之連接埠;以及,該控制器將流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流重新規劃至該新傳輸路徑。 One aspect of the invention is a load balancing method. According to an embodiment of the invention, a load balancing method is applied to a network system, wherein the network system includes a plurality of nodes and a controller, each of the nodes including at least one port, and two adjacent ones of the nodes Through the connections, a plurality of links are formed. The load balancing method includes: the nodes respectively transmitting an identification information and a support speed of the connection ports of the nodes to the controller; the controller receives the identification information to construct a network topology, and receives the The support speed of the connection port of the nodes; the controller monitors a packet flow of a packet flow flowing through the connection ports of the nodes, and according to the connection of the packets, the packet of the packet flow Flowing traffic to determine whether the packet flow is a heavy-duty packet flow; the controller separately monitors an average traffic of the ports of the nodes; and when the average traffic of one of the ports of the nodes exceeds a threshold value, and the flow of the packet flowing through the port whose average flow exceeds the threshold value is the weight of the port that exceeds the threshold value of the average flow rate when the packet flow is the heavy load packet flow Carrying a packet flow and the network topology, performing a shortest path algorithm to obtain a new transmission path, wherein the calculated connection ports do not include the average traffic exceeding the congestion threshold Port; and the controller will flow through the ports of the average flow rate exceeds the threshold value of the congestion packet stream overloads re-planning to the new transmission path.

本發明的另一態樣為一種網路系統。根據本發明 一實施例,該網路系統包括複數個節點以及一控制器。每一該些節點包括至少一連接埠,該些節點中的相鄰兩者透過該些連接埠形成複數個鏈結,該些節點用以分別輸出一識別資訊以及該些節點之該連接埠的一支援速度。該控制器用以接收該識別資訊以建構出一網路拓樸,並接收該些節點之該連接埠的該支援速度,且監控該些連接埠之一平均流量,且監控流過該些節點之該連接埠之一封包流的一封包流流量,並根據該些節點之該連接埠之該封包流的該封包流流量,以判斷該封包流是否為一重載封包流。當該些節點之該連接埠中的一者之該平均流量超過一壅塞門檻值,且流過該平均流量超過該壅塞門檻值之連接埠的該封包流為該重載封包流時,該控制器根據流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流以及該網路拓樸,進行一最短路徑演算法,以得到一新傳輸路徑,並將流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流重新規劃至該新傳輸路徑。其中被計算的該些連接埠中不包括該平均流量超過該壅塞門檻值之連接埠。 Another aspect of the invention is a network system. According to the invention In one embodiment, the network system includes a plurality of nodes and a controller. Each of the nodes includes at least one port, and two of the nodes form a plurality of links through the ports, and the nodes are respectively configured to output an identification information and the connection ports of the nodes. A support speed. The controller is configured to receive the identification information to construct a network topology, and receive the support speed of the connection ports of the nodes, and monitor an average traffic of the ports, and monitor the flow of the nodes. A packet flow of the packet flow of the connection port, and the packet flow rate of the packet flow according to the connection of the nodes to determine whether the packet flow is a reload packet flow. When the average traffic of one of the ports of the nodes exceeds a congestion threshold, and the packet flow that flows through the connection whose average traffic exceeds the congestion threshold is the heavy-duty packet flow, the control Performing a shortest path algorithm based on the heavy-duty packet stream flowing through the connection port whose average traffic exceeds the congestion threshold and the network topology to obtain a new transmission path, and the average traffic flow exceeds The reloaded packet stream of the congestion threshold is re-planned to the new transmission path. The ports in which the average flow rate exceeds the threshold value of the congestion threshold are not included in the calculated ports.

綜上所述,透過應用上述一實施例,可實現一種負載平衡方法,其透過監控各連接埠的流量,可在任一連接埠之平均流量超過一壅塞門檻值且該連接埠具有重載封包流時,將此一連接埠中的重載封包流移至其它路徑。另外,透過應用上述一實施例,藉由根據連接埠的支援速度與平均流量計算鏈路成本的方法,流過平均流量超過壅塞門檻值之連接埠的重載封包流可被移至最小鏈路成本路徑,以 使網路系統中的資料流量均勻分配。 In summary, by applying the above embodiment, a load balancing method can be implemented, which can monitor the traffic of each port, and the average traffic in any port exceeds a congestion threshold and the port has a heavy-duty packet flow. Move the overloaded packet stream in one port to another path. In addition, by applying the above embodiment, by calculating the link cost according to the support speed and the average traffic of the port, the reload packet stream flowing through the port whose average traffic exceeds the congestion threshold can be moved to the minimum link. Cost path to Make the data traffic in the network system evenly distributed.

10‧‧‧網路系統 10‧‧‧Network System

100‧‧‧控制器 100‧‧‧ Controller

200‧‧‧負載平衡方法 200‧‧‧ load balancing method

N1-N5‧‧‧節點 N1-N5‧‧‧ node

P11-P52‧‧‧連接埠 P11-P52‧‧‧Connector

L1-L6‧‧‧鏈結 L1-L6‧‧‧ link

S0-S6‧‧‧步驟 S0-S6‧‧‧ steps

第1圖為根據本發明一實施例所繪示的網路系統的示意圖; 1 is a schematic diagram of a network system according to an embodiment of the invention;

第2圖為根據本發明一實施例所繪示的負載平衡方法的流程圖。 FIG. 2 is a flow chart of a load balancing method according to an embodiment of the invention.

以下將以圖式及詳細敘述清楚說明本揭示內容之精神,任何所屬技術領域中具有通常知識者在瞭解本揭示內容之較佳實施例後,當可由本揭示內容所教示之技術,加以改變及修飾,其並不脫離本揭示內容之精神與範圍。 The spirit and scope of the present disclosure will be apparent from the following description of the preferred embodiments of the present disclosure. Modifications do not depart from the spirit and scope of the disclosure.

關於本文中所使用之『第一』、『第二』、…等,並非特別指稱次序或順位的意思,亦非用以限定本案,其僅為了區別以相同技術用語描述的元件或操作。 The use of the terms "first", "second", ", etc." as used herein does not specifically mean the order or the order, and is not intended to limit the present invention. It is merely to distinguish between elements or operations described in the same technical terms.

本發明的一實施態樣為一種網路系統,其可利用控制器監控網路系統中的節點(例如是交換機或路由器)的連接埠之平均流量,以及流經網路系統中的節點的連接埠的封包流(packet flow)的封包流流量,並在任一連接埠之平均流量超過一壅塞門檻值且流經網路系統中的節點的連接埠的封包流為重載封包流時,將此一重載封包流移至其它路徑。 An embodiment of the present invention is a network system that can utilize a controller to monitor an average traffic of a node (e.g., a switch or a router) in a network system, and a connection through a node in the network system. The packet flow rate of the packet flow, and when the average traffic of any port exceeds a congestion threshold and the packet flow flowing through the node in the network system is a heavy-duty packet flow, A heavy-duty packet flows to other paths.

此處所謂封包流,意指網路系統中複數個連續或不連續的封包,具有相同的特徵,例如具有相同的來源位址、目的位址、應用層的來源埠號碼(source port number)及/或應用層的目的埠號碼(destination port number)。其中來源位址及目的位址例如是網際網路協定(internet protocol,IP)位址及/或媒體存取控制(media access control,MAC)位址。 The term "packet flow" as used herein means a plurality of consecutive or discontinuous packets in a network system having the same characteristics, such as having the same source address, destination address, source port number of the application layer, and / or application port number (destination port number). The source address and the destination address are, for example, an internet protocol (IP) address and/or a media access control (MAC) address.

第1圖為根據本發明一實施例所繪示的網路系統10之示意圖。網路系統10包括一控制器100以及複數個節點例如N1-N5。每一節點N1-N5包括至少一連接埠,例如節點N1包括連接埠P11、P12,節點N2包括連接埠P21、P22等。控制器100分別連接每一節點N1-N5。節點N1-N5中的相鄰兩者彼此透過對應的連接埠形成鏈結。例如節點N1與節點N3透過連接埠P11與P31形成鏈結L1,節點N1與節點N4透過連接埠P12與P41形成鏈結L2等。此處所謂相鄰的節點,係指兩個節點可經由單一鏈結彼此連接。另外,上述節點N1-N5可為開放流(openflow)交換機或路由器,上述控制器可為開放流控制器。 FIG. 1 is a schematic diagram of a network system 10 according to an embodiment of the invention. Network system 10 includes a controller 100 and a plurality of nodes such as N1-N5. Each node N1-N5 includes at least one port, for example, node N1 includes ports P11, P12, and node N2 includes ports P21, P22, and the like. The controller 100 is connected to each of the nodes N1-N5. Adjacent ones of the nodes N1-N5 form a link with each other through a corresponding port. For example, the node N1 and the node N3 form a link L1 through the connection ports P11 and P31, and the node N1 and the node N4 form a link L2 and the like through the ports 12P12 and P41. By adjacent nodes herein is meant that two nodes can be connected to each other via a single link. In addition, the above nodes N1-N5 may be open flow switches or routers, and the above controller may be an open flow controller.

在本實施例中,控制器100例如是一電腦。控制器100可發出命令至節點N1-N5,以令節點N1-N5分別輸出一識別資訊以及節點N1-N5之連接埠P11-P52的支援速度至控制器100。接著,控制器100可接收此些識別資訊以建構出相應於網路系統10的網路拓樸以及各個節點N1-N5的連接埠P11-P52的支援速度,其中網路拓樸可意指節點N1-N5之間的連接關係。實施上,控制器100可令節點N1-N5向 其相鄰的節點N1-N5廣播鏈路層發現協議(link layer discovery protocol,LLDP)封包,使相鄰的節點N1-N5間交換識別資訊,而後控制器100可再發送命令至節點N1-N5使其回傳相鄰節點N1-N5的識別資訊,如此一來,控制器100可藉此些識別資訊得知相應於網路系統10的網路拓樸。另一方面,控制器100亦可藉由發送命令至節點N1-N5,使節點N1-N5分別回傳其連接埠P11-P52的支援速度。 In the present embodiment, the controller 100 is, for example, a computer. The controller 100 can issue commands to the nodes N1-N5 to cause the nodes N1-N5 to output an identification information and a support speed of the ports 11P11-P52 of the nodes N1-N5 to the controller 100, respectively. Then, the controller 100 can receive the identification information to construct a network topology corresponding to the network system 10 and the connection speeds of the ports 11P11-P52 of the nodes N1-N5, wherein the network topology can mean a node. The connection relationship between N1-N5. In practice, the controller 100 can make the nodes N1-N5 The adjacent nodes N1-N5 broadcast a link layer discovery protocol (LLDP) packet, so that the adjacent nodes N1-N5 exchange identification information, and then the controller 100 can send a command to the node N1-N5. The identification information of the adjacent nodes N1-N5 is returned, so that the controller 100 can use the identification information to know the network topology corresponding to the network system 10. On the other hand, the controller 100 can also cause the nodes N1-N5 to respectively transmit the support speeds of the ports 11P11-P52 by transmitting commands to the nodes N1-N5.

控制器100可監控連接埠P11-P52之平均流量,例如可定期發送命令至節點N1-N5,以令節點N1-N5傳送其連接埠P11-P52的累計流量至控制器100,控制器100再根據累計流量計算平均流量。 The controller 100 can monitor the average traffic of the ports P11-P52. For example, the commands can be periodically sent to the nodes N1-N5, so that the nodes N1-N5 can transmit the accumulated traffic of the ports P11-P52 to the controller 100, and the controller 100 Calculate the average flow based on the cumulative flow.

另外,控制器100可監控流過連接埠P11-P52之封包流的封包流流量,並根據流過連接埠P11-P52之封包流的封包流流量,以判斷是否有任一流過連接埠P11-P52之封包流為一重載封包流。 In addition, the controller 100 can monitor the flow of the packet flow flowing through the packet flow of the connection port P11-P52, and according to the flow of the packet flow flowing through the packet flow of the connection port P11-P52, to determine whether any flow through the connection port P11- The packet stream of P52 is a heavy-duty packet stream.

舉例而言,控制器100可定期(例如是每30秒)監控所有流過連接埠P11-P52之封包流的封包流流量,並判斷流過連接埠P11-P52之封包流的封包流流量是否連續超過一封包流流量門檻(例如連續兩次超過封包流流量門檻),當有任一流過連接埠P11-P52之封包流的封包流流量連續超過封包流流量門檻,控制器100判斷此一封包流為重載封包流。另外當重載封包流未能連續超過封包流流量門檻時,控制器100可判斷此一封包流已不為重載封包流。 For example, the controller 100 can periodically monitor (for example, every 30 seconds) the packet flow rate of all packet flows flowing through the ports P11-P52, and determine whether the packet flow flow through the packet flow connected to the ports P11-P52 is Continuously exceeds a packet flow threshold (for example, exceeds the packet flow threshold twice in succession), and when any packet flow flowing through the packet flow connected to the ports P11-P52 continuously exceeds the packet flow threshold, the controller 100 determines the packet. The stream is a heavy-duty packet stream. In addition, when the reload packet flow fails to continuously exceed the packet flow threshold, the controller 100 can determine that the packet flow is not a reload packet flow.

接著,當控制器100發現任一連接埠P11-P52的平 均流量超過一個壅塞門檻值時,控制器100可判斷通過此平均流量超過該壅塞門檻值之連接埠P11-P52中是否有封包流為重載封包流。若有,則控制器100可根據流過平均流量超過壅塞門檻值之連接埠的重載封包流以及相應於網路系統10的網路拓樸,進行最短路徑演算法,其中在最短路徑演算法中被計算的連接埠P11-P52不包括前述平均流量超過壅塞門檻值之連接埠P11-P52。如此設置,則控制器100可得到一條新傳輸路徑。而後,控制器100可將流過平均流量超過壅塞門檻值之連接埠的重載封包流重新規劃至此一新傳輸路徑。以令此重載封包流沿著此一新傳輸路徑傳輸。 Then, when the controller 100 finds any connection 埠P11-P52 When the average flow rate exceeds a threshold value, the controller 100 can determine whether the packet flow is a heavy-duty packet flow through the connection port P11-P52 whose average flow rate exceeds the congestion threshold value. If so, the controller 100 can perform the shortest path algorithm based on the reloaded packet stream flowing through the port of the average traffic exceeding the congestion threshold and the network topology corresponding to the network system 10, wherein the shortest path algorithm The ports 11P11-P52 calculated in the middle do not include the aforementioned ports 11P11-P52 whose average flow rate exceeds the 壅plug threshold. With this arrangement, the controller 100 can obtain a new transmission path. Then, the controller 100 can re-plan the reloaded packet stream flowing through the port of the average traffic exceeding the congestion threshold to the new transmission path. So that the reloaded packet stream is transmitted along this new transmission path.

舉例而言,在一狀況下,網路系統10中有一封包流(N1,N2)及另一封包流(N5,N2)同時通過連接埠P32,其中封包流(N1,N2)的來源位址為節點N1、目的位址為節點N2、依據路徑N1→N3→N2傳輸,封包流(N5,N2)的來源位址為節點N5、目的位址為節點N2、依據路徑N5→N3→N2傳輸。其中封包流(N1,N2)為重載封包流。當控制器100發現連接埠P32的平均流量超過壅塞門檻值且通過連接埠P32的封包流(N1,N2)及封包流(N5,N2)中有一者為重載封包流時,控制器100可根據重載封包流(即封包流(N1,N2))進行最短路徑演算法,以得到一條新傳輸路徑,例如是N1→N4→N2。如此一來,則控制器100可使原先連接埠P32中的重載封包流依據新傳輸路徑傳輸,而避免連接埠P32發生壅塞或持續保持壅塞狀態。 For example, in one situation, the network system 10 has a packet flow (N1, N2) and another packet flow (N5, N2) simultaneously connected through the connection P32, wherein the source address of the packet flow (N1, N2) For the node N1, the destination address is the node N2, and according to the path N1→N3→N2, the source address of the packet flow (N5, N2) is the node N5, the destination address is the node N2, and the transmission is according to the path N5→N3→N2. . The packet flow (N1, N2) is a heavy load packet flow. When the controller 100 finds that the average traffic of the port 32P32 exceeds the congestion threshold and one of the packet flow (N1, N2) and the packet flow (N5, N2) connected to the 埠P32 is a heavy-load packet flow, the controller 100 may The shortest path algorithm is performed according to the reloaded packet stream (ie, the packet stream (N1, N2)) to obtain a new transmission path, for example, N1→N4→N2. In this way, the controller 100 can cause the reloaded packet stream in the original port 32P32 to be transmitted according to the new transmission path, and avoid the congestion of the port 32P32 or the continuous stagnation state.

在一實施例中,壅塞門檻值可相應於連接埠 P11-P52的支援速度,例如,當連接埠P32的支援速度為100MBps時,連接埠P32的壅塞門檻值可為100MBps*80%=80MBps。 In an embodiment, the threshold value of the choking may correspond to the connection 埠 The support speed of the P11-P52, for example, when the support speed of the connection P32 is 100 MBps, the congestion threshold of the connection P32 can be 100 MBps*80%=80 MBps.

藉由上述的方法,在網路系統10中任一連接埠P11-P52的平均流量超過壅塞門檻值時,通過其上的的重載封包流可被移至其它路徑,如此以避免壅塞發生或持續性地壅塞,以保持網路系統10的穩定及可靠。 By the above method, when the average traffic of any of the ports P11-P52 in the network system 10 exceeds the congestion threshold, the heavy-duty packet stream passing thereover can be moved to other paths, so as to avoid congestion or Continuous congestion to keep the network system 10 stable and reliable.

以下段落將對前述進行最短路徑演算法作進一步說明。 The following paragraphs will further explain the aforementioned shortest path algorithm.

在一實施例中,前述進行最短路徑演算法的方法例如是:控制器100根據前述流過平均流量超過壅塞門檻值之連接埠的重載封包流以及相應於網路系統10的網路拓樸分別找出流過平均流量超過壅塞門檻值之連接埠的重載封包流之複數個準傳送路徑,並分別計算此些準傳送路徑之路徑成本,而後控制器100選出此些準傳送路徑中路徑成本最小者作為流過平均流量超過壅塞門檻值之連接埠的重載封包流的新傳輸路徑。 In an embodiment, the foregoing method for performing the shortest path algorithm is, for example, the controller 100 according to the foregoing, the overloaded packet flow that flows through the connection port whose average traffic exceeds the congestion threshold and the network topology corresponding to the network system 10. Finding a plurality of quasi-transmission paths of the reloaded packet flows through the ports whose average traffic exceeds the congestion threshold, respectively, and calculating the path costs of the quasi-transport paths, and then the controller 100 selects the paths in the quasi-transport paths. The lowest cost is the new transmission path of the reloaded packet stream flowing through the port of the average traffic exceeding the congestion threshold.

在另一實施例中,前述進行最短路徑演算法的方法例如是控制器100對前述流過平均流量超過壅塞門檻值之連接埠的重載封包流執行代克思托演算法(Dijkstra algorithm),以找出此重載封包流的新傳輸路徑。其中在執行代克思托演算法時,可透過將平均流量超過壅塞門檻值的連接埠P11-P52所對應的鏈結L1-L6移除(例如可將連接埠P32所對應的鏈結L3移除),以避免新傳輸路徑經過平均 流量超過壅塞門檻值的連接埠P11-P52所對應的鏈結L1-L6。 In another embodiment, the foregoing method for performing the shortest path algorithm is, for example, the controller 100 performing a Dijkstra algorithm on the reloaded packet stream flowing through the port of the average flow exceeding the congestion threshold. To find out the new transmission path for this overloaded packet stream. In the execution of the Dexter algorithm, the links L1-L6 corresponding to the connection 埠P11-P52 whose average flow exceeds the congestion threshold can be removed (for example, the link L3 corresponding to the connection 埠P32 can be moved) In addition to avoid the new transmission path through the average The links L1-L6 corresponding to the ports 11P11-P52 whose flow rate exceeds the threshold value.

再者,在一實施例中,當任一連接埠P11-P52之平均流量超過壅塞門檻值時,控制器100可根據連接埠P11-P52之平均流量與連接埠P11-P52的支援速度分別計算鏈結L1-L6的鏈路成本,並以鏈結L1-L6的鏈路成本為權重值(weight)對流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流進行最短路徑演算法,以找出此重載封包流的新傳輸路徑。其中在進行最短路徑演算法時,控制器100可排除平均流量超過壅塞門檻值的連接埠P11-P52所對應的鏈結L1-L6,以使新傳輸路徑不經過平均流量超過壅塞門檻值的連接埠P11-P52對應的鏈結L1-L6。例如,在進行最短路徑演算法時,控制器100可將平均流量超過壅塞門檻值的連接埠P11-P52所對應的鏈結L1-L6移除或將其鏈路成本設為無限大。 Furthermore, in an embodiment, when the average flow rate of any of the ports P11-P52 exceeds the threshold value, the controller 100 can calculate the average flow rate of the ports P11-P52 and the support speeds of the ports P11-P52, respectively. The link cost of the link L1-L6, and the link cost of the link L1-L6 as the weight value (weight) for the shortest path calculation of the heavy-duty packet flow flowing through the connection 埠P11-P52 whose average flow exceeds the congestion threshold Method to find the new transmission path for this overloaded packet stream. When performing the shortest path algorithm, the controller 100 can exclude the links L1-L6 corresponding to the ports 11P11-P52 whose average flow exceeds the congestion threshold, so that the new transmission path does not pass the connection whose average flow exceeds the congestion threshold.链P11-P52 corresponds to the links L1-L6. For example, when performing the shortest path algorithm, the controller 100 may remove the links L1-L6 corresponding to the ports 11P11-P52 whose average traffic exceeds the congestion threshold or set the link cost to infinity.

另外,在一實施例中,鏈結L1-L6的鏈路成本的計算方法例如是:控制器100用連接埠P11-P52的支援速度減去其當前平均流量,以求得連接埠P11-P52的剩餘流量,接著,控制器100用連接埠P11-P52的剩餘流量除以連接埠P11-P52的支援速度,以求得相應於連接埠P11-P52的鏈結L1-L6之鏈路成本。 In addition, in an embodiment, the link cost calculation method of the links L1-L6 is, for example, the controller 100 subtracts its current average flow rate from the support speed of the connection port P11-P52 to obtain the connection port P11-P52. The remaining flow rate is then divided by the remaining flow rate of the port 11P11-P52 by the support speed of the port 11P11-P52 to determine the link cost corresponding to the links L1-L6 of the ports 11P11-P52.

透過上述的操作,可使流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流被移至鏈路成本的新傳輸路徑,以使網路系統10中的資料流量被均勻分配。 Through the above operation, the reloaded packet stream flowing through the ports P11-P52 whose average flow rate exceeds the congestion threshold value can be moved to the new transmission path of the link cost, so that the data traffic in the network system 10 is evenly distributed. .

以下段落將對前述連接埠P11-P52之平均流量的監控作進一步說明。 The following paragraphs will further illustrate the monitoring of the average flow of the aforementioned ports P11-P52.

在本發明一實施例中,節點N1-N5可分別儲存統計資料,統計資料可包括各節點N1-N5上各連接埠P11-P52的累計流量(如累計傳送位元組)。控制器100可定期接收各節點N1-N5上各連接埠P11-P52的累計流量,並用最新接收的累計流量與次新接收的累計流量之差除以兩次接收累計流量的時間間隔,以求得連接埠P11-P52當前的平均流量。 In an embodiment of the invention, the nodes N1-N5 may respectively store statistical data, and the statistical data may include accumulated traffic (for example, cumulative transmission byte groups) of each port 11P11-P52 on each node N1-N5. The controller 100 can periodically receive the accumulated traffic of each port 11P11-P52 on each node N1-N5, and divide the difference between the latest received cumulative traffic and the newly received accumulated traffic by the time interval between receiving the accumulated traffic twice. It is necessary to connect the current average traffic of the P11-P52.

舉例而言,控制器100可在第一時間點(如第0秒時)分別接收節點N1-N5的連接埠P11-P52的第一累計流量,接著在一段預設時間(如30秒)後,控制器100可在第二時間點(如第30秒時)分別接收節點N1-N5的連接埠P11-P52的第二累計流量。接著,控制器100可用上述連接埠P11-P52的第一、第二累計流量的差除以第一、第二時間點的差,以求得連接埠P11-P52的平均流量。 For example, the controller 100 may receive the first accumulated traffic of the ports 11P11-P52 of the nodes N1-N5 at the first time point (eg, at the 0th second), and then after a preset time (eg, 30 seconds) The controller 100 may receive the second accumulated flow of the ports 11P11-P52 of the nodes N1-N5 at the second time point (eg, at the 30th second). Next, the controller 100 divides the difference between the first and second accumulated flows of the ports 11P11-P52 by the difference between the first and second time points to determine the average flow rate of the ports 11P11-P52.

以下段落將對前述使流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流依據新傳輸路徑傳輸的細節作進一步說明。 The following paragraphs will further illustrate the details of the transfer of the reloaded packet stream flowing through the ports P11-P52 having an average flow exceeding the congestion threshold in accordance with the new transmission path.

在本發明一實施例中,節點N1-N5可各包括一個轉送表,用以儲存零至多筆封包轉送規則,節點N1-N5可根據此些封包轉送規則轉送封包,且每筆封包轉送規則可各自記錄其累計流量及其傳輸時間。藉由上述設置,於各節點N1-N5中,轉送表中的一或多筆封包轉送規則可分別對應通過此一節點的一或多條封包流,而封包流流量例如 是但不限於對應封包轉送規則中累計流量除以傳輸時間。 In an embodiment of the present invention, the nodes N1-N5 may each include a forwarding table for storing zero to more packet forwarding rules, and the nodes N1-N5 may forward the packets according to the packet forwarding rules, and each packet forwarding rule may be Each records its cumulative flow and its transmission time. With the above setting, in each of the nodes N1-N5, one or more packet forwarding rules in the forwarding table may respectively correspond to one or more packet flows through the node, and the packet flow rate is, for example, Yes, but not limited to, the cumulative traffic in the corresponding packet forwarding rule divided by the transmission time.

當連接埠P11-P52中的一者之平均流量超過壅塞門檻值,且流過平均流量超過壅塞門檻值之連接埠P11-P52的封包流為重載封包流時,控制器100可根據對應於流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流的封包轉送規則,找出此一重載封包流的來源節點以及目的節點。接著,根據流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流的來源節點以及目的節點,控制器100可在所有節點N1-N5之轉送表中比對出此一重載封包流的一條原始路徑。 When the average flow rate of one of the ports 11P11-P52 exceeds the 壅plug threshold, and the packet flow of the port 11P11-P52 flowing through the average flow rate exceeding the 壅 槛 threshold is a heavy load packet flow, the controller 100 may correspond to The packet forwarding rule of the reload packet stream of the port 11P11-P52 whose average traffic exceeds the congestion threshold is found, and the source node and the destination node of the reload packet stream are found. Then, according to the source node and the destination node of the reload packet flow flowing through the ports P11-P52 whose average flow exceeds the congestion threshold, the controller 100 can compare the overloads in the transfer tables of all the nodes N1-N5. An original path to the packet stream.

而控制器100得到新傳輸路徑後,控制器100可根據此新傳輸路徑,把相應的封包轉送規則寫入此新傳輸路徑所經過的節點N1-N5之轉送表,並且,在原始路徑所經過的節點N1-N5之轉送表中,將對應於原始路徑的封包轉送規則刪除。如此一來,流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流即可依新傳輸路徑傳輸。 After the controller 100 obtains the new transmission path, the controller 100 can write the corresponding packet forwarding rule to the forwarding table of the node N1-N5 through which the new transmission path passes according to the new transmission path, and pass through the original path. In the forwarding table of the nodes N1-N5, the packet forwarding rule corresponding to the original path is deleted. In this way, the reloaded packet stream flowing through the ports P11-P52 whose average traffic exceeds the congestion threshold can be transmitted according to the new transmission path.

本發明的另一實施態樣為一種負載平衡方法。此負載平衡方法可用於結構與前述第1圖中相同或類似的網路系統。為方便說明,下述操作方法係以第1圖所示之實施例為例進行描述,但並不以第1圖之實施例為限。 Another embodiment of the invention is a load balancing method. This load balancing method can be applied to a network system having the same or similar structure as in the foregoing Fig. 1. For convenience of description, the following operation method is described by taking the embodiment shown in FIG. 1 as an example, but is not limited to the embodiment of FIG. 1.

當注意到,在以下操作方法中的步驟中,除非另行述明,否則並不具有特定順序。另外,以下步驟亦可能被同時執行,或者於執行時間上有所重疊。 It is noted that in the steps of the following methods of operation, there is no particular order unless otherwise stated. In addition, the following steps may also be performed simultaneously or overlap in execution time.

第2圖為根據本發明一實施例所繪示的負載平衡 方法200。負載平衡方法200可包括步驟S0-S7。 FIG. 2 is a diagram of load balancing according to an embodiment of the invention. Method 200. The load balancing method 200 can include steps S0-S7.

於步驟S0中,節點N1-N5可傳送識別資訊以及節點N1-N5之連接埠P11-P52的支援速度至控制器100。 In step S0, the nodes N1-N5 can transmit the identification information and the support speed of the ports 11P11-P52 of the nodes N1-N5 to the controller 100.

在步驟S1中,控制器100可接收節點N1-N5傳送的識別資訊以建構出相應於網路系統10的網路拓樸並接收節點N1-N5傳送的連接埠P11-P52的支援速度。舉例而言,控制器100可令節點N1-N5向其相鄰的節點N1-N5廣播鏈路層發現協議(link layer discovery protocol,LLDP)封包,使相鄰的節點N1-N5間交換識別資訊,而後控制器100可再發送命令至節點N1-N5使其回傳相鄰節點N1-N5的識別資訊,如此則控制器100可藉此些識別資訊得知相應於網路系統10的網路拓樸。控制器100亦可藉由發送一命令至節點N1-N5,使節點N1-N5分別回傳其連接埠P11-P52的支援速度。 In step S1, the controller 100 can receive the identification information transmitted by the nodes N1-N5 to construct a support speed corresponding to the network topology of the network system 10 and receive the ports 11P11-P52 transmitted by the nodes N1-N5. For example, the controller 100 can cause the nodes N1-N5 to broadcast a link layer discovery protocol (LLDP) packet to the neighboring nodes N1-N5, so that the adjacent nodes N1-N5 exchange identification information. Then, the controller 100 can resend the command to the nodes N1-N5 to transmit the identification information of the neighboring nodes N1-N5, so that the controller 100 can use the identification information to know the network corresponding to the network system 10. Topology. The controller 100 can also cause the nodes N1-N5 to respectively transmit the support speeds of the ports 11P11-P52 by transmitting a command to the nodes N1-N5.

於步驟S2中,控制器100可監控流過連接埠P11-P52之封包流的封包流流量,並根據流過連接埠P11-P52之封包流的封包流流量,以判斷是否有任一流過連接埠P11-P52之封包流為一重載封包流。 In step S2, the controller 100 can monitor the flow of the packet flow flowing through the packet flow of the connection port P11-P52, and determine whether there is any flow connection according to the flow of the packet flow flowing through the packet flow of the connection port P11-P52. The packet flow of 埠P11-P52 is a heavy-duty packet stream.

於步驟S3中,控制器100可監控連接埠P11-P52之平均流量。例如控制器100可定期發送命令至節點N1-N5,以令節點N1-N5傳送其連接埠P11-P52的累計流量至控制器100,控制器100再根據累計流量計算平均流量。當注意到,步驟S2、S3的執行順序可對調。 In step S3, the controller 100 can monitor the average flow rate of the ports 11P11-P52. For example, the controller 100 may periodically send commands to the nodes N1-N5 to cause the nodes N1-N5 to transmit the accumulated traffic of their ports 11P11-P52 to the controller 100, and the controller 100 calculates the average traffic based on the accumulated traffic. When noted, the order of execution of steps S2, S3 can be reversed.

於步驟S4中,控制器100可判斷是否有任一連接 埠P11-P52的平均流量超過壅塞門檻且判斷通過此平均流量超過該壅塞門檻值之連接埠P11-P52中是否有封包流為重載封包流。若否,則控制器100持續監控流過連接埠P11-P52之封包流的封包流流量與連接埠P11-P52之平均流量;若是,則控制器100可根據流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流以及相應於網路系統10的網路拓樸,進行最短路徑演算法,以找出一條新傳輸路徑。其中在最短路徑演算法中被計算的連接埠P11-P52不包括前述平均流量超過壅塞門檻值之連接埠P11-P52(步驟S5)。當注意到,壅塞門檻值可相應於連接埠P11-P52的支援速度。再著,上述封包流的相關細節可參照前一實施態樣,在此不再贅述。 In step S4, the controller 100 can determine whether there is any connection. 平均 The average flow rate of P11-P52 exceeds the congestion threshold and it is judged whether or not the packet flow is a heavy-duty packet flow through the connection port P11-P52 whose average flow rate exceeds the congestion threshold value. If not, the controller 100 continuously monitors the packet flow rate of the packet flow flowing through the ports P11-P52 and the average flow rate of the ports P11-P52; if so, the controller 100 can exceed the congestion threshold according to the average flow rate. The shortest path algorithm is used to find a new transmission path by connecting the heavy-duty packet stream of the P11-P52 and the network topology corresponding to the network system 10. The ports 11P11-P52 calculated in the shortest path algorithm do not include the aforementioned ports 11P11-P52 whose average flow rate exceeds the 壅 槛 threshold (step S5). When noted, the congestion threshold can correspond to the support speed of the ports P11-P52. Further, the details of the above packet flow can be referred to the previous embodiment, and details are not described herein again.

接著,於步驟S6中,控制器100可將流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流重新規劃至此一新傳輸路徑,以令前述最大流量封包流沿著此一新傳輸路徑傳輸。 Then, in step S6, the controller 100 may re-plan the reload packet flow flowing through the ports P11-P52 whose average flow exceeds the congestion threshold to the new transmission path, so that the maximum flow packet flow along the first New transmission path transmission.

藉由上述的方法,在網路系統10中任一連接埠P11-P52的平均流量超過壅塞門檻值時,通過其上的的重載封包流可被移至其它路徑,如此以避免壅塞發生或持續性地壅塞,以保持網路系統10的穩定及可靠。 By the above method, when the average traffic of any of the ports P11-P52 in the network system 10 exceeds the congestion threshold, the heavy-duty packet stream passing thereover can be moved to other paths, so as to avoid congestion or Continuous congestion to keep the network system 10 stable and reliable.

根據本發明一實施例,在步驟S2中,控制器100可定期(例如是每30秒)監控所有流過連接埠P11-P52之封包流的封包流流量,並判斷流過連接埠P11-P52之封包流的封包流流量是否連續超過一封包流流量門檻(例如連續兩次超 過封包流流量門檻),當有任一流過連接埠P11-P52之封包流的封包流流量連續超過封包流流量門檻,控制器100判斷此一封包流為重載封包流。另外當重載封包流未能連續超過封包流流量門檻時,控制器100可判斷此一封包流已不為重載封包流。 According to an embodiment of the present invention, in step S2, the controller 100 can periodically monitor (for example, every 30 seconds) the packet flow rate of all packet flows flowing through the ports P11-P52, and determine that the flow passes through the port P11-P52. Whether the packet flow rate of the packet flow continuously exceeds a packet flow threshold (for example, two consecutive times When the packet flow rate of the packet flow flowing through the connection port P11-P52 continuously exceeds the packet flow rate threshold, the controller 100 determines that the packet flow is a heavy load packet flow. In addition, when the reload packet flow fails to continuously exceed the packet flow threshold, the controller 100 can determine that the packet flow is not a reload packet flow.

根據本發明一實施例,在步驟S5中,控制器100可根據連接埠P11-P52之平均流量與此連接埠P11-P52的支援速度分別計算鏈結L1-L6的鏈路成本,並以鏈結L1-L6的鏈路成本為權重值(weight)對流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流進行最短路徑演算法,以找出此重載封包流的新傳輸路徑。 According to an embodiment of the present invention, in step S5, the controller 100 can calculate the link cost of the links L1-L6 according to the average flow rate of the ports 11P11-P52 and the support speed of the port 11P11-P52, respectively, and The link cost of the junction L1-L6 is the weight value (weight) for the shortest path algorithm of the reloaded packet stream flowing through the connection 埠P11-P52 with the average traffic exceeding the congestion threshold to find the new transmission of the reload packet stream. path.

其中在進行最短路徑演算法時,控制器100可排除平均流量超過壅塞門檻值的連接埠P11-P52所對應的鏈結L1-L6,以使新傳輸路徑不經過平均流量超過壅塞門檻值的連接埠P11-P52對應的鏈結L1-L6。例如,在進行最短路徑演算法時,控制器100可將平均流量超過壅塞門檻值的連接埠P11-P52所對應的鏈結L1-L6移除或將其鏈路成本設為無限大。 When performing the shortest path algorithm, the controller 100 can exclude the links L1-L6 corresponding to the ports 11P11-P52 whose average flow exceeds the congestion threshold, so that the new transmission path does not pass the connection whose average flow exceeds the congestion threshold.链P11-P52 corresponds to the links L1-L6. For example, when performing the shortest path algorithm, the controller 100 may remove the links L1-L6 corresponding to the ports 11P11-P52 whose average traffic exceeds the congestion threshold or set the link cost to infinity.

根據本發明一實施例,在步驟S5中,前述進行最短路徑演算法的方法例如是:控制器100根據流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流以及相應於網路系統10的網路拓樸分別找出流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流之複數個準傳送路徑,並分別計算此些準傳送路徑之路徑成本,而後控制器 100選出此些準傳送路徑中路徑成本最小者作為流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流的新傳輸路徑。 According to an embodiment of the present invention, in the step S5, the method for performing the shortest path algorithm is, for example, the controller 100 according to the reload packet flow flowing through the ports P11-P52 whose average traffic exceeds the congestion threshold and corresponding to the network. The network topology of the road system 10 respectively finds a plurality of quasi-transmission paths through the reload packet flow of the ports P11-P52 whose average traffic exceeds the congestion threshold, and calculates the path costs of the quasi-transport paths respectively, and then Controller 100 selects the new one of the quasi-transport paths with the lowest path cost as the new transport path of the reloaded packet stream flowing through the ports P11-P52 whose average traffic exceeds the congestion threshold.

例如,控制器100可分別加總上述準傳送路徑所經過的鏈結L1-L6的鏈路成本,以計算出此些準傳送路徑的錄路成本總和作為路徑成本,而後控制器100選出此些準傳送路徑中路徑成本最小者作為流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流的新傳輸路徑。 For example, the controller 100 may add the link costs of the links L1-L6 through which the quasi-transport path passes, respectively, to calculate the sum of the recorded costs of the quasi-transport paths as the path cost, and then the controller 100 selects these The path cost of the quasi-transport path is the smallest as the new transmission path of the reload packet stream flowing through the ports P11-P52 whose average traffic exceeds the congestion threshold.

根據本發明另一實施例,前述進行最短路徑演算法的方法例如是控制器100以鏈結L1-L6的鏈路成本為權重值,對流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流執行代克思托演算法,以找出流過平均流量超過壅塞門檻值之連接埠的重載封包流的新傳輸路徑。其中在執行代克思托演算法時,可透過將平均流量超過壅塞門檻值的連接埠P11-P52所對應的鏈結L1-L6移除或將其鏈路成本設為無限大,以避免新傳輸路徑經過平均流量超過壅塞門檻值的連接埠P11-P52所對應的鏈結L1-L6。 According to another embodiment of the present invention, the foregoing method for performing the shortest path algorithm is, for example, that the controller 100 uses the link cost of the links L1-L6 as a weight value for the port 11P11-P52 that flows through the average flow rate exceeding the congestion threshold. The reloaded packet stream performs a Dexter algorithm to find a new transmission path for a reloaded packet stream that flows through a port whose average traffic exceeds the congestion threshold. In the implementation of the Dexter algorithm, the link L1-L6 corresponding to the connection 埠P11-P52 whose average flow exceeds the congestion threshold can be removed or the link cost can be set to infinity to avoid new The transmission path passes through the links L1-L6 corresponding to the ports 11P11-P52 whose average flow rate exceeds the threshold value.

再者,鏈結L1-L6的鏈路成本的計算方法例如是:控制器100用連接埠P11-P52的支援速度減去其當前平均流量,以求得連接埠P11-P52的剩餘流量,接著,用連接埠P11-P52的剩餘流量除以連接埠P11-P52的支援速度,以求得相應於連接埠P11-P52的鏈結L1-L6之鏈路成本。 Furthermore, the link cost of the links L1-L6 is calculated, for example, by the controller 100 subtracting its current average flow rate from the support speed of the port 11P11-P52 to obtain the remaining flow rate of the port 11P11-P52, and then The remaining flow rate of the port 11P11-P52 is divided by the support speed of the port 11P11-P52 to obtain the link cost corresponding to the links L1-L6 of the ports 11P11-P52.

藉由上述的方法,在網路系統10中任一連接埠P11-P52的平均流量超過壅塞門檻值時,流過平均流量超過 壅塞門檻值之連接埠P11-P52的重載封包流可被移至鏈路成本為最小的新傳送路徑,如此以避免壅塞發生或持續性地壅塞,使網路系統10中的資料流量被均勻分配,並保持網路系統10的穩定及可靠。 By the above method, when the average flow rate of any of the ports P11-P52 in the network system 10 exceeds the threshold value, the average flow rate exceeds The congestion port of the congestion threshold P11-P52 can be moved to a new transmission path with the lowest link cost, so as to avoid congestion or persistent congestion, and the data traffic in the network system 10 is evenly distributed. Allocate and maintain the stability and reliability of the network system 10.

在本發明的一實施例中,於步驟S3中,控制器100可定期接收各節點N1-N5上各連接埠P11-P52的累計流量,並用最新接收的累計流量與次新接收的累計流量之差除以兩次接收累計流量的時間間隔,以求得連接埠P11-P52當前的平均流量。舉例而言,控制器100可在第一時間點(如第0秒時)分別接收節點N1-N5的連接埠P11-P52的第一累計流量,接著在一段預設時間(如30秒)後,控制器100可在第二時間點(如第30秒時)分別接收節點N1-N5的連接埠P11-P52的第二累計流量。而後,控制器100可用上述連接埠P11-P52的第一、第二累計流量的差除以第一、第二時間點的差,以求得連接埠P11-P52的平均流量。當注意到,上述預設時間相應於控制器100接收各連接埠P11-P52的累計流量之頻率,其可視實施情況作調整,不以上述實施例為限。 In an embodiment of the present invention, in step S3, the controller 100 can periodically receive the accumulated traffic of each port 11P11-P52 on each node N1-N5, and use the newly received accumulated traffic and the newly received accumulated traffic. The difference is divided by the time interval at which the cumulative flow is received twice to find the current average flow rate of the ports 11P11-P52. For example, the controller 100 may receive the first accumulated traffic of the ports 11P11-P52 of the nodes N1-N5 at the first time point (eg, at the 0th second), and then after a preset time (eg, 30 seconds) The controller 100 may receive the second accumulated flow of the ports 11P11-P52 of the nodes N1-N5 at the second time point (eg, at the 30th second). Then, the controller 100 divides the difference between the first and second accumulated flows of the ports 11P11-P52 by the difference between the first and second time points to obtain the average flow rate of the ports 11P11-P52. It is noted that the preset time corresponds to the frequency at which the controller 100 receives the accumulated traffic of each port P11-P52, which may be adjusted according to the implementation, and is not limited to the above embodiment.

另外,在本發明的一實施例中,步驟S6可更包括以下步驟。控制器100例如是根據對應於流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流的封包轉送規則,找出流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流的來源節點以及目的節點。接著,根據流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流的 來源節點以及目的節點,控制器100可在所有節點N1-N5之轉送表中比對出通過此重載封包流的一條原始路徑。其中,轉送表與封包轉送規則的相關細節可參照前一實施態樣,在此不再贅述。 In addition, in an embodiment of the present invention, step S6 may further include the following steps. The controller 100, for example, finds the weight of the port 11P11-P52 flowing through the average flow rate exceeding the 壅 槛 threshold value according to the packet transfer rule corresponding to the reload packet flow of the port 11 P11-P52 flowing through the average flow rate exceeding the 壅 槛 threshold value. The source node of the packet stream and the destination node. Then, according to the flow of the heavy-duty packet flowing through the ports P11-P52 whose average flow rate exceeds the threshold value The source node and the destination node, the controller 100 can compare an original path through the reload packet stream in the forwarding table of all nodes N1-N5. For details of the forwarding table and the packet forwarding rule, reference may be made to the previous embodiment, and details are not described herein again.

而控制器100得到新傳輸路徑後,控制器100可根據此新傳輸路徑,把相應的封包轉送規則寫入此新傳輸路徑所經過的節點N1-N5之轉送表,並且,在原始路徑所經過的節點N1-N5之轉送表中,將對應於原始路徑的封包轉送規則刪除。如此一來,流過平均流量超過壅塞門檻值之連接埠P11-P52的重載封包流即可依新傳輸路徑傳輸。 After the controller 100 obtains the new transmission path, the controller 100 can write the corresponding packet forwarding rule to the forwarding table of the node N1-N5 through which the new transmission path passes according to the new transmission path, and pass through the original path. In the forwarding table of the nodes N1-N5, the packet forwarding rule corresponding to the original path is deleted. In this way, the reloaded packet stream flowing through the ports P11-P52 whose average traffic exceeds the congestion threshold can be transmitted according to the new transmission path.

雖然本案已以實施例揭露如上,然其並非用以限定本案,任何熟習此技藝者,在不脫離本案之精神和範圍內,當可作各種之更動與潤飾,因此本案之保護範圍當視後附之申請專利範圍所界定者為準。 Although the present invention has been disclosed in the above embodiments, it is not intended to limit the present case. Anyone skilled in the art can make various changes and refinements without departing from the spirit and scope of the present case. The scope defined in the patent application is subject to change.

200‧‧‧負載平衡方法 200‧‧‧ load balancing method

S0-S6‧‧‧步驟 S0-S6‧‧‧ steps

Claims (10)

一種負載平衡方法,應用於一網路系統,其中該網路系統包括複數個節點以及一控制器,該控制器分別電性耦接至該些節點,每一該些節點包括至少一連接埠,該些節點中的相鄰兩者透過該些連接埠形成複數個鏈結,該負載平衡方法包括:該些節點分別傳送一識別資訊以及該些節點之該連接埠的一支援速度至該控制器;該控制器接收該識別資訊以建構出一網路拓樸,並接收該些節點之該連接埠的該支援速度;該控制器監控流過該些節點之該連接埠之一封包流的一封包流流量,並根據該些節點之該連接埠之該封包流的該封包流流量,以判斷該封包流是否為一重載封包流;該控制器分別監控該些節點之該連接埠之一平均流量;當該些節點之該連接埠中的一者之該平均流量超過一壅塞門檻值,且流過該平均流量超過該壅塞門檻值之連接埠的該封包流為該重載封包流時,該控制器根據流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流以及該網路拓樸,進行一最短路徑演算法,以得到一新傳輸路徑,其中被計算的該些連接埠中不包括該平均流量超過該壅塞門檻值之連接埠;以及該控制器將流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流重新規劃至該新傳輸路徑。 A load balancing method is applied to a network system, where the network system includes a plurality of nodes and a controller, the controllers are electrically coupled to the nodes, and each of the nodes includes at least one port. The two adjacent nodes form a plurality of links through the ports, and the load balancing method includes: the nodes respectively transmitting an identification information and a support speed of the connection ports of the nodes to the controller The controller receives the identification information to construct a network topology and receives the support speed of the connection port of the nodes; the controller monitors a packet flow of the connection port flowing through the nodes Packet flow traffic, and according to the packet flow rate of the packet flow of the connection node of the nodes, to determine whether the packet flow is a heavy load packet flow; the controller separately monitors one of the connection ports of the nodes Average flow rate; when the average flow rate of one of the ports of the nodes exceeds a congestion threshold, and the flow of the packet flowing through the connection whose average flow exceeds the congestion threshold is The controller performs a shortest path algorithm to obtain a new transmission path according to the heavy-duty packet flow flowing through the connection port whose average flow exceeds the congestion threshold and the network topology. The calculated ports do not include the port whose average flow exceeds the threshold value; and the controller re-plans the flow of the heavy-duty packet flowing through the port whose average flow exceeds the threshold value to the New transmission path. 如請求項1所述的負載平衡方法,其中該控制器監控流過該些節點之該連接埠之該封包流的該封包流流量,並根據該些節點之該連接埠之該封包流的該封包流流量,以判斷該封包流是否為該重載封包流的步驟包括:該控制器定期監控流過該些節點之該連接埠之該封包流的該封包流流量,並判斷流過該些節點之該連接埠之該封包流的該封包流流量是否連續超過一封包流流量門檻;以及當流過該些節點之該連接埠之該封包流的該封包流流量連續超過該封包流流量門檻,該控制器判斷該封包流為該重載封包流。 The load balancing method of claim 1, wherein the controller monitors the packet flow of the packet flow flowing through the connection ports of the nodes, and according to the connection flow of the connection ports of the nodes The step of packet flow to determine whether the packet flow is the reload packet flow includes: the controller periodically monitoring the flow of the packet flow of the packet flow flowing through the connection ports of the nodes, and determining that the flow flows through the packet flow Whether the flow of the packet flow of the packet flow of the node exceeds a packet flow threshold; and the flow of the packet flow of the packet flow flowing through the connection of the nodes continuously exceeds the threshold of the flow of the packet flow The controller determines that the packet stream is the reload packet stream. 如請求項1所述的負載平衡方法,其中該控制器進行該最短路徑演算法的步驟包括:該控制器根據流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流以及該網路拓樸,找出流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流之複數個準傳送路徑;該控制器分別計算該些準傳送路徑之一路徑成本;以及該控制器選出該些準傳送路徑中該路徑成本為最小者。 The load balancing method of claim 1, wherein the step of the controller performing the shortest path algorithm comprises: the controller according to the overloaded packet flow flowing through the connection port whose average traffic exceeds the congestion threshold and a network topology for finding a plurality of quasi-transport paths of the reload packet stream flowing through the port whose average traffic exceeds the congestion threshold; the controller separately calculating a path cost of the one of the quasi-transport paths; The controller selects the minimum cost of the path in the quasi-transport paths. 如請求項1所述的負載平衡方法,其中該控制器進行該最短路徑演算法的步驟包括:該控制器找出流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流的一來源節點、一目的節點以及該來源節點與該目的節點之間的一原始路徑;其中該控制器將流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流重新規劃至該新傳輸路徑的步驟包括:該控制器將至少一封包轉送規則分別寫入該新傳輸路徑所經過的節點之轉送表;以及在該原始路徑所經過的節點之轉送表中,該控制器將對應於該原始路徑的封包轉送規則刪除。 The load balancing method of claim 1, wherein the step of the controller performing the shortest path algorithm comprises: the controller finding a flow of the reloaded packet flowing through the port of the average traffic exceeding the congestion threshold a source node, a destination node, and an original path between the source node and the destination node; wherein the controller re-plans the flow of the overloaded packet flowing through the port whose average traffic exceeds the congestion threshold to The step of the new transmission path includes: the controller writing at least one packet forwarding rule to the forwarding table of the node through which the new transmission path passes; and in the forwarding table of the node through which the original path passes, the controller will correspond The packet forwarding rule of the original path is deleted. 如請求項1所述的負載平衡方法,更包括:當該些連接埠中的一者之該平均流量超過該壅塞門檻值時,該控制器根據該平均流量超過該壅塞門檻值之連接埠之該平均流量與該平均流量超過該壅塞門檻值之連接埠的該支援速度分別計算該些鏈結的一鏈路成本;其中該控制器根據流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流以及該網路拓樸,進行該最短路徑演算法的步驟包括:該控制器以該些鏈結的該鏈路成本為權重值(weight),進行該最短路徑演算法,以規劃出該新傳輸路徑。 The load balancing method of claim 1, further comprising: when the average traffic of one of the ports exceeds the congestion threshold, the controller exceeds the connection threshold according to the average traffic. Calculating a link cost of the links respectively, the average flow rate and the support speed of the connection with the average flow rate exceeding the congestion threshold value; wherein the controller is based on the connection port that exceeds the congestion threshold value The step of performing the shortest path algorithm includes: the controller performing the shortest path algorithm by using the link cost of the links as a weight path, to perform the shortest path algorithm Plan the new transmission path. 一種網路系統,包括:複數個節點,其中每一該些節點包括至少一連接埠,該些節點中的相鄰兩者透過該些連接埠形成複數個鏈結,該些節點用以分別輸出一識別資訊以及該些節點之該連接埠的一支援速度;以及一控制器,用以接收該識別資訊以建構出一網路拓樸,並接收該些節點之該連接埠的該支援速度,且監控該些連接埠之一平均流量,且監控流過該些節點之該連接埠之一封包流的一封包流流量,並根據該些節點之該連接埠之該封包流的該封包流流量,以判斷該封包流是否為一重載封包流,其中當該些節點之該連接埠中的一者之該平均流量超過一壅塞門檻值,且流過該平均流量超過該壅塞門檻值之連接埠的該封包流為該重載封包流時,該控制器根據流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流以及該網路拓樸,進行一最短路徑演算法,以得到一新傳輸路徑,並將流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流重新規劃至該新傳輸路徑,其中在該最短路徑演算法中被計算的該些連接埠中不包括該平均流量超過該壅塞門檻值之連接埠。 A network system includes: a plurality of nodes, wherein each of the nodes includes at least one port, and adjacent ones of the nodes form a plurality of links through the ports, and the nodes are respectively used for outputting a recognition information and a support speed of the connection ports of the nodes; and a controller for receiving the identification information to construct a network topology and receiving the support speed of the connection ports of the nodes, And monitoring an average traffic of the ports, and monitoring a packet flow of a packet flow flowing through the ports of the nodes, and according to the packet flow of the packet flow of the connection of the nodes And determining whether the packet flow is a heavy-duty packet flow, wherein when the average flow rate of one of the connection ports of the nodes exceeds a congestion threshold, and the connection exceeds the connection threshold value exceeds the connection threshold When the packet flow of the buffer is the heavy-duty packet flow, the controller performs a shortest path according to the heavy-duty packet flow flowing through the connection port whose average flow exceeds the congestion threshold value and the network topology. a method for obtaining a new transmission path and re-planning the reloaded packet stream flowing through the port whose average traffic exceeds the congestion threshold to the new transmission path, wherein the shortest path algorithm is calculated These ports do not include the port whose average flow exceeds the threshold. 如請求項6所述的網路系統,其中該控制器更用以定期監控流過該些節點之該連接埠之該封包流的該封包流 流量,並判斷流過該些節點之該連接埠之該封包流的該封包流流量是否連續超過一封包流流量門檻,當流過該些節點之該連接埠之該封包流的該封包流流量連續超過該封包流流量門檻,該控制器判斷該封包流為該重載封包流。 The network system of claim 6, wherein the controller is further configured to periodically monitor the packet flow of the packet flow flowing through the ports of the nodes. Traffic, and determining whether the packet flow rate of the packet flow flowing through the connection of the nodes exceeds a packet flow threshold, and the packet flow of the packet flow flowing through the connection of the nodes The controller continuously determines that the packet flow is the heavy-duty packet flow. 如請求項6所述的網路系統,其中該控制器更用以根據流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流以及該網路拓樸找出該流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流之複數個準傳送路徑,並分別計算該些準傳送路徑之一路徑成本,且選出該些準傳送路徑中該路徑成本最小者作為該新傳輸路徑。 The network system of claim 6, wherein the controller is further configured to find that the flow is based on the overloaded packet flow that flows through the connection that exceeds the congestion threshold and the network topology. The average traffic exceeds a plurality of quasi-transmission paths of the reload packet flow of the connection threshold, and calculates a path cost of the quasi-transport paths, and selects the minimum cost of the path in the quasi-transmission path. The new transmission path. 如請求項6所述的網路系統,其中該控制器更用以找出該流過該平均流量超過該壅塞門檻值之連接埠的該重載封包流的一來源節點、一目的節點以及該來源節點與該目的節點之間的一原始路徑,並將至少一封包轉送規則分別寫入該新傳輸路徑所經過的節點之轉送表,以及在該原始路徑所經過的節點之轉送表中,將對應於該原始路徑的封包轉送規則刪除。 The network system of claim 6, wherein the controller is further configured to find a source node, a destination node, and the destination node of the overloaded packet flow that flows through the connection port whose average traffic exceeds the congestion threshold An original path between the source node and the destination node, and writing at least one packet forwarding rule to the forwarding table of the node through which the new transmission path passes, and in the forwarding table of the node through which the original path passes, The packet forwarding rule corresponding to the original path is deleted. 如請求項6所述的網路系統,其中當該些連接埠中的一者之該平均流量超過該壅塞門檻值時,該控制器更用以根據該平均流量超過該壅塞門檻值之連接埠之該平均流量與該平均流量超過該壅塞門檻值之連接埠的該支援速度 分別計算該些鏈結的一鏈路成本,並以該些鏈結的該鏈路成本為權重值,進行該最短路徑演算法,以規劃出該新傳輸路徑。 The network system of claim 6, wherein when the average traffic of one of the ports exceeds the congestion threshold, the controller is further configured to exceed the connection threshold based on the average traffic. The support speed of the average flow rate and the average flow rate exceeding the connection threshold value The link cost of the links is separately calculated, and the link cost of the links is used as a weight value, and the shortest path algorithm is performed to plan the new transmission path.
TW102120753A 2013-06-11 2013-06-11 Network system and load balancing method TWI523463B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW102120753A TWI523463B (en) 2013-06-11 2013-06-11 Network system and load balancing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW102120753A TWI523463B (en) 2013-06-11 2013-06-11 Network system and load balancing method

Publications (2)

Publication Number Publication Date
TW201448529A TW201448529A (en) 2014-12-16
TWI523463B true TWI523463B (en) 2016-02-21

Family

ID=52707659

Family Applications (1)

Application Number Title Priority Date Filing Date
TW102120753A TWI523463B (en) 2013-06-11 2013-06-11 Network system and load balancing method

Country Status (1)

Country Link
TW (1) TWI523463B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10103974B2 (en) 2016-07-12 2018-10-16 National Tsing Hua University Software-defined network controller and multipath routing method

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10103974B2 (en) 2016-07-12 2018-10-16 National Tsing Hua University Software-defined network controller and multipath routing method

Also Published As

Publication number Publication date
TW201448529A (en) 2014-12-16

Similar Documents

Publication Publication Date Title
US11695699B2 (en) Fault tolerant and load balanced routing
US9806994B2 (en) Routing via multiple paths with efficient traffic distribution
KR102104047B1 (en) Congestion control in packet data networking
KR101869902B1 (en) Sdn controller, data centre system, and router connection method
US9049131B2 (en) Network system and load balancing method
US9325609B2 (en) Segmented source routing in a network
US9654398B2 (en) Computer system, controller, switch, communication method and recording medium storing a network management program
CN103685054A (en) Multipath load balancing method based on service awareness
JP2014103656A (en) Network system and routing method
EP3364611B1 (en) Software-defined-networking table-entry generation and packet forwarding
IL230202A (en) Method and apparatus for resilient routing of control traffic in a split-architecture system
US20160065449A1 (en) Bandwidth-Weighted Equal Cost Multi-Path Routing
WO2021088801A9 (en) Routing method, network controller, system, and storage medium
US10686734B2 (en) Network switch with interconnected member nodes
WO2011118574A1 (en) Communications system, control device, delay measuring method, and program
TW201519603A (en) Device for multipath routing of packets in computer networking and method thereof
TWI523463B (en) Network system and load balancing method
WO2022052800A1 (en) Communication system, data processing method and related device
TWI556599B (en) Network controlling method and network controller
WO2016202095A1 (en) Path selection method and device, routing bridge, and network
TWI487330B (en) Network system and routing method
TW201424303A (en) Network system and load balancing method
TWI492587B (en) Network system and routing method
JP2012160980A (en) Router device, communication system, and route control method for use in those
CN104243336A (en) Network system and load balancing method