CN109905251B - Network management method, apparatus, electronic device and storage medium - Google Patents
Network management method, apparatus, electronic device and storage medium Download PDFInfo
- Publication number
- CN109905251B CN109905251B CN201711283418.8A CN201711283418A CN109905251B CN 109905251 B CN109905251 B CN 109905251B CN 201711283418 A CN201711283418 A CN 201711283418A CN 109905251 B CN109905251 B CN 109905251B
- Authority
- CN
- China
- Prior art keywords
- network
- topology information
- switch
- switches
- sdn controller
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000003860 storage Methods 0.000 title claims abstract description 15
- 238000007726 management method Methods 0.000 title claims description 31
- 238000000034 method Methods 0.000 claims abstract description 51
- 238000004422 calculation algorithm Methods 0.000 claims description 31
- 238000004364 calculation method Methods 0.000 claims description 18
- 238000004590 computer program Methods 0.000 claims description 10
- 230000004044 response Effects 0.000 claims description 4
- 230000001360 synchronised effect Effects 0.000 abstract description 8
- 239000010410 layer Substances 0.000 description 33
- 238000010586 diagram Methods 0.000 description 13
- 230000007547 defect Effects 0.000 description 12
- 230000008569 process Effects 0.000 description 12
- 238000012545 processing Methods 0.000 description 8
- 238000004891 communication Methods 0.000 description 6
- 230000008901 benefit Effects 0.000 description 3
- 230000008859 change Effects 0.000 description 3
- 239000000306 component Substances 0.000 description 3
- 230000002776 aggregation Effects 0.000 description 2
- 238000004220 aggregation Methods 0.000 description 2
- 230000005540 biological transmission Effects 0.000 description 2
- 239000012792 core layer Substances 0.000 description 2
- 238000009826 distribution Methods 0.000 description 2
- 230000006870 function Effects 0.000 description 2
- 238000012423 maintenance Methods 0.000 description 2
- 230000002093 peripheral effect Effects 0.000 description 2
- 229920000642 polymer Polymers 0.000 description 2
- 229920003245 polyoctenamer Polymers 0.000 description 2
- 235000008694 Humulus lupulus Nutrition 0.000 description 1
- 230000001174 ascending effect Effects 0.000 description 1
- 230000002457 bidirectional effect Effects 0.000 description 1
- 230000000903 blocking effect Effects 0.000 description 1
- 239000008358 core component Substances 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000000802 evaporation-induced self-assembly Methods 0.000 description 1
- 238000005111 flow chemistry technique Methods 0.000 description 1
- 230000006872 improvement Effects 0.000 description 1
- 230000003993 interaction Effects 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000006855 networking Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- RJCRUVXAWQRZKQ-UHFFFAOYSA-N oxosilicon;silicon Chemical compound [Si].[Si]=O RJCRUVXAWQRZKQ-UHFFFAOYSA-N 0.000 description 1
- 239000004065 semiconductor Substances 0.000 description 1
- 229910052710 silicon Inorganic materials 0.000 description 1
- 239000010703 silicon Substances 0.000 description 1
- 230000003068 static effect Effects 0.000 description 1
- 238000012546 transfer Methods 0.000 description 1
- 230000001960 triggered effect Effects 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L12/00—Data switching networks
- H04L12/28—Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
- H04L12/2803—Home automation networks
- H04L12/2823—Reporting information sensed by appliance or service execution status of appliance services in a home automation network
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L12/00—Data switching networks
- H04L12/28—Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
Landscapes
- Engineering & Computer Science (AREA)
- Automation & Control Theory (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
本发明实施例提供了一种基于SDN的实现全局网络管理方法、装置、电子设备和存储介质。其中,该方法应用于SDN控制器,SDN控制器属于SDN控制器集群,SDN控制器集群中各SDN控制器分别与分布式数据库相连,并且还分别与多个交换机相连并形成一网络域;任一交换机至少连接两个SDN控制器;该网络控制方法包括获取网络域内交换机间的第一拓扑信息;从分布式数据库获取SDN控制器集群中其他SDN控制器所在网络域内交换机间的第二拓扑信息;根据第一拓扑信息和第二拓扑信息,确定全局网络拓扑信息;基于全局网络拓扑信息,控制所在网络域内各交换机进行数据转发。由此,本发明实施例扩大了网络拓扑的规模,实现了全局拓扑信息的同步更新,对分布式数据库的性能要求小。
Embodiments of the present invention provide a method, apparatus, electronic device and storage medium for implementing global network management based on SDN. The method is applied to an SDN controller, the SDN controller belongs to an SDN controller cluster, and each SDN controller in the SDN controller cluster is respectively connected to a distributed database, and is also connected to a plurality of switches respectively to form a network domain; A switch is connected to at least two SDN controllers; the network control method includes acquiring first topology information between switches in a network domain; acquiring second topology information between switches in the network domain where other SDN controllers in the SDN controller cluster are located from a distributed database ; Determine global network topology information according to the first topology information and the second topology information; and control each switch in the network domain to perform data forwarding based on the global network topology information. Therefore, the embodiment of the present invention expands the scale of the network topology, realizes the synchronous update of the global topology information, and requires less performance of the distributed database.
Description
技术领域technical field
本发明涉及网络管理技术领域,特别是涉及一种网络管理方法、装置、电子设备和存储介质。The present invention relates to the technical field of network management, and in particular, to a network management method, apparatus, electronic device and storage medium.
背景技术Background technique
近年来,传统网络架构由于其管理过于复杂,且缺乏灵活性,已不足以满足人们的需求。In recent years, the traditional network architecture has been insufficient to meet people's needs due to its complex management and lack of flexibility.
为了满足人们对网络管理的灵活性和简单性的需求,SDN(Software DefinedNetwork,软件定义网络)的概念随之兴起。SDN概念的核心思想为软件可编程。基于SDN的概念,网络应用中常采用无分层网络控制方式的OpenFlow(一种网络协议)网络。In order to meet people's demand for flexibility and simplicity of network management, the concept of SDN (Software Defined Network, Software Defined Network) has emerged. The core idea of the SDN concept is software programmability. Based on the concept of SDN, OpenFlow (a network protocol) network without a hierarchical network control method is often used in network applications.
目前,在现有的OpenFlow网络中,通常只采用一个SDN控制器对网络内的所有交换机进行集中式网络管理。例如,假设OpenFlow网络中有1500台交换机和一台SDN控制器。该1500台交换机每秒钟会产生100000多条数据流,而一台SDN控制器只能处理30000条左右的数据流,导致在对该OpenFlow网络进行部署时无法承受设置足够数量的交换机,由此,全局网络拓扑规模受到了影响。因此,现有的OpenFlow网络由于采用一台SDN控制器来发现全局网络拓扑以对交换机进行管理而存在全局网络拓扑规模小的缺陷。Currently, in the existing OpenFlow network, only one SDN controller is usually used to perform centralized network management on all switches in the network. For example, suppose there are 1500 switches and an SDN controller in an OpenFlow network. The 1,500 switches will generate more than 100,000 data flows per second, and an SDN controller can only handle about 30,000 data flows, which makes it impossible to set up enough switches when deploying the OpenFlow network. , the global network topology scale is affected. Therefore, the existing OpenFlow network has the defect of small scale of the global network topology because an SDN controller is used to discover the global network topology to manage the switches.
发明内容SUMMARY OF THE INVENTION
本发明实施例的目的在于提供一种网络管理方法、装置、电子设备和存储介质,以解决如何扩大全局网络拓扑规模的技术问题。The purpose of the embodiments of the present invention is to provide a network management method, apparatus, electronic device and storage medium, so as to solve the technical problem of how to expand the scale of the global network topology.
为了实现上述目的,第一方面,提供了以下技术方案:In order to achieve the above purpose, in the first aspect, the following technical solutions are provided:
一种基于软件定义网络SDN的全局网络管理方法,所述方法应用于SDN控制器,所述SDN控制器属于SDN控制器集群,所述SDN控制器集群中各SDN控制器分别与分布式数据库相连,且所述各SDN控制器分别与多个互连的交换机相连并形成一网络域;A global network management method based on a software-defined network SDN, the method is applied to an SDN controller, the SDN controller belongs to an SDN controller cluster, and each SDN controller in the SDN controller cluster is respectively connected to a distributed database , and the SDN controllers are respectively connected with a plurality of interconnected switches to form a network domain;
所述方法包括:The method includes:
获取自身所在网络域内交换机间的第一拓扑信息;Obtain the first topology information between switches in the network domain where it is located;
从所述分布式数据库获取所述SDN控制器集群中其他SDN控制器所在网络域内交换机间的第二拓扑信息;Acquire, from the distributed database, second topology information between switches in the network domain where other SDN controllers in the SDN controller cluster are located;
根据所述第一拓扑信息和所述第二拓扑信息,确定全局网络拓扑。A global network topology is determined according to the first topology information and the second topology information.
可选的,所述获取自身所在网络域内交换机间的第一拓扑信息的步骤,包括:Optionally, the step of acquiring the first topology information between switches in the network domain where the self is located includes:
向自身所在网络域内的交换机分别发送拓扑信息请求;Send topology information requests to switches in its own network domain;
分别接收各交换机针对所述拓扑信息请求发送的端口信息及与之相连的交换机的端口信息;Respectively receive the port information sent by each switch for the topology information request and the port information of the switch connected to it;
根据接收到的端口信息,得到所述自身所在网络域内交换机间的所述第一拓扑信息。According to the received port information, the first topology information between switches in the network domain where the self is located is obtained.
可选的,在所述获取自身所在网络域内交换机间的第一拓扑信息的步骤之后,所述方法包括:Optionally, after the step of acquiring the first topology information between switches in the network domain where the self is located, the method includes:
将所述第一拓扑信息发送至所述分布式数据库。Sending the first topology information to the distributed database.
可选的,所述从所述分布式数据库获取所述SDN控制器集群中其他SDN控制器所在网络域内交换机间的第二拓扑信息的步骤,包括:Optionally, the step of acquiring the second topology information between switches in the network domain where other SDN controllers in the SDN controller cluster are located from the distributed database includes:
接收所述分布式数据库发送的拓扑信息更新通知;其中,所述拓扑信息更新通知为所述分布式数据库在接收到由所述其他SDN控制器发送的所述第二拓扑信息时发送的;receiving a topology information update notification sent by the distributed database; wherein, the topology information update notification is sent by the distributed database when receiving the second topology information sent by the other SDN controllers;
根据所述拓扑信息更新通知从所述分布式数据库获取所述SDN控制器集群中所述其他SDN控制器所在网络域内交换机间的第二拓扑信息。Acquire second topology information between switches in the network domain where the other SDN controllers in the SDN controller cluster are located from the distributed database according to the topology information update notification.
可选的,所述方法还包括:Optionally, the method further includes:
根据所述全局网络拓扑,控制所述自身所在网络域内各交换机进行数据转发。According to the global network topology, each switch in the network domain where the self is located is controlled to perform data forwarding.
可选的,所述根据所述全局网络拓扑,控制所述自身所在网络域内各交换机进行数据转发的步骤,包括:Optionally, the step of controlling each switch in the network domain where the self is located to perform data forwarding according to the global network topology includes:
根据所述全局网络拓扑生成流表,并向所述自身所在网络域内各交换机分别发送所述流表,控制所述自身所在网络域内各交换机进行数据转发。A flow table is generated according to the global network topology, and the flow table is sent to each switch in the network domain where the self is located to control each switch in the network domain where the self is located to perform data forwarding.
可选的,所述自身所在网络域内各交换机包括多个提供商边缘交换机;Optionally, each switch in the network domain where the self is located includes multiple provider edge switches;
所述根据所述全局网络拓扑生成流表的步骤,包括:The step of generating a flow table according to the global network topology includes:
根据所述全局网络拓扑,按照预定算法计算所述多个提供商边缘交换机之间的路径;According to the global network topology, calculate the paths between the plurality of provider edge switches according to a predetermined algorithm;
生成包含所述路径的流表。A flow table containing the paths is generated.
可选的,所述根据所述全局网络拓扑,按照预定算法计算所述多个提供商边缘交换机之间的路径的步骤,包括:Optionally, the step of calculating paths between the multiple provider edge switches according to a predetermined algorithm according to the global network topology includes:
接收所述自身所在网络域内交换机发送的数据包;receiving a data packet sent by the switch in the network domain where the self is located;
解析所述数据包,得到目的MAC地址;Parse the data packet to obtain the destination MAC address;
根据所述全局网络拓扑和所述目的MAC地址,按照预定算法计算所述多个提供商边缘交换机之间的路径。According to the global network topology and the destination MAC address, paths between the plurality of provider edge switches are calculated according to a predetermined algorithm.
可选的,所述方法还包括:Optionally, the method further includes:
接收自身所在网络域之外的其他网络域内交换机发送的网络连接请求;其中,所述网络连接请求是由所述其他网络域内的交换机在所述其他网络域的SDN控制器出现故障时发送的;receiving a network connection request sent by a switch in another network domain other than the network domain where it is located; wherein the network connection request is sent by a switch in the other network domain when the SDN controller of the other network domain fails;
根据所述网络连接请求,与所述其他网络域内的交换机建立网络连接。According to the network connection request, a network connection is established with the switches in the other network domains.
为了实现上述目的,第二方面,还提供了以下技术方案:In order to achieve the above purpose, in the second aspect, the following technical solutions are also provided:
一种基于软件定义网络SDN的全局网络管理装置,所述装置应用于SDN控制器,所述SDN控制器属于SDN控制器集群,所述SDN控制器集群中各SDN控制器分别与分布式数据库相连,且所述各SDN控制器分别与多个互连的交换机相连并形成一网络域;A global network management device based on software-defined network SDN, the device is applied to an SDN controller, the SDN controller belongs to an SDN controller cluster, and each SDN controller in the SDN controller cluster is respectively connected to a distributed database , and the SDN controllers are respectively connected with a plurality of interconnected switches to form a network domain;
所述装置包括:The device includes:
第一获取模块,用于获取自身所在网络域内交换机间的第一拓扑信息;a first obtaining module, configured to obtain the first topology information between switches in the network domain where it is located;
第二获取模块,用于从所述分布式数据库获取所述SDN控制器集群中其他SDN控制器所在网络域内交换机间的第二拓扑信息;A second obtaining module, configured to obtain, from the distributed database, second topology information between switches in the network domain where other SDN controllers in the SDN controller cluster are located;
确定模块,用于根据所述第一拓扑信息和所述第二拓扑信息,确定全局网络拓扑。A determining module, configured to determine a global network topology according to the first topology information and the second topology information.
可选的,所述第一获取模块包括:Optionally, the first acquisition module includes:
第一发送单元,用于向自身所在网络域内的交换机分别发送拓扑信息请求;a first sending unit, configured to send topology information requests to switches in the network domain where it is located;
第一接收单元,用于分别接收各交换机针对所述拓扑信息请求发送的端口信息及与之相连的交换机的端口信息;a first receiving unit, configured to respectively receive the port information sent by each switch in response to the topology information request and the port information of the switch connected to it;
第一获取单元,用于根据接收到的端口信息,得到所述自身所在网络域内交换机间的所述第一拓扑信息。A first obtaining unit, configured to obtain the first topology information between switches in the network domain where the self is located according to the received port information.
可选的,所述装置还包括:Optionally, the device further includes:
发送模块,用于将所述第一拓扑信息发送至所述分布式数据库。A sending module, configured to send the first topology information to the distributed database.
可选的,所述第二获取模块包括:Optionally, the second acquisition module includes:
第二接收单元,用于接收所述分布式数据库发送的拓扑信息更新通知;其中,所述拓扑信息更新通知为所述分布式数据库在接收到由所述其他SDN控制器发送的所述第二拓扑信息时发送的;A second receiving unit, configured to receive a topology information update notification sent by the distributed database; wherein, the topology information update notification is when the distributed database receives the second notification sent by the other SDN controller. Sent when topology information;
第二获取单元,用于根据所述拓扑信息更新通知从所述分布式数据库获取所述SDN控制器集群中所述其他SDN控制器所在网络域内交换机间的第二拓扑信息。A second obtaining unit, configured to obtain the second topology information between switches in the network domain where the other SDN controllers in the SDN controller cluster are located from the distributed database according to the topology information update notification.
可选的,所述装置还包括:Optionally, the device further includes:
控制模块,用于根据所述全局网络拓扑,控制所述自身所在网络域内各交换机进行数据转发。A control module, configured to control each switch in the network domain where the self is located to perform data forwarding according to the global network topology.
可选的,所述控制模块具体用于根据所述全局网络拓扑生成流表,并向所述自身所在网络域内各交换机分别发送所述流表,控制所述自身所在网络域内各交换机进行数据转发。Optionally, the control module is specifically configured to generate a flow table according to the global network topology, send the flow table to each switch in the network domain where the self is located, and control the switches in the network domain where the self is located to perform data forwarding. .
可选的,所述自身所在网络域内各交换机包括多个提供商边缘交换机;Optionally, each switch in the network domain where the self is located includes multiple provider edge switches;
所述控制模块包括:The control module includes:
计算单元,用于根据所述全局网络拓扑,按照预定算法计算所述多个提供商边缘交换机之间的路径;a calculation unit, configured to calculate paths between the plurality of provider edge switches according to a predetermined algorithm according to the global network topology;
生成单元,用于生成包含所述路径的流表。A generating unit for generating a flow table including the path.
可选的,所述计算单元包括:Optionally, the computing unit includes:
接收子单元,用于接收所述自身所在网络域内交换机发送的数据包;a receiving subunit, configured to receive the data packet sent by the switch in the network domain where the self is located;
解析子单元,用于解析所述数据包,得到目的MAC地址;A parsing subunit for parsing the data packet to obtain a destination MAC address;
计算子单元,用于根据所述全局网络拓扑和所述目的MAC地址,按照预定算法计算所述多个提供商边缘交换机之间的路径。A calculation subunit, configured to calculate paths between the plurality of provider edge switches according to a predetermined algorithm according to the global network topology and the destination MAC address.
可选的,所述装置还包括:Optionally, the device further includes:
接收模块,用于接收自身所在网络域之外的其他网络域内交换机发送的网络连接请求;其中,所述网络连接请求是由所述其他网络域内的交换机在所述其他网络域的SDN控制器出现故障时发送的;A receiving module, configured to receive a network connection request sent by a switch in another network domain other than the network domain where it is located; wherein, the network connection request is generated by the switch in the other network domain at the SDN controller of the other network domain Sent when there is a failure;
建立模块,用于根据所述网络连接请求,与所述其他网络域内的交换机建立网络连接。The establishing module is configured to establish a network connection with the switches in the other network domains according to the network connection request.
为了实现上述目的,第三方面,还提供了以下技术方案:In order to achieve the above purpose, in the third aspect, the following technical solutions are also provided:
一种电子设备,其包括处理器和存储器;An electronic device including a processor and a memory;
所述存储器,用于存放计算机程序;the memory for storing computer programs;
所述处理器,用于执行存储器上所存放的程序时,实现第一方面所述的方法步骤。The processor is configured to implement the method steps described in the first aspect when executing the program stored in the memory.
为了实现上述目的,第四方面,还提供了以下技术方案:In order to achieve the above purpose, in the fourth aspect, the following technical solutions are also provided:
一种计算机可读存储介质,所述计算机可读存储介质内存储有计算机程序,所述计算机程序被处理器执行时实现第一方面所述的方法步骤。A computer-readable storage medium stores a computer program in the computer-readable storage medium, and when the computer program is executed by a processor, implements the method steps of the first aspect.
本发明实施例提供一种基于SDN的实现全局网络管理方法、装置、电子设备和存储介质。其中,该网络控制方法应用于SDN控制器,SDN控制器属于SDN控制器集群,SDN控制器集群中各SDN控制器分别与分布式数据库相连,并且还分别与多个交换机相连并形成一网络域;该网络控制方法包括:获取自身所在网络域内交换机间的第一拓扑信息;从分布式数据库获取SDN控制器集群中其他SDN控制器所在网络域内交换机间的第二拓扑信息;根据第一拓扑信息和第二拓扑信息,确定全局网络拓扑。Embodiments of the present invention provide a method, apparatus, electronic device and storage medium for implementing global network management based on SDN. The network control method is applied to an SDN controller, the SDN controller belongs to an SDN controller cluster, and each SDN controller in the SDN controller cluster is respectively connected to a distributed database, and is also connected to a plurality of switches respectively to form a network domain ; The network control method comprises: acquiring first topology information between switches in a network domain where one is located; acquiring from a distributed database second topology information between switches in a network domain where other SDN controllers in the SDN controller cluster are located; according to the first topology information and the second topology information to determine the global network topology.
本发明实施例通过采取上述技术方案,通过SDN控制器集群来控制交换机,并使得每一个SDN控制器在一个网络域内与多个互连的交换机相连,SDN控制器集群中的每一个SDN控制器不仅获取自身所在网络域内的第一拓扑信息,而且还通过分布式数据库获取其他SDN控制器所在网络域的第二拓扑信息,从而使得每一个SDN控制器可以获得整个网络的全局网络拓扑,由此扩大了网络拓扑的规模,并且可以实现网络拓扑规模的无限扩展。而且通过分布式数据库获取其他SDN控制器所在网络域内的第二拓扑信息的步骤,还实现了全局拓扑信息的同步更新。另外,在本发明实施例中,SDN控制器从分布式数据库获取的是拓扑信息,而没有涉及到诸如与路径计算、流表下发等相关信息;因此,本发明实施例对分布式数据库的性能要求小,提高了网络性能,从而克服了现有技术存在的SDN控制性能瓶颈的缺陷。In the embodiment of the present invention, by adopting the above technical solution, the switches are controlled through the SDN controller cluster, and each SDN controller is connected to a plurality of interconnected switches in a network domain. Each SDN controller in the SDN controller cluster Not only the first topology information in the network domain where it is located, but also the second topology information in the network domain where other SDN controllers are located through the distributed database, so that each SDN controller can obtain the global network topology of the entire network. The scale of the network topology is enlarged, and the infinite expansion of the scale of the network topology can be realized. Moreover, the step of obtaining the second topology information in the network domain where other SDN controllers are located through the distributed database also realizes the synchronous update of the global topology information. In addition, in the embodiment of the present invention, the SDN controller obtains topology information from the distributed database, and does not involve related information such as path calculation, flow table delivery, etc.; The performance requirements are small, and the network performance is improved, thereby overcoming the defect of the SDN control performance bottleneck existing in the prior art.
本发明的其它特征和优点将在随后的说明书中阐述,并且,部分地从说明书中变得显而易见,或者通过实施本发明而得以体现。本发明的目的和其他优点可通过在说明书、权利要求书以及附图中所特别指出的结构来实现和获得。Other features and advantages of the invention will be set forth in the description which follows, and in part will be apparent from the description, or will be manifested by practice of the invention. The objectives and other advantages of the invention may be realized and attained by the structure particularly pointed out in the description, claims and drawings.
当然,实施本发明的任一产品或方法并不一定需要同时达到以上所述的所有优点。Of course, it is not necessary for any product or method of the present invention to achieve all of the advantages described above at the same time.
附图说明Description of drawings
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to explain the embodiments of the present invention or the technical solutions in the prior art more clearly, the following briefly introduces the accompanying drawings that need to be used in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are only These are some embodiments of the present invention. For those of ordinary skill in the art, other drawings can also be obtained according to these drawings without creative efforts.
图1为根据本发明实施例的SDN控制器的逻辑分层架构示意图;1 is a schematic diagram of a logical layered architecture of an SDN controller according to an embodiment of the present invention;
图2为根据本发明实施例的基于SDN的全局网络管理方法的流程示意图;2 is a schematic flowchart of an SDN-based global network management method according to an embodiment of the present invention;
图3为根据本发明实施例的一种网络拓扑结构示意图;3 is a schematic diagram of a network topology structure according to an embodiment of the present invention;
图4为根据本发明实施例的获取自身所在网络域内交换机间的第一拓扑信息的流程示意图;FIG. 4 is a schematic flowchart of obtaining first topology information between switches in the network domain where oneself is located according to an embodiment of the present invention;
图5为根据本发明实施例的从分布式数据库获取SDN控制器集群中其他SDN控制器所在网络域内交换机间的第二拓扑信息的流程示意图;5 is a schematic flowchart of obtaining from a distributed database the second topology information between switches in the network domain where other SDN controllers in the SDN controller cluster are located according to an embodiment of the present invention;
图6为根据本发明实施例的在图2所示实施例的基础上增加根据全局网络拓扑,控制自身所在网络域内各交换机进行数据转发步骤的流程示意图;6 is a schematic flowchart of a step of controlling each switch in the network domain where it is located to perform data forwarding according to the global network topology based on the embodiment shown in FIG. 2 according to an embodiment of the present invention;
图7为根据本发明实施例的根据全局网络拓扑生成流表的流程示意图;7 is a schematic flowchart of generating a flow table according to a global network topology according to an embodiment of the present invention;
图8为根据本发明实施例的根据全局网络拓扑,按照预定算法计算多个提供商边缘交换机之间的路径的流程示意图;8 is a schematic flowchart of calculating paths between multiple provider edge switches according to a predetermined algorithm according to a global network topology according to an embodiment of the present invention;
图9为根据本发明实施例的根据交换机角色维护全局网络拓扑的过程的示意图;9 is a schematic diagram of a process of maintaining a global network topology according to a switch role according to an embodiment of the present invention;
图10为根据本发明另一实施例的根据交换机角色维护全局网络拓扑的过程的示意图;10 is a schematic diagram of a process of maintaining a global network topology according to a switch role according to another embodiment of the present invention;
图11为根据本发明实施例的基于SDN的全局网络管理装置的结构示意图;11 is a schematic structural diagram of an SDN-based global network management apparatus according to an embodiment of the present invention;
图12为根据本发明实施例的第一获取模块的结构示意图;12 is a schematic structural diagram of a first acquisition module according to an embodiment of the present invention;
图13为根据本发明另一实施例的基于SDN的全局网络管理装置的结构示意图;13 is a schematic structural diagram of an SDN-based global network management apparatus according to another embodiment of the present invention;
图14为根据本发明实施例的第二获取模块的结构示意图;14 is a schematic structural diagram of a second acquisition module according to an embodiment of the present invention;
图15为根据本发明实施例的控制模块的结构示意图;15 is a schematic structural diagram of a control module according to an embodiment of the present invention;
图16为根据本发明实施例的计算单元的结构示意图;16 is a schematic structural diagram of a computing unit according to an embodiment of the present invention;
图17为根据本发明实施例的电子设备的结构示意图。FIG. 17 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
具体实施方式Detailed ways
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, but not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.
下面对本文涉及到的术语进行详细说明:The following is a detailed description of the terms involved in this article:
链路是指网络中任意相连节点之间的连通路径;例如,两个交换机之间的连通路径。A link is a connection path between any connected nodes in a network; for example, a connection path between two switches.
路径是指网络中从源节点到目的节点之间的通路;一条路径可以包含一条或多条链路;本文中可以指提供商边缘交换机之间的通路。A path refers to a path from a source node to a destination node in a network; a path can contain one or more links; in this context, it can refer to a path between provider edge switches.
SDN:是一种网络架构,其主要通过OpenFlow协议将网络设备的控制面与数据面分离开来,从而实现网络流量的控制。SDN: It is a network architecture, which mainly separates the control plane and data plane of network devices through the OpenFlow protocol, so as to realize the control of network traffic.
OpenFlow网络:其包括交换机和Controller(控制器);其中,交换机优选为OpenFlowSwitch(开放流交换机)。OpenFlowSwitch是整个OpenFlow网络的核心部件,包括流表、安全通道和OpenFlow协议,并且主要管理数据层的转发。其中,安全通道为连接交换机与控制器的接口;OpenFlow协议用于描述控制器与交换机之间交互所用信息的标准,以及控制器和交换机的接口标准。OpenFlowSwitch拥有一个或多个FlowTable(流表),并只按照流表进行数据包的转发。FlowTable的生成、维护和下发由Controller来实现。这里,FlowTable并非是指IP五元组(IP源地址、IP目的地址、协议号、源端口、目的端口),而是涵括了二到七层网络的几乎所有网络字段。FlowTable中的每个关键字都可以通配。网络的运营商可以决定使用何种粒度的流。比如,如果运营商只需要根据目的IP进行数据包路由,那么,FlowTable中就可以只有IP目的地址字段是有效的,其它全为通配。传统网络中数据包的流向是人为指定的,虽然交换机、路由器拥有控制权,却没有数据流的概念,只进行数据包级别的交换;而在OpenFlow网络中,Controller取代路由,管理所有数据包在网络中的传输路径,实现控制层的功能。OpenFlow network: it includes a switch and a Controller (controller); wherein, the switch is preferably an OpenFlowSwitch (Open Flow Switch). OpenFlowSwitch is the core component of the entire OpenFlow network, including flow table, secure channel and OpenFlow protocol, and mainly manages the forwarding of the data layer. Among them, the secure channel is the interface connecting the switch and the controller; the OpenFlow protocol is used to describe the standard of the information used in the interaction between the controller and the switch, and the interface standard of the controller and the switch. OpenFlowSwitch has one or more FlowTable (flow table), and only forwards data packets according to the flow table. The generation, maintenance and distribution of FlowTable are implemented by Controller. Here, FlowTable does not refer to IP quintuple (IP source address, IP destination address, protocol number, source port, destination port), but covers almost all network fields of Layer 2 to Layer 7 networks. Every keyword in the FlowTable can be wildcarded. The operator of the network can decide what granularity of flow to use. For example, if the operator only needs to route data packets based on the destination IP, then only the IP destination address field in the FlowTable can be valid, and the others are all wildcards. The flow direction of data packets in traditional networks is artificially specified. Although switches and routers have control, they do not have the concept of data flow, and only perform packet-level exchanges. In OpenFlow networks, the Controller replaces routing and manages all data packets. The transmission path in the network to realize the function of the control layer.
图1示例性地示出了SDN控制器(也称OpenFlow控制器)的逻辑分层架构示意图。图1所示结构总体分为三层,即应用层、控制平面层和数据平面层。其中,控制平面层和数据平面层都基于同一个物理网络。数据平面层作为底层,主要包括交换机等设备;该交换机优选为支持OpenFlow协议的物理机或者软件实现的虚拟交换机(例如,OpenFlowSwitch,开放流交换机),用于负责从控制器接收流表规则,转发网络流量。控制平面层包括开放流控制器;该开放流控制器用于发现下层交换机的全局拓扑,然后,根据具体业务和上层应用逻辑下发对应的流表规则,控制交换机进行数据流量转发。应用层为基于开放流控制器的一些具体业务应用,例如,其可以包括虚拟网络、流量工程和多个泛光灯应用程序,用于抽象出一个逻辑的虚拟网络,功能用户配置和使用,从而使得用户不必关心下层具体物理网络的结构,易于进行组网和连通业务。FIG. 1 exemplarily shows a schematic diagram of a logical layered architecture of an SDN controller (also called an OpenFlow controller). The structure shown in Figure 1 is generally divided into three layers, namely the application layer, the control plane layer and the data plane layer. Among them, the control plane layer and the data plane layer are based on the same physical network. The data plane layer, as the bottom layer, mainly includes devices such as switches; the switch is preferably a physical machine that supports the OpenFlow protocol or a software-implemented virtual switch (for example, OpenFlowSwitch, OpenFlow switch), which is responsible for receiving flow table rules from the controller and forwarding them. Network traffic. The control plane layer includes an OpenFlow controller; the OpenFlow controller is used to discover the global topology of the lower-layer switches, and then issue corresponding flow table rules according to specific services and upper-layer application logic to control the switches to forward data traffic. The application layer is based on some specific business applications based on the OpenFlow controller. For example, it can include virtual networks, traffic engineering and multiple floodlight applications, which are used to abstract a logical virtual network, functional user configuration and use, thereby The user does not need to care about the structure of the specific physical network at the lower layer, and it is easy to perform networking and connection services.
现有的OpenFlow网络由于通常采用一台SDN控制器来发现全局网络拓扑以对交换机进行管理而存在全局网络拓扑规模小的缺陷。例如,在现有的采用一主多备的方案中,多个控制器读写同一个数据库,用于保存基于OpenFlow协议的相关网络拓扑信息。该方案中,同一时间只有一个主控制器进行写入数据库的操作;备控制器只能从数据库中读取网络拓扑信息。由此,网络额规模化支持受限于SDN控制器的性能。因此,该方案由于同一时间只有一台控制器而存在不支持大规模网络拓扑的缺陷。The existing OpenFlow network has the defect of small scale of the global network topology because an SDN controller is usually used to discover the global network topology to manage the switches. For example, in the existing solution using one master and multiple backups, multiple controllers read and write the same database for saving relevant network topology information based on the OpenFlow protocol. In this solution, only one master controller writes to the database at the same time; the backup controller can only read network topology information from the database. Thus, network scale support is limited by the capabilities of the SDN controller. Therefore, this scheme has the defect of not supporting large-scale network topology due to only one controller at the same time.
鉴于此,为了解决如何扩大全局网络拓扑规模的技术问题,本发明实施例提供一种基于软件定义网络SDN的全局网络管理方法,其应用于SDN控制器,SDN控制器属于SDN控制器集群,SDN控制器集群中各SDN控制器分别与分布式数据库相连,且各SDN控制器分别与多个互连的交换机相连并形成一网络域;如图2所示,基于SDN的全局网络管理方法包括如下步骤S200至步骤S220。其中:In view of this, in order to solve the technical problem of how to expand the scale of the global network topology, an embodiment of the present invention provides a global network management method based on a software-defined network SDN, which is applied to an SDN controller. The SDN controller belongs to the SDN controller cluster, and the SDN Each SDN controller in the controller cluster is connected to a distributed database, and each SDN controller is connected to a plurality of interconnected switches to form a network domain; as shown in Figure 2, the SDN-based global network management method includes the following Steps S200 to S220. in:
S200:获取自身所在网络域内交换机间的第一拓扑信息。S200: Acquire first topology information between switches in the network domain where the self is located.
本步骤可以通过SDN控制器获取自身所在网络域内多个交换机之间的第一拓扑信息。其中,SDN控制器集群中的每一个SDN控制器可以只管控整个网络中的部分交换机。SDN控制器例如可以为FloodLight控制器(泛光控制器)、OpenDayLight控制器(一种开源控制器)等任意商用或开源的控制器。其中,FloodLight控制器的结构精简且采用模块化设计模式,易于增加和开发上层虚拟网络应用。该SDN控制器运行在服务器(例如,X86架构服务器)上,并在该服务器上进行诸如拓扑发现、流表下发、数据包上报处理等数据流的处理。每个SDN控制器通过交换机的IP地址和端口号可以管理一定数量的交换机。In this step, the SDN controller may obtain the first topology information among the multiple switches in the network domain where it is located. Wherein, each SDN controller in the SDN controller cluster can only manage and control some switches in the entire network. For example, the SDN controller can be any commercial or open source controller such as a FloodLight controller (flood light controller), an OpenDayLight controller (an open source controller). Among them, the FloodLight controller has a simplified structure and adopts a modular design mode, which is easy to add and develop upper-layer virtual network applications. The SDN controller runs on a server (for example, an X86 architecture server), and performs data flow processing such as topology discovery, flow table delivery, and data packet reporting processing on the server. Each SDN controller can manage a certain number of switches through the IP addresses and port numbers of the switches.
交换机优选为支持OpenFlow协议的OpenFlow交换机。交换机的端口既可以用于收发控制包,也可以用于收发数据包。交换机可以在本地维护一个流表。The switch is preferably an OpenFlow switch supporting the OpenFlow protocol. The port of the switch can be used to send and receive control packets, and can also be used to send and receive data packets. The switch can maintain a flow table locally.
第一拓扑信息可以包括但不限于各交换机的IP地址和端口号。The first topology information may include, but is not limited to, the IP addresses and port numbers of each switch.
表1示例性地示出了第一拓扑信息。表1中的信息表示第一交换机通过1号端口与第二交换机相连;第二交换机通过5号端口与第三交换机相连。Table 1 exemplarily shows the first topology information. The information in Table 1 indicates that the first switch is connected to the second switch through port 1; the second switch is connected to the third switch through port 5.
表1Table 1
图3示例性地示出了一种网络拓扑结构示意图。图3所示网络拓扑为数据中心三层网络拓扑结构。其中包括分布式数据库30、网络域31和网络域32。其中,网络域31包括SDN控制器311与交换机3111、交换机3121、交换机3122、交换机3131和交换机3132。网络域32包括SDN控制器321与交换机3211、交换机3221、交换机3222和交换机3231。交换机3111、交换机3211、交换机3121、交换机3122、交换机3221和交换机3222构成full mesh(全网状)连接的网络,以从接入层网络设备双上行至中间汇聚层网络提供无阻塞数据转发。其中,接入层用于向本地网段提供工作站接入服务。汇聚层是指位于网络接入层和核心层之间的中介层。核心层是指网络主干网络层。SDN控制器311和SDN控制器321可以构成SDN控制器集群。分布式数据库30可以由开源的数据库予以实现,并且该分布式数据库30可以提供分布式锁功能,以保证SDN控制器集群中的所有SDN控制器节点数据的有序和有效的读写。如图3所示,SDN控制器311获取网络域31内交换机3111、交换机3131、交换机3132、交换机3131和交换机3132间的拓扑信息;SDN控制器321获取网络域32内SDN控制器321与交换机3211、交换机3221、交换机3222和交换机3231之间的拓扑信息。FIG. 3 exemplarily shows a schematic diagram of a network topology. The network topology shown in Figure 3 is a three-layer network topology of the data center. It includes a distributed
具体地,在一些可选的实施例中,如图4所示,本步骤可以包括如下步骤S201至步骤S203。其中:Specifically, in some optional embodiments, as shown in FIG. 4 , this step may include the following steps S201 to S203. in:
S201:向自身所在网络域内的交换机分别发送拓扑信息请求。S201: Send topology information requests to switches in the network domain where the network domain is located.
在实际应用中,交换机中配置有该SDN控制器的IP(网际间协议)地址。交换机主动与SDN控制器建立连接。连接建立之后,SDN控制器向自身所在网络域内的交换机发送拓扑信息请求。In practical applications, the switch is configured with the IP (Internet Protocol) address of the SDN controller. The switch actively establishes a connection with the SDN controller. After the connection is established, the SDN controller sends a topology information request to the switch in its own network domain.
沿用图3所示示例,SDN控制器311可以向网络域31内的各个交换机发送拓扑信息请求。Following the example shown in FIG. 3 , the
S202:分别接收各交换机针对拓扑信息请求发送的端口信息及与之相连的交换机的端口信息。S202: Receive the port information sent by each switch in response to the topology information request and the port information of the switch connected thereto respectively.
其中,端口信息可以是交换机的端口号,例如,2号、5号等。The port information may be the port number of the switch, for example, No. 2, No. 5, and so on.
在实际应用中,交换机接收到拓扑信息请求之后,向SDN控制器发送自身的端口信息以及与之相连的交换机的端口信息。In practical applications, after the switch receives the topology information request, it sends its own port information and the port information of the connected switch to the SDN controller.
沿用图3所示示例,以网络域31内的交换机3131为例,SDN控制器311接收交换机3131发送的其自身的端口号以及交换机3121、交换机3122所用的端口号。Following the example shown in FIG. 3 , taking the
S203:根据接收到的端口信息,得到自身所在网络域内交换机间的第一拓扑信息。S203: According to the received port information, obtain first topology information between switches in the network domain where the self is located.
本步骤在接收到端口信息后,可以根据各个交换机的端口之间的连接关系,绘制出拓扑图,形成第一拓扑信息。In this step, after receiving the port information, a topology map may be drawn according to the connection relationship between the ports of each switch to form the first topology information.
以表一为例,表一中的信息表示第一交换机通过1号端口与第二交换机相连;第二交换机通过5号端口与第三交换机相连。通过该拓扑信息,可以得到第一交换机与第二交换机之间的拓扑信息。Taking Table 1 as an example, the information in Table 1 indicates that the first switch is connected to the second switch through port 1; the second switch is connected to the third switch through port 5. Through the topology information, topology information between the first switch and the second switch can be obtained.
在一些可选的实施例中,在步骤S200之后,基于SDN的全局网络管理方法还可以包括:In some optional embodiments, after step S200, the SDN-based global network management method may further include:
将第一拓扑信息发送至分布式数据库。The first topology information is sent to the distributed database.
本步骤中,各个SDN控制器可以将各自所获取到的拓扑信息发送至分布式数据库,实现了对该分布式数据库中所存储的拓扑信息的更新。In this step, each SDN controller can send the obtained topology information to the distributed database, so as to realize the updating of the topology information stored in the distributed database.
S210:从分布式数据库获取SDN控制器集群中其他SDN控制器所在网络域内交换机间的第二拓扑信息。S210: Acquire, from the distributed database, second topology information between switches in the network domain where other SDN controllers in the SDN controller cluster are located.
其中,有关第二拓扑信息的说明可以参见本文对第一拓扑信息的说明,在此不再赘述。For the description of the second topology information, reference may be made to the description of the first topology information in this document, and details are not repeated here.
本发明实施例既获取自身所在网络域内交换机间的第一拓扑信息,也通过本步骤获取SDN控制器集群中其他SDN控制器所在网络域内交换机间的第二拓扑信息,以用于获得全局网络拓扑。The embodiment of the present invention not only obtains the first topology information between switches in the network domain where the self is located, but also obtains the second topology information between switches in the network domain where other SDN controllers in the SDN controller cluster are located through this step, so as to obtain the global network topology .
在一些可选的实施例中,如图5所示,步骤S210具体可以包括步骤S211和步骤S212。其中:In some optional embodiments, as shown in FIG. 5 , step S210 may specifically include step S211 and step S212. in:
S211:接收分布式数据库发送的拓扑信息更新通知;其中,拓扑信息更新通知为分布式数据库在接收到由其他SDN控制器发送的第二拓扑信息时发送的。S211: Receive a topology information update notification sent by the distributed database; wherein, the topology information update notification is sent by the distributed database when it receives the second topology information sent by other SDN controllers.
在具体实施过程中,各个SDN控制器实时监测分布式数据库的拓扑信息更新。当分布式数据库中的拓扑信息发生更新时,分布式数据库通知各个SDN控制器,然后,各个SDN控制器接收该分布式数据库发送的拓扑信息更新通知。In the specific implementation process, each SDN controller monitors the topology information update of the distributed database in real time. When the topology information in the distributed database is updated, the distributed database notifies each SDN controller, and then each SDN controller receives the topology information update notification sent by the distributed database.
沿用图3所示示例,如果SDN控制器311将拓扑信息发送至分布式数据库30;则该分布式数据库30向SDN控制器321发送拓扑信息更新通知。Following the example shown in FIG. 3 , if the
S212:根据拓扑信息更新通知从分布式数据库获取SDN控制器集群中其他SDN控制器所在网络域内交换机间的第二拓扑信息。S212: Acquire second topology information between switches in the network domain where other SDN controllers in the SDN controller cluster are located from the distributed database according to the topology information update notification.
作为示例,各个SDN控制器接收到更新通知后,从该分布式数据库中获取其他SDN控制器发送至分布式数据库的拓扑信息,由此实现了全局拓扑信息的同步。As an example, after each SDN controller receives the update notification, it obtains, from the distributed database, topology information sent by other SDN controllers to the distributed database, thereby realizing synchronization of global topology information.
S220:根据第一拓扑信息和第二拓扑信息,确定全局网络拓扑。S220: Determine the global network topology according to the first topology information and the second topology information.
本步骤根据所获取到的自身网络域内的交换机间的拓扑信息,以及从分布式数据库同步得到的其他SDN控制器所在网络域内交换机间的拓扑信息,可以获得整个网络中各个网络域内各个交换机端口之间的连接关系,据此可以拼出一张拓扑图,从而确定出全局拓扑。In this step, according to the obtained topology information between switches in the own network domain and the topology information between switches in the network domain where other SDN controllers are located, obtained from the distributed database synchronization, the relationship between the ports of each switch in each network domain in the entire network can be obtained. According to the connection relationship between them, a topology map can be spelled out to determine the global topology.
以图3所示为例,交换机3111、交换机3211、交换机3121、交换机3122、交换机3221和交换机3222可以采用32╳40G接口的DC Core(Data Center Core,核心交换机);交换机3131、交换机3132和交换机3231可以采用48╳10G+4╳40G的TOR(柜顶式交换机);在这种拓扑结构下,采用48台DC Core和128台TOR可以提供3:1收敛的6144个10G的接入口。将该接入口连接X86服务器,该X86服务器上运行Vswitch(虚拟交换机)和SDN控制器,作为转发使用。如果按照24核、128G内存的服务器配置,本实施例可以提供10万规模的网络拓扑。与采用一台SDN控制器的现有技术相比,扩大了全局网络拓扑的规模。Taking Figure 3 as an example,
本发明实施例由于利用SDN控制器集群中各个SDN控制器分别获取各自所在网络域内的拓扑信息,并再通过分布式数据库获取其他各个SDN控制器所获得的拓扑信息,由此实现了全局网络拓扑的发现。In the embodiment of the present invention, each SDN controller in the SDN controller cluster is used to obtain the topology information in the respective network domains, and then the topology information obtained by the other SDN controllers is obtained through the distributed database, thereby realizing the global network topology. 's discovery.
在现有使用分布式数据库发现网络拓扑的方案中,使用分布式数据库统一存放网络拓扑和流表以及OpenDayLight等SDN控制器状态等信息,也就是把所有状态信息都剥离出去,统一存储在一个分布式数据库中。该方案虽然通过分布式数据库解决了规模化的瓶颈,但是,该方案将网络拓扑以及所有状态信息都存放在统一的数据库中。因此,该方案不仅增加了控制器的逻辑复杂度,而且对于分布式数据库的性能要求也很高,比如,实时变化的流表信息,如不能及时存储和更新,将会造成网络通路的混乱,导致网络故障。In the existing solution of using a distributed database to discover the network topology, the distributed database is used to store information such as network topology, flow table, and SDN controller status such as OpenDayLight in a unified manner, that is, all status information is stripped out and stored in a distributed database. in the database. Although this solution solves the bottleneck of scale through a distributed database, this solution stores the network topology and all state information in a unified database. Therefore, this scheme not only increases the logic complexity of the controller, but also has high performance requirements for the distributed database. For example, if the flow table information that changes in real time cannot be stored and updated in time, it will cause confusion in the network path. cause network failure.
另外,在现有采用部分控制器使用二段提交方式的方案中,将控制器分为两层。其中,下面一层的控制器各自管理部分OpenFlow交换机,上层为中央控制器,管理下层中的各个控制器,从下层控制器收取网络拓扑信息,从而发现全局拓扑。在该方案中,下层控制器能够处理部分流表下发等请求,只有不能处理的请求才转发到上层中央控制器进行处理。所以,当下层中的控制器增多之后,中央控制器会成为性能瓶颈,从而造成网络性能不佳。In addition, in the existing solution that some controllers use the two-stage submission method, the controllers are divided into two layers. Among them, the controllers of the lower layer manage some OpenFlow switches respectively, the upper layer is the central controller, manages each controller in the lower layer, and receives network topology information from the lower layer controllers, thereby discovering the global topology. In this solution, the lower-level controller can process requests such as partial flow table issuance, and only requests that cannot be processed are forwarded to the upper-level central controller for processing. Therefore, when the number of controllers in the lower layer increases, the central controller will become a performance bottleneck, resulting in poor network performance.
然而,在本发明实施例中,提出了一个完善的分布式控制器方案,同样是使用统一的分布式数据库存取状态信息,但是,由于SDN控制器与分布式数据库之间只同步拓扑信息,该拓扑信息的信息量小且稳定、不会发生变化,而没有向该分布式数据库引入路径计算和流表下发等逻辑;所以,本发明实施例对分布式数据库的性能要求小,并由此还可以确保良好的全局拓扑同步实时性,还改善了网络性能。However, in the embodiment of the present invention, a complete distributed controller solution is proposed, which also uses a unified distributed database to access state information. However, since only topology information is synchronized between the SDN controller and the distributed database, The information amount of the topology information is small and stable, and will not change, and logic such as path calculation and flow table delivery is not introduced into the distributed database; therefore, the embodiment of the present invention has small performance requirements on the distributed database, and is implemented by This also ensures good global topology synchronization real-time and also improves network performance.
在一些可选的实施例中,基于上述任一实施例,如图6所示,基于SDN的全局网络管理方法还可以包括:In some optional embodiments, based on any of the foregoing embodiments, as shown in FIG. 6 , the SDN-based global network management method may further include:
S230:根据全局网络拓扑,控制自身所在网络域内各交换机进行数据转发。S230: Control each switch in the network domain where it is located to perform data forwarding according to the global network topology.
本实施例依据全局网络拓扑控制,控制自身网络域内各个交换机对数据包进行转发,并最终将该数据包转发至目的服务器。According to the global network topology control, this embodiment controls each switch in its own network domain to forward the data packet, and finally forwards the data packet to the destination server.
在具体实施过程中,可以将多个OpenFlow交换机和SDN控制器构成数据面;然后,通过数据面来转发数据包。In a specific implementation process, multiple OpenFlow switches and SDN controllers may form a data plane; then, data packets are forwarded through the data plane.
在一些可选的实施例中,在上述实施例的基础上,根据全局网络拓扑,控制自身所在网络域内各交换机进行数据转发的步骤具体包括:In some optional embodiments, on the basis of the above-mentioned embodiments, according to the global network topology, the step of controlling each switch in the network domain where it is located to perform data forwarding specifically includes:
根据全局网络拓扑生成流表,并向自身所在网络域内各交换机分别发送流表,控制自身所在网络域内各交换机进行数据转发。The flow table is generated according to the global network topology, and the flow table is sent to each switch in the network domain where it is located to control the data forwarding of each switch in the network domain where it is located.
在本实施例中,流表包括多个流表项;每个流表项可以包括一个或多个匹配域,具体地,可以包括诸如头域、目的MAC(Media Access Control,媒体接入控制层)地址、源MAC地址、目的IP地址、源IP地址、TCP端口号/UDP端口号、指令等。其中,指令用于指示通过哪个端口转发数据包。当然,流表项中还可以包括计数器等。其中,计数器用于统计该流表项被命中的次数。In this embodiment, the flow table includes multiple flow table entries; each flow table entry may include one or more matching fields, specifically, may include header fields, destination MAC (Media Access Control, Media Access Control layer) ) address, source MAC address, destination IP address, source IP address, TCP port number/UDP port number, commands, etc. Among them, the instruction is used to indicate which port to forward the packet through. Of course, the flow entry may also include a counter and the like. The counter is used to count the number of times the flow entry is hit.
作为示例,本步骤在向自身所在网络域内各交换机分别发送流表时,可以依据路径上交换机与自身跳数的多少,按照从小到大的顺序向各个交换机发送流表项。As an example, in this step, when the flow table is sent to each switch in the own network domain, the flow table entries may be sent to each switch in ascending order according to the number of hops between the switch and itself on the path.
另外,本领域技术人员应该能够理解,为了使得交换机可以转发数据包,可以向该交换机发送初始流表。具体地,可以采取控制平面和数据平面相分离的方式来获取流表。例如,OpenFlow交换机基于LLDP协议(Link LayerDiscovery Protocol,链路层发现协议)和STP协议(Spanning Tree Protocol,生成树协议)等连通控制平面,也就是通过上述协议生成的转发表实现各种OpenFlow控制消息的转发。OpenFlow交换机向SDN控制器发送流表请求;SDN控制器接收到该流表请求后,通过控制平面向该OpenFlow交换机发送流表项;OpenFlow交换机接收到该流表项后将其添加到自身本地维护的流表中,从而获得初始流表。In addition, those skilled in the art should be able to understand that, in order to enable the switch to forward data packets, an initial flow table may be sent to the switch. Specifically, the flow table can be obtained by separating the control plane and the data plane. For example, an OpenFlow switch connects to the control plane based on the LLDP (Link Layer Discovery Protocol, Link Layer Discovery Protocol) and STP (Spanning Tree Protocol, Spanning Tree Protocol) protocols, that is, through the forwarding table generated by the above protocols to implement various OpenFlow control messages 's forwarding. The OpenFlow switch sends a flow table request to the SDN controller; after the SDN controller receives the flow table request, it sends the flow table entry to the OpenFlow switch through the control plane; the OpenFlow switch adds the flow table entry to its own local maintenance after receiving the flow table entry to obtain the initial flow table.
在一些可选的实施例中,在上述实施例的基础上,自身所在网络域内各交换机包括多个提供商边缘交换机;如图7所示,根据全局网络拓扑生成流表的步骤包括如下步骤S231和步骤S232。其中:In some optional embodiments, on the basis of the above-mentioned embodiments, each switch in its own network domain includes multiple provider edge switches; as shown in FIG. 7 , the step of generating the flow table according to the global network topology includes the following step S231 and step S232. in:
S231:根据全局网络拓扑,按照预定算法计算多个提供商边缘交换机之间的路径。S231: Calculate paths between multiple provider edge switches according to a predetermined algorithm according to the global network topology.
其中,预定算法例如可以为最小路径算法、最优路径算法、关键路径算法等,但绝不限于此。The predetermined algorithm may be, for example, a minimum path algorithm, an optimal path algorithm, a critical path algorithm, etc., but is by no means limited thereto.
其中,提供商边缘交换机(即provideer edge交换机,简称PE设备)可以为所带负载小的交换机,例如可以为单个端口为10Gb吞吐量的交换机。PE设备例如可以为普通的交换机。该PE设备连接服务器。The provider edge switch (ie, provider edge switch, PE device for short) may be a switch with a small load, for example, a switch with a single port of 10 Gb throughput. The PE device can be, for example, an ordinary switch. The PE device is connected to the server.
与上述提供商边缘交换机相对应地,本文还定义了提供商交换机(即provider交换机,简称P设备),其可以为带负载大的交换机,例如,可以为单个端口为40Gb吞吐量的交换机。该P设备可以作为中间节点,未连接服务器。Corresponding to the above-mentioned provider edge switch, this paper also defines a provider switch (ie, provider switch, P device for short), which may be a switch with a large load, for example, a switch with a single port of 40Gb throughput. The P device can act as an intermediate node and is not connected to the server.
S232:生成包含路径的流表。S232: Generate a flow table including paths.
本实施例中,路径计算和流表均由各SDN控制器独自计算和存储,对分布式数据库的要求小,改善了网络性能。In this embodiment, the path calculation and the flow table are calculated and stored by each SDN controller independently, and the requirement for the distributed database is small, which improves the network performance.
在一些可选的实施例中,在上述实施例的基础上,如图8所示,根据全局网络拓扑,按照预定算法计算多个提供商边缘交换机之间的路径的步骤具体可以包括步骤S2311至步骤S2313。其中:In some optional embodiments, on the basis of the foregoing embodiments, as shown in FIG. 8 , according to the global network topology, the step of calculating paths between multiple provider edge switches according to a predetermined algorithm may specifically include steps S2311 to S2311 to Step S2313. in:
S2311:接收自身所在网络域内交换机发送的数据包。S2311: Receive the data packet sent by the switch in the network domain where the self is located.
当至少发生以下情况时,交换机将数据包发送至SDN控制器:The switch sends the packet to the SDN controller when at least the following conditions occur:
情况一:交换机接收到没有与任何流表项相匹配的数据包;Case 1: The switch receives a packet that does not match any flow entry;
上述情况发生时,交换机将数据包发送至自身所在网络域内的SDN控制器,以获得可以匹配的流表。When the above situation occurs, the switch sends the data packet to the SDN controller in its own network domain to obtain a matching flow table.
情况二:交换机接收到数据包,但没有接收到SDN控制器下发的流表。Case 2: The switch receives the data packet, but does not receive the flow table sent by the SDN controller.
上述情况包括交换机在预定时间(例如,3分钟、5分钟)内没有匹配到流表,而将不匹配的流表删除的情况。在情况二发生时,交换机将数据包发送至SDN控制器,以获取与数据包相匹配的流表。The above situation includes the situation that the switch does not match the flow table within a predetermined time (for example, 3 minutes, 5 minutes), and deletes the unmatched flow table. When the second situation occurs, the switch sends the packet to the SDN controller to obtain a flow table that matches the packet.
S2312:解析数据包,得到目的MAC地址。S2312: Parse the data packet to obtain the destination MAC address.
S2313:根据全局网络拓扑和目的MAC地址,按照预定算法计算多个提供商边缘交换机之间的路径。S2313: Calculate paths between multiple provider edge switches according to a predetermined algorithm according to the global network topology and the destination MAC address.
其中,预定算法例如可以为最小路径算法、最优路径算法、关键路径算法等,但绝不限于此。The predetermined algorithm may be, for example, a minimum path algorithm, an optimal path algorithm, a critical path algorithm, etc., but is by no means limited thereto.
为了便于网络管理和路径计算,本发明实施例将交换机区分为提供商边缘交换机和提供商交换机,也就是将交换机分为PE(provider edge,提供商边缘)角色和P(provider,提供商)角色,分别简称PE设备和P设备。交换机的角色适用于SDN控制器,对物理交换机透明。SDN控制器根据角色来维护网络域内的拓扑。具体地,P设备在网络拓扑中仅作为中间节点,不作为路径计算的源或者目的节点;在发现网络拓扑时,PE设备之间的link(链路)判定为非法链接,其被忽略。所以,本步骤按照诸如最小路径算法、最优路径算法、关键路径算法等计算PE设备间的路径。To facilitate network management and path calculation, the embodiments of the present invention divide switches into provider edge switches and provider switches, that is, divide switches into PE (provider edge, provider edge) roles and P (provider, provider) roles , referred to as PE equipment and P equipment, respectively. The role of the switch applies to the SDN controller and is transparent to the physical switch. The SDN controller maintains the topology within the network domain based on roles. Specifically, the P device only acts as an intermediate node in the network topology, and does not act as a source or destination node for path calculation; when the network topology is discovered, the link between the PE devices is determined to be an illegal link and is ignored. Therefore, in this step, paths between PE devices are calculated according to, for example, a minimum path algorithm, an optimal path algorithm, and a critical path algorithm.
在实际应用中,上述P角色和PE角色可以通过SwitchRoleManager(交换机角色管理器)来维护交换机与角色的对应关系。用户可以通过Restful API(RepresentationalState Transfer API,资源表现层状态转化应用程序编程接口)查看所有交换机的角色信息,或者设定/删除某个交换机的角色配置。In practical applications, the above-mentioned P roles and PE roles can maintain the corresponding relationship between switches and roles through the SwitchRoleManager (switch role manager). Users can view the role information of all switches, or set/delete the role configuration of a switch through the Restful API (Representational State Transfer API).
下面结合图9以具体的实施例对本发明实施例根据交换机角色维护全局网络拓扑的过程进行详细说明。本实施例以网络域内接入交换机为例。The process of maintaining the global network topology according to the switch role according to the embodiment of the present invention will be described in detail below with reference to FIG. 9 with a specific embodiment. In this embodiment, an access switch in a network domain is used as an example.
当网络域内有新的交换机接入并与SDN控制器相连时,该SDN控制器识别该交换机;根据预定的交换机与角色的对应关系,确定所述交换机的角色;将确定了角色的交换机的Link线(也称为Link,即链路)、拓扑信息发送至分布式数据库。When a new switch in the network domain is connected and connected to the SDN controller, the SDN controller identifies the switch; determines the role of the switch according to the predetermined correspondence between the switch and the role; links the link of the switch whose role is determined Lines (also called Links), topology information is sent to a distributed database.
具体地,如图9所示,SDN控制器可以包括拓扑管理器、交换机角色管理器、域拓扑管理器和全局拓扑管理器。Specifically, as shown in FIG. 9 , the SDN controller may include a topology manager, a switch role manager, a domain topology manager, and a global topology manager.
当存在交换机接入网络时,执行以下步骤:When there is a switch connected to the network, perform the following steps:
步骤a1:拓扑管理器向交换机角色管理器发送交换机连接控制器通知;Step a1: The topology manager sends a switch connection controller notification to the switch role manager;
步骤a2:交换机角色管理器在角色信息存在的情况下,对交换机的角色进行设置,并将设置后的角色信息发送至域拓扑管理器;Step a2: The switch role manager sets the role of the switch when the role information exists, and sends the set role information to the domain topology manager;
步骤a3:域拓扑管理器将交换机加入本地控制器拓扑;域拓扑管理器获取与该交换机相关的链路,并将其发送至拓扑管理器;将合法的Link线加入拓扑,并初始化链路权重,删除非法的Link线;将更新的拓扑信息发送至全局拓扑管理器,更新之后,计算路径、流表预下发、更新链路权重;Step a3: The domain topology manager adds the switch to the local controller topology; the domain topology manager obtains the link related to the switch and sends it to the topology manager; adds the legal Link line to the topology, and initializes the link weight , delete the illegal Link line; send the updated topology information to the global topology manager, after the update, calculate the path, pre-delivery the flow table, and update the link weight;
步骤a4:全局拓扑管理器将分布式数据库的更新信息发送至域拓扑管理器,以供其他SDN控制根据更新后的全局网络拓扑信息,按照预定算法计算多个提供商边缘交换机之间的路径。Step a4: The global topology manager sends the update information of the distributed database to the domain topology manager for other SDN control to calculate paths between multiple provider edge switches according to a predetermined algorithm according to the updated global network topology information.
同理,当交换机与所在网络域内的SDN控制器断开连接时,处理过程与交换机接入的情况类似,在此不再赘述。Similarly, when the switch is disconnected from the SDN controller in the network domain where the switch is located, the processing process is similar to that of the switch access, which is not repeated here.
下面结合图10以具体的实施例对本发明实施例根据交换机角色维护全局网络拓扑的过程进行详细说明。本实施例以链路状态变化为例。The process of maintaining the global network topology according to the switch role according to the embodiment of the present invention will be described in detail below with reference to FIG. 10 with a specific embodiment. This embodiment takes the link state change as an example.
当网络拓扑中链路状态变化时,会触发域拓扑管理器进行相关处理。新增Link线时,会更新本地拓扑,然后将信息更新到分布式数据库,共其他SDN控制器进行全局拓扑同步。当Link线断开时,会检测本地拓扑中是否存在该Link线;若存在,则更新路径计算和流表下发等操作;然后,将该Link线删除,并更新至分布式数据库中。When the link status in the network topology changes, the domain topology manager is triggered to perform related processing. When a new link line is added, the local topology will be updated, and then the information will be updated to the distributed database, and the global topology will be synchronized with other SDN controllers. When the link line is disconnected, it will detect whether the link line exists in the local topology; if it exists, the operations such as path calculation and flow table delivery will be updated; then, the link line will be deleted and updated to the distributed database.
如图10所示,拓扑管理器向域拓扑管理器发送Link增加/断开消息;域拓扑管理器在Link合法的情况下,将Link加入拓扑,初始化链路权重为1(),然后,向全局拓扑管理器发送更新分布式数据库的指令;在Link非法的情况下,域拓扑管理器将Link标志警告,不作处理。如果拓扑中存在该Link,则域拓扑管理器从拓扑中删除该Link,然后,向全局拓扑管理器发送更新分布式数据库信息;如果拓扑中不存在该Link,则域拓扑管理器从告警Link中删除该Link,进行相关路径计算、流表下发等操作。当有Link线断开时,会检测本地拓扑中是否存在该Link线,若存在,则会更新路径计算和流表下发等操作,然后,将Link线删除,并更新到分布式数据库,以供其他SDN控制器根据更新后的全局网络拓扑信息,按照预定算法计算多个提供商边缘交换机之间的路径。As shown in Figure 10, the topology manager sends a Link add/disconnect message to the domain topology manager; when the link is valid, the domain topology manager adds the link to the topology, initializes the link weight to 1(), and then sends the link to the The global topology manager sends an instruction to update the distributed database; if the link is illegal, the domain topology manager will mark the link as a warning and will not handle it. If the link exists in the topology, the domain topology manager deletes the link from the topology, and then sends the updated distributed database information to the global topology manager; if the link does not exist in the topology, the domain topology manager deletes the link from the alarm link Delete the link and perform operations such as related path calculation and flow table delivery. When a link line is disconnected, it will detect whether the link line exists in the local topology. If it exists, it will update the path calculation and flow table distribution and other operations, and then delete the link line and update it to the distributed database to For other SDN controllers to calculate paths between multiple provider edge switches according to the updated global network topology information according to a predetermined algorithm.
现有技术中,由于只采取一台SDN控制器对网络进行集中式管理。如果这台SDN控制器发生故障宕机,由于没有备用的SDN控制器接替该发生故障宕机的SDN控制器,因此整个网络就无法正常工作了。因而,现有技术存在单点故障的缺陷。In the prior art, only one SDN controller is used to centrally manage the network. If this SDN controller fails and goes down, since there is no backup SDN controller to take over the failed SDN controller, the entire network cannot work normally. Therefore, the prior art suffers from a single point of failure.
鉴于上述现有技术存在的缺陷,在一些可选的实施例中,在图4所示实施例的基础上,基于SDN的全局网络管理方法还包括如下步骤b1和步骤b2。In view of the above-mentioned defects in the prior art, in some optional embodiments, on the basis of the embodiment shown in FIG. 4 , the SDN-based global network management method further includes the following steps b1 and b2.
步骤b1:接收自身所在网络域之外的其他网络域内交换机发送的网络连接请求;其中,网络连接请求是由其他网络域内的交换机在其他网络域的SDN控制器出现故障时发送的;Step b1: receiving network connection requests sent by switches in other network domains other than the network domain where the network domain is located; wherein, the network connection requests are sent by switches in other network domains when the SDN controller of other network domains fails;
本步骤在具体实施过程中,可以在交换机中配置至少两台SDN控制器的IP地址,以使得该交换机可以收到至少两台SDN控制器的管理。In the specific implementation process of this step, the IP addresses of at least two SDN controllers may be configured in the switch, so that the switch can receive management from the at least two SDN controllers.
举例而言,如果将OpenFlow交换机与第一SDN控制器和第二SDN控制器相连,则在该OpenFlow交换机中配置第一SDN控制器和第二SDN控制器的IP地址,并使得该OpenFlow交换机与第一SDN控制器处于同一网络域内。这样,该OpenFlow交换机与第二SDN控制器处于不同的网络域。当第一SDN控制器发生故障时,该OpenFlow交换机由于配置有第二SDN控制器的IP地址,因而,此时,该OpenFlow交换机可以去连接第二SDN控制器,也就是向第二SDN控制器发送网络连接请求。第二SDN控制器接收其他网络域内的、该OpenFlow交换机发送的网络连接请求。For example, if an OpenFlow switch is connected to the first SDN controller and the second SDN controller, configure the IP addresses of the first SDN controller and the second SDN controller in the OpenFlow switch, and make the OpenFlow switch connect with the first SDN controller and the second SDN controller. The first SDN controller is in the same network domain. In this way, the OpenFlow switch and the second SDN controller are in different network domains. When the first SDN controller fails, the OpenFlow switch is configured with the IP address of the second SDN controller. Therefore, at this time, the OpenFlow switch can connect to the second SDN controller, that is, to the second SDN controller. Send a network connection request. The second SDN controller receives the network connection request sent by the OpenFlow switch in other network domains.
步骤b2:根据网络连接请求,与其他网络域内的交换机建立网络连接。Step b2: According to the network connection request, establish network connections with switches in other network domains.
沿用上例,当第二SDN控制器接收到该网络连接请求后,与该OpenFlow交换机建立网络连接,以对该OpenFlow交换机进行管理。其中,该网络连接例如可以为TCP(传输控制协议)连接。Following the above example, after receiving the network connection request, the second SDN controller establishes a network connection with the OpenFlow switch to manage the OpenFlow switch. The network connection may be, for example, a TCP (Transmission Control Protocol) connection.
本实施例由于将交换机与至少两台SDN控制器相连;因此,当其中一台SDN控制器发生故障宕机而无法正常工作时,该交换机可以与其他未发生故障宕机的SDN控制器进行网络连接而维持正常的工作。故,与采用一主多备的方案相比,本实施例克服了单点故障的缺陷,而且通过本发明实施例提供的技术方案,可以使得网络不受限于一台SDN控制器的性能的影响,克服了性能瓶颈的缺陷,从而提高了网络的处理速度和网络拓扑规模。In this embodiment, the switch is connected to at least two SDN controllers; therefore, when one of the SDN controllers fails and goes down and cannot work normally, the switch can network with other SDN controllers that do not fail and go down. connection to maintain normal operation. Therefore, compared with the scheme using one master and multiple backups, this embodiment overcomes the defect of a single point of failure, and the technical scheme provided by the embodiment of the present invention can make the network not limited by the performance of one SDN controller. It overcomes the defect of performance bottleneck, thereby improving the processing speed of the network and the scale of the network topology.
综上所述,本发明实施例通过采取上述任一技术方案,通过SDN控制器集群来控制交换机,并使得每一个SDN控制器在一个网络域内与多个交换机相连,SDN控制器集群中的每一个SDN控制器不仅获取自身所在网络域内的第一拓扑信息,而且还通过分布式数据库获取其他SDN控制器所在网络域的第二拓扑信息,从而使得每一个SDN控制器可以获得整个网络的全局网络拓扑,由此扩大了网络拓扑的规模,并且可以实现网络拓扑规模的无限扩展。而且通过分布式数据库获取其他SDN控制器所在网络域内的第二拓扑信息的步骤,还实现了全局拓扑信息的同步更新。另外,在本发明实施例中,SDN控制器从分布式数据库获取的是拓扑信息,而没有涉及到诸如与路径计算、流表下发等相关信息;因此,本发明实施例对分布式数据库的性能要求小,提高了网络性能,从而克服了现有技术存在的SDN控制性能瓶颈的缺陷。To sum up, in this embodiment of the present invention, by adopting any of the above technical solutions, the switches are controlled through the SDN controller cluster, and each SDN controller is connected to multiple switches in one network domain. An SDN controller not only obtains the first topology information in its own network domain, but also obtains the second topology information of the network domain where other SDN controllers are located through a distributed database, so that each SDN controller can obtain the global network of the entire network. Therefore, the scale of the network topology is expanded, and the infinite expansion of the scale of the network topology can be realized. Moreover, the step of obtaining the second topology information in the network domain where other SDN controllers are located through the distributed database also realizes the synchronous update of the global topology information. In addition, in the embodiment of the present invention, the SDN controller obtains topology information from the distributed database, and does not involve related information such as path calculation, flow table delivery, etc.; The performance requirements are small, and the network performance is improved, thereby overcoming the defect of the SDN control performance bottleneck existing in the prior art.
现有的OpenFlow网络由于通常采用一台SDN控制器来发现全局网络拓扑以对交换机进行管理而存在全局网络拓扑规模小的缺陷。由此,网络额规模化支持受限于SDN控制器的性能。因此,为了解决如何扩大全局网络拓扑规模的技术问题,本发明实施例提供一种基于软件定义网络SDN的全局网络管理装置,该装置可以执行上述方法实施例。装置应用于SDN控制器,SDN控制器属于SDN控制器集群,SDN控制器集群中各SDN控制器分别与分布式数据库相连,且各SDN控制器分别与多个互连的交换机相连并形成一网络域;如图11所示,基于SDN的全局网络管理装置包括:The existing OpenFlow network has the defect of small scale of the global network topology because an SDN controller is usually used to discover the global network topology to manage the switches. Thus, network scale support is limited by the capabilities of the SDN controller. Therefore, in order to solve the technical problem of how to expand the scale of the global network topology, an embodiment of the present invention provides a software-defined network SDN-based global network management apparatus, which can execute the above method embodiments. The device is applied to an SDN controller. The SDN controller belongs to an SDN controller cluster. Each SDN controller in the SDN controller cluster is respectively connected to a distributed database, and each SDN controller is respectively connected to a plurality of interconnected switches to form a network. domain; as shown in Figure 11, the SDN-based global network management device includes:
第一获取模块111,用于获取自身所在网络域内交换机间的第一拓扑信息;The first obtaining
第二获取模块112,用于从分布式数据库获取SDN控制器集群中其他SDN控制器所在网络域内交换机间的第二拓扑信息;The second obtaining
确定模块113,用于根据第一拓扑信息和第二拓扑信息,确定全局网络拓扑。The determining
本实施例通过SDN控制器集群来控制交换机,并使得每一个SDN控制器在一个网络域内与多个交换机相连,SDN控制器集群中的每一个SDN控制器不仅通过第一获取模块111获取自身所在网络域内的第一拓扑信息,而且还通过第二获取模块112从分布式数据库获取其他SDN控制器所在网络域的第二拓扑信息,从而通过确定模块113可以获得整个网络的全局网络拓扑,由此扩大了网络拓扑的规模,并且可以实现网络拓扑规模的无限扩展。而且,通过第二获取模块112从分布式数据库获取其他SDN控制器所在网络域内的第二拓扑信息的步骤,还实现了全局拓扑信息的同步更新。另外,在本发明实施例中,SDN控制器从分布式数据库获取的是拓扑信息,而没有涉及到诸如与路径计算、流表下发等相关信息;因此,本发明实施例对分布式数据库的性能要求小,提高了网络性能,从而克服了现有技术存在的SDN控制性能瓶颈的缺陷。In this embodiment, the switches are controlled through the SDN controller cluster, and each SDN controller is connected to multiple switches in one network domain. Each SDN controller in the SDN controller cluster not only obtains its own location through the first obtaining
在一些可选的实施例中,如图12所示,第一获取模块包括:In some optional embodiments, as shown in FIG. 12 , the first acquisition module includes:
第一发送单元121,用于向自身所在网络域内的交换机分别发送拓扑信息请求;The
第一接收单元122,用于分别接收各交换机针对拓扑信息请求发送的端口信息及与之相连的交换机的端口信息;The
第一获取单元123,用于根据接收到的端口信息,得到自身所在网络域内交换机间的第一拓扑信息。The first obtaining
在一些可选的实施例中,如图13所示,基于SDN的全局网络管理装置还可以包括:In some optional embodiments, as shown in FIG. 13 , the SDN-based global network management apparatus may further include:
发送模块114,用于将第一拓扑信息发送至分布式数据库。The sending
在一些可选的实施例中,如图14所示,第二获取模块具体包括:In some optional embodiments, as shown in FIG. 14 , the second acquisition module specifically includes:
第二接收单元141,用于接收分布式数据库发送的拓扑信息更新通知;其中,拓扑信息更新通知为分布式数据库在接收到由其他SDN控制器发送的第二拓扑信息时发送的;The
第二获取单元142,用于根据拓扑信息更新通知从分布式数据库获取SDN控制器集群中其他SDN控制器所在网络域内交换机间的第二拓扑信息。The second obtaining
在一些可选的实施例中,基于SDN的全局网络管理装置还可以包括:In some optional embodiments, the SDN-based global network management apparatus may further include:
控制模块,用于根据全局网络拓扑,控制自身所在网络域内各交换机进行数据转发。The control module is used to control each switch in the network domain where it is located to perform data forwarding according to the global network topology.
在一些可选的实施例中,控制模块具体用于根据全局网络拓扑生成流表,并向自身所在网络域内各交换机分别发送流表,控制自身所在网络域内各交换机进行数据转发。In some optional embodiments, the control module is specifically configured to generate a flow table according to the global network topology, send the flow table to each switch in the network domain where it is located, and control each switch in the network domain where it is located to perform data forwarding.
在一些可选的实施例中,自身所在网络域内各交换机包括多个提供商边缘交换机;In some optional embodiments, each switch in the network domain where it is located includes multiple provider edge switches;
如图15所示,控制模块具体包括:As shown in Figure 15, the control module specifically includes:
计算单元151,用于根据全局网络拓扑,按照预定算法计算多个提供商边缘交换机之间的路径;a
生成单元152,用于生成包含路径的流表。The generating
在一些可选的实施例中,如图16所示,计算单元具体包括:In some optional embodiments, as shown in FIG. 16 , the computing unit specifically includes:
接收子单元161,用于接收自身所在网络域内交换机发送的数据包;The receiving
解析子单元162,用于解析数据包,得到目的MAC地址;The parsing
计算子单元163,用于根据全局网络拓扑和目的MAC地址,按照预定算法计算多个提供商边缘交换机之间的路径。The
在一些可选的实施例中,基于SDN的全局网络管理装置还可以包括:In some optional embodiments, the SDN-based global network management apparatus may further include:
接收模块,用于接收自身所在网络域之外的其他网络域内交换机发送的网络连接请求;其中,网络连接请求是由其他网络域内的交换机在其他网络域的SDN控制器出现故障时发送的;The receiving module is used to receive network connection requests sent by switches in other network domains other than its own network domain; wherein, the network connection requests are sent by switches in other network domains when the SDN controller in other network domains fails;
建立模块,用于根据网络连接请求,与其他网络域内的交换机建立网络连接。The establishment module is used for establishing network connection with switches in other network domains according to the network connection request.
有关基于SDN的全局网络管理装置实施例的说明可以参考前述基于SDN的全局网络管理方法实施例的说明,在此不再赘述。For the description of the embodiment of the SDN-based global network management apparatus, reference may be made to the description of the foregoing SDN-based global network management method embodiment, which will not be repeated here.
基于与方法实施例相同的技术构思,本发明实施例还提供了一种电子设备,如图17所示,包括处理器171和存储器172;Based on the same technical idea as the method embodiment, the embodiment of the present invention further provides an electronic device, as shown in FIG. 17 , including a
存储器172,用于存放计算机程序;a
处理器171,用于执行存储器172上所存放的程序时,实现上述基于SDN的全局网络管理方法实施例中所述的方法步骤。The
当然,本领域技术人员应能理解,上述实施例还可以包括通信接口和通信总线,这些明显变形或等同替换的实施例也应包含在本发明的保护范围之内。Of course, those skilled in the art should understand that the above embodiments may also include a communication interface and a communication bus, and these obviously modified or equivalently replaced embodiments should also be included within the protection scope of the present invention.
上述电子设备提到的通信总线可以是外设部件互连标准(Peripheral ComponentInterconnect,PCI)总线或扩展工业标准结构(Extended Industry StandardArchitecture,EISA)总线等。该通信总线可以分为地址总线、数据总线、控制总线等。为便于表示,图17中仅用一条粗线表示,但并不表示仅有一根总线或一种类型的总线。The communication bus mentioned in the above electronic device may be a peripheral component interconnect standard (Peripheral Component Interconnect, PCI) bus or an Extended Industry Standard Architecture (Extended Industry Standard Architecture, EISA) bus or the like. The communication bus can be divided into an address bus, a data bus, a control bus, and the like. For ease of representation, only one thick line is shown in FIG. 17, but it does not mean that there is only one bus or one type of bus.
上述通信接口用于上述电子设备与其他设备之间的通信。The above-mentioned communication interface is used for communication between the above-mentioned electronic device and other devices.
上述存储器172可以包括随机存取存储器(Random Access Memory,RAM),也可以包括非易失性存储器(non-volatile memory,NVM),例如至少一个磁盘存储器。可选的,存储器还可以是至少一个位于远离前述处理器的存储装置。The above-mentioned
上述的处理器171可以是通用处理器,包括中央处理器(Central ProcessingUnit,简称CPU)、网络处理器(Ne twork Processor,NP)等;还可以是数字信号处理器(Digital Signal Processing,DSP)、专用集成电路(Applica tion Specific IntegratedCircuit,ASIC)、现场可编程门阵列(Field-Programmable Gate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件。The above-mentioned
上述电子设备包括但不限于智能手机、计算机、个人数字助理、可穿戴设备等。The above electronic devices include but are not limited to smart phones, computers, personal digital assistants, wearable devices, and the like.
本实施例中,通过处理器171执行存储器172上所存放的程序,实现了通过SDN控制器集群来控制交换机,并使得每一个SDN控制器在一个网络域内与多个交换机相连,SDN控制器集群中的每一个SDN控制器不仅获取自身所在网络域内的第一拓扑信息,而且还通过分布式数据库获取其他SDN控制器所在网络域的第二拓扑信息,从而使得每一个SDN控制器可以获得整个网络的全局网络拓扑,由此扩大了网络拓扑的规模,并且可以实现网络拓扑规模的无限扩展。而且通过分布式数据库获取其他SDN控制器所在网络域内的第二拓扑信息的步骤,还实现了全局拓扑信息的同步更新。另外,在本发明实施例中,SDN控制器从分布式数据库获取的是拓扑信息,而没有涉及到诸如与路径计算、流表下发等相关信息;因此,本发明实施例对分布式数据库的性能要求小,提高了网络性能,从而克服了现有技术存在的SDN控制性能瓶颈的缺陷。In this embodiment, by executing the program stored in the
基于与方法实施例相同的技术构思,本发明实施例还提供了一种计算机可读存储介质。该计算机可读存储介质内存储有计算机程序,计算机程序被处理器执行时实现上述基于SDN的全局网络管理方法实施例中所述的方法步骤。Based on the same technical concept as the method embodiments, the embodiments of the present invention further provide a computer-readable storage medium. A computer program is stored in the computer-readable storage medium, and when the computer program is executed by the processor, the method steps described in the foregoing embodiments of the SDN-based global network management method are implemented.
上述计算机可读存储介质可以包括但不限于随机存取存储器(RAM)、动态随机存取存储器(DRAM)、静态随机存取存储器(SRAM)、只读存储器(ROM)、可编程只读存储器(PROM)、可擦写可编程只读存储器(EPROM)、电可擦写可编程只读存储器(EEPROM)、闪存(例如,NOR型闪存或NAND型闪存)、内容可寻址存储器(CAM)、聚合物存储器(例如,铁电聚合物存储器)、相变存储器、双向开关半导体存储器、硅-氧化物-氮化硅-氧化硅-硅(Silicon-Oxide-Nitride-Oxide-Silicon,SONOS)存储器、磁卡或者光卡,亦或是其他任意适当类型的计算机可读存储介质。The above-mentioned computer-readable storage medium may include, but is not limited to, random access memory (RAM), dynamic random access memory (DRAM), static random access memory (SRAM), read only memory (ROM), programmable read only memory ( PROM), Erasable Programmable Read Only Memory (EPROM), Electrically Erasable Programmable Read Only Memory (EEPROM), Flash Memory (eg, NOR-type Flash or NAND-type Flash), Content Addressable Memory (CAM), Polymer memory (eg, ferroelectric polymer memory), phase change memory, bidirectional switching semiconductor memory, silicon-oxide-silicon nitride-silicon-oxide-silicon (SONOS) memory, Magnetic card or optical card, or any other suitable type of computer-readable storage medium.
本实施例中,计算机程序被处理器执行时实现了通过SDN控制器集群来控制交换机,并使得每一个SDN控制器在一个网络域内与多个交换机相连,SDN控制器集群中的每一个SDN控制器不仅获取自身所在网络域内的第一拓扑信息,而且还通过分布式数据库获取其他SDN控制器所在网络域的第二拓扑信息,从而使得每一个SDN控制器可以获得整个网络的全局网络拓扑,由此扩大了网络拓扑的规模,并且可以实现网络拓扑规模的无限扩展。而且通过分布式数据库获取其他SDN控制器所在网络域内的第二拓扑信息的步骤,还实现了全局拓扑信息的同步更新。另外,在本发明实施例中,SDN控制器从分布式数据库获取的是拓扑信息,而没有涉及到诸如与路径计算、流表下发等相关信息;因此,本发明实施例对分布式数据库的性能要求小,提高了网络性能,从而克服了现有技术存在的SDN控制性能瓶颈的缺陷。In this embodiment, when the computer program is executed by the processor, the switches are controlled through the SDN controller cluster, and each SDN controller is connected to multiple switches in one network domain, and each SDN controller in the SDN controller cluster controls the switches. The controller not only obtains the first topology information in its own network domain, but also obtains the second topology information of the network domain where other SDN controllers are located through the distributed database, so that each SDN controller can obtain the global network topology of the entire network. This enlarges the scale of the network topology, and can realize the infinite expansion of the scale of the network topology. Moreover, the step of obtaining the second topology information in the network domain where other SDN controllers are located through the distributed database also realizes the synchronous update of the global topology information. In addition, in the embodiment of the present invention, the SDN controller obtains topology information from the distributed database, and does not involve related information such as path calculation, flow table delivery, etc.; The performance requirements are small, and the network performance is improved, thereby overcoming the defect of the SDN control performance bottleneck existing in the prior art.
需要说明的是,在本文中,诸如第一和第二等之类的关系术语仅仅用来将一个实体或者操作与另一个实体或操作区分开来,而不一定要求或者暗示这些实体或操作之间存在任何这种实际的关系或者顺序。而且,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、物品或者设备中还存在另外的相同要素。It should be noted that, in this document, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any relationship between these entities or operations. any such actual relationship or sequence exists. Moreover, the terms "comprising", "comprising" or any other variation thereof are intended to encompass non-exclusive inclusion such that a process, method, article or device comprising a list of elements includes not only those elements, but also includes not explicitly listed or other elements inherent to such a process, method, article or apparatus. Without further limitation, an element qualified by the phrase "comprising a..." does not preclude the presence of additional identical elements in a process, method, article or apparatus that includes the element.
本说明书中的各个实施例均采用相关的方式描述,每个实施例重点说明的都是与其他实施例的不同之处,各个实施例之间相同相似的部分互相参见即可。尤其,对于装置实施例而言,由于其基本相似于方法实施例,所以描述的比较简单,相关之处参见方法实施例的部分说明即可。以上所述仅为本发明的较佳实施例而已,并非用于限定本发明的保护范围。凡在本发明的精神和原则之内所作的任何修改、等同替换、改进等,均包含在本发明的保护范围内。The various embodiments in this specification are described in a related manner, and each embodiment focuses on the differences from other embodiments, and the same and similar parts between the various embodiments can be referred to each other. In particular, for the apparatus embodiments, since they are basically similar to the method embodiments, the description is relatively simple, and reference may be made to some descriptions of the method embodiments for related parts. The above descriptions are only preferred embodiments of the present invention, and are not intended to limit the protection scope of the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention are included in the protection scope of the present invention.
Claims (14)
Priority Applications (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201711283418.8A CN109905251B (en) | 2017-12-07 | 2017-12-07 | Network management method, apparatus, electronic device and storage medium |
| PCT/CN2018/119512 WO2019109970A1 (en) | 2017-12-07 | 2018-12-06 | Network management method and apparatus, electronic device and storage medium |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201711283418.8A CN109905251B (en) | 2017-12-07 | 2017-12-07 | Network management method, apparatus, electronic device and storage medium |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| CN109905251A CN109905251A (en) | 2019-06-18 |
| CN109905251B true CN109905251B (en) | 2020-12-18 |
Family
ID=66750816
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN201711283418.8A Active CN109905251B (en) | 2017-12-07 | 2017-12-07 | Network management method, apparatus, electronic device and storage medium |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN109905251B (en) |
| WO (1) | WO2019109970A1 (en) |
Families Citing this family (14)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| EP3917086B1 (en) * | 2020-05-30 | 2023-04-05 | Huawei Technologies Co., Ltd. | Network topology discovery method, device, and system |
| CN111585917B (en) * | 2020-06-10 | 2021-03-30 | 广州市品高软件股份有限公司 | Bare metal server network system and implementation method thereof |
| CN112187523A (en) * | 2020-09-10 | 2021-01-05 | 华云数据控股集团有限公司 | Network high-availability implementation method and super-convergence system |
| CN112689163A (en) * | 2020-12-02 | 2021-04-20 | 中国民航机场建设集团有限公司 | Video service transmission system and method based on SDN and in-network cache |
| CN114629791B (en) * | 2020-12-21 | 2024-03-26 | 亚信科技(中国)有限公司 | Data processing method, device, electronic equipment and computer readable storage medium |
| CN113055232B (en) * | 2021-03-11 | 2022-07-12 | 浪潮思科网络科技有限公司 | Network configuration deployment method, device and equipment |
| CN115086978B (en) * | 2021-03-11 | 2024-05-07 | 中国移动通信集团四川有限公司 | Network Function Virtualization SDN Network System |
| CN113329055B (en) * | 2021-04-30 | 2023-04-07 | 网络通信与安全紫金山实验室 | Distributed SDN controller system and control method and device thereof |
| CN114422529B (en) * | 2022-01-21 | 2023-07-11 | 中国联合网络通信集团有限公司 | Data processing method, device and medium |
| CN115297157A (en) * | 2022-08-01 | 2022-11-04 | 中国电信股份有限公司 | Service processing method, device, system, medium and electronic equipment |
| CN115834327B (en) * | 2022-11-03 | 2025-05-13 | 紫金山实验室 | Controller system scheduling method, system and non-volatile storage medium |
| TWI824827B (en) * | 2022-11-17 | 2023-12-01 | 中華電信股份有限公司 | Management system and management method for network topology of software-defined network |
| CN118337698A (en) * | 2024-03-04 | 2024-07-12 | 鹏城实验室 | Fully distributed switch traffic scheduling method, device, equipment and storage medium |
| CN118573575A (en) * | 2024-04-28 | 2024-08-30 | 超聚变数字技术有限公司 | Topology updating method, computing device and super-fusion system |
Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN104618475A (en) * | 2015-01-28 | 2015-05-13 | 清华大学 | Horizontal direction communication method for heterogeneous SDN (self-defending network) and SDN system |
| CN104811325A (en) * | 2014-01-24 | 2015-07-29 | 华为技术有限公司 | Cluster node controller monitoring method, related device and controller |
| CN105072037A (en) * | 2015-07-23 | 2015-11-18 | 北京航空航天大学 | Dynamic flow generating method for distributed SDN controllers |
| CN106411736A (en) * | 2016-11-17 | 2017-02-15 | 中国电子科技集团公司第五十四研究所 | Node resource discovery strategy optimization method for software defined satellite network |
Family Cites Families (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN103684922B (en) * | 2013-12-23 | 2017-02-15 | 蓝盾信息安全技术股份有限公司 | Outlet information privacy checking detection platform system based on SDN (self-defending network) and detection method |
| CN105357024A (en) * | 2015-09-23 | 2016-02-24 | 清华大学 | Area control equipment, domain control equipment and control system for SDN (Software Defined Networking) |
| CN106936731A (en) * | 2015-12-31 | 2017-07-07 | 北京华为数字技术有限公司 | The method and apparatus of the message forwarding in software defined network SDN |
| CN107070681B (en) * | 2016-12-07 | 2020-10-09 | 全球能源互联网研究院有限公司 | Network topology obtaining method and device based on Software Defined Network (SDN) |
-
2017
- 2017-12-07 CN CN201711283418.8A patent/CN109905251B/en active Active
-
2018
- 2018-12-06 WO PCT/CN2018/119512 patent/WO2019109970A1/en not_active Ceased
Patent Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN104811325A (en) * | 2014-01-24 | 2015-07-29 | 华为技术有限公司 | Cluster node controller monitoring method, related device and controller |
| CN104618475A (en) * | 2015-01-28 | 2015-05-13 | 清华大学 | Horizontal direction communication method for heterogeneous SDN (self-defending network) and SDN system |
| CN105072037A (en) * | 2015-07-23 | 2015-11-18 | 北京航空航天大学 | Dynamic flow generating method for distributed SDN controllers |
| CN106411736A (en) * | 2016-11-17 | 2017-02-15 | 中国电子科技集团公司第五十四研究所 | Node resource discovery strategy optimization method for software defined satellite network |
Also Published As
| Publication number | Publication date |
|---|---|
| CN109905251A (en) | 2019-06-18 |
| WO2019109970A1 (en) | 2019-06-13 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN109905251B (en) | Network management method, apparatus, electronic device and storage medium | |
| US12445324B2 (en) | Single node and multiple node datastore architecture in a network routing environment | |
| US11563602B2 (en) | Method and apparatus for providing a point-to-point connection over a network | |
| CN106375231B (en) | A kind of flow switching method, equipment and system | |
| WO2023071324A1 (en) | Packet forwarding method and apparatus | |
| CN103997513A (en) | Programmable virtual network service system | |
| JP7190569B2 (en) | Data center traffic sharing method, apparatus, device and storage medium | |
| IL280472B1 (en) | System and method for using cloud network software | |
| WO2017054770A1 (en) | Cluster communication | |
| CN112187635A (en) | Message forwarding method and device | |
| CN116016448B (en) | Service network access method, device, equipment and storage medium | |
| CN115118655B (en) | Cross-network message forwarding method and device, electronic equipment and readable storage medium | |
| WO2024108493A1 (en) | Virtual and real combined dynamic traffic scheduling method and apparatus based on sdn and ndn | |
| CN106921576B (en) | Virtualization system-based data network and management network flow separation method and device | |
| CN104980526A (en) | Control method of media access control (MAC) address drift, control device of MAC address drift and network device | |
| WO2025102794A1 (en) | Data splitting method and apparatus, device, storage medium, and program product | |
| WO2016173196A1 (en) | Method and apparatus for learning address mapping relationship | |
| CN120528866B (en) | Network communication establishment method, system and computer equipment | |
| CN106330707A (en) | Network control method and network controller | |
| CN116319545B (en) | A method and device for processing route aggregation based on EVPN network | |
| CN117499295A (en) | Message forwarding method, device, equipment and storage medium | |
| WO2023169364A1 (en) | Routing generation method and apparatus, and data message forwarding method and apparatus | |
| CN119583430A (en) | Routing information transmission method, device, equipment, storage medium and program product | |
| WO2024082462A1 (en) | Service forwarding method and apparatus, and electronic device |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| GR01 | Patent grant | ||
| GR01 | Patent grant |
