[go: up one dir, main page]

CN104852849B - A kind of OSPF configuration methods and relevant apparatus - Google Patents

A kind of OSPF configuration methods and relevant apparatus Download PDF

Info

Publication number
CN104852849B
CN104852849B CN201510222353.0A CN201510222353A CN104852849B CN 104852849 B CN104852849 B CN 104852849B CN 201510222353 A CN201510222353 A CN 201510222353A CN 104852849 B CN104852849 B CN 104852849B
Authority
CN
China
Prior art keywords
master
router
ospf
ospf process
interface
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201510222353.0A
Other languages
Chinese (zh)
Other versions
CN104852849A (en
Inventor
王军
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201510222353.0A priority Critical patent/CN104852849B/en
Publication of CN104852849A publication Critical patent/CN104852849A/en
Application granted granted Critical
Publication of CN104852849B publication Critical patent/CN104852849B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The embodiment of the invention discloses a kind of OSPF configuration methods, are automatically configured for realizing OSPF.Present invention method includes:After enabling Virtual Cluster function on the first interface of the first Master, the first Master creates the first ospf process, and first interface is added in the first ospf process, and first interface is the interface being connected with the AP;First Master distributes the first router mark Router ID, the first Router ID in the first ospf process and is used for first Master of the unique mark in the first ospf process;First Master runs the first ospf process.

Description

一种OSPF配置方法以及相关装置A kind of OSPF configuration method and related device

技术领域technical field

本发明涉及互联网领域,尤其涉及一种OSPF配置方法以及相关装置。The present invention relates to the Internet field, in particular to an OSPF configuration method and related devices.

背景技术Background technique

虚拟集群系统一般由多个接入节点AP(AP,Access Point)和若干核心汇聚节点(Master)构成,其中AP一般采用小容量、低性能的低端路由器或交换机等设备;Master可以是具有大容量、高性能的路由器或交换机等设备。Master具有很强的控制管理能力,用于集中控制管理虚拟集群系统,虚拟集群系统对外只呈现Master。A virtual cluster system is generally composed of multiple access nodes (AP, Access Point) and several core aggregation nodes (Master). APs generally use low-end routers or switches with small capacity and low performance; Capacity, high-performance routers or switches and other equipment. The Master has strong control and management capabilities and is used for centralized control and management of the virtual cluster system. The virtual cluster system only presents the Master to the outside world.

现阶段的技术通过在虚拟集群系统内运行开放最短路径优先协议(OSPF,OpenShortest Path First)来收集虚拟集群系统的网络拓扑,这就要求用户配置集群系统中每个路由器上运行的OSPF进程的进程标识(Process ID)以及路由器在每个进程中的路由器标识(Router ID),以顺利运行这些OSPF进程。The current technology collects the network topology of the virtual cluster system by running the Open Shortest Path First protocol (OSPF, OpenShortest Path First) in the virtual cluster system, which requires the user to configure the process of the OSPF process running on each router in the cluster system ID (Process ID) and the router ID (Router ID) of the router in each process to run these OSPF processes smoothly.

但是,Router ID的配置需要用户预知虚拟集群系统的网络拓扑结构,并根据该网络拓扑结构人工规划路由器在每个进程中的Router ID,该操作较为复杂,工作量大,不利于网络的配置安装。However, the configuration of the Router ID requires the user to predict the network topology of the virtual cluster system and manually plan the Router ID of the router in each process according to the network topology. This operation is more complicated and the workload is heavy, which is not conducive to network configuration and installation. .

发明内容Contents of the invention

本发明实施例提供了一种OSPF配置方法中,用于在虚拟集群系统中实现OSPF的自动配置。The embodiment of the present invention provides an OSPF configuration method for realizing automatic configuration of OSPF in a virtual cluster system.

本发明实施例的第一方面提供了一种OSPF配置方法,适用于虚拟集群系统,所述虚拟集群系统包括核心汇聚节点Master与接入节点AP,所述方法包括:The first aspect of the embodiments of the present invention provides an OSPF configuration method, which is suitable for a virtual cluster system. The virtual cluster system includes a core aggregation node Master and an access node AP. The method includes:

当第一Master的第一接口上使能虚拟集群功能之后,所述第一Master创建第一OSPF进程,并将所述第一接口加入到所述第一OSPF进程中,所述第一接口是与所述AP相连的接口;After the virtual cluster function is enabled on the first interface of the first Master, the first Master creates a first OSPF process, and adds the first interface to the first OSPF process, and the first interface is an interface connected to the AP;

所述第一Master在所述第一OSPF进程中分配第一路由器标识Router ID,所述第一Router ID用于唯一标识在所述第一OSPF进程中的所述第一Master;The first Master assigns a first router identifier Router ID in the first OSPF process, and the first Router ID is used to uniquely identify the first Master in the first OSPF process;

所述第一Master运行所述第一OSPF进程。The first Master runs the first OSPF process.

结合本发明实施例的第一方面,本发明实施例的第一方面的第一种实现方式中,所述第一Router ID包括用于唯一标识所述第一OSPF进程的字段,和用于唯一标识所述第一Master的字段。With reference to the first aspect of the embodiments of the present invention, in the first implementation manner of the first aspect of the embodiments of the present invention, the first Router ID includes a field for uniquely identifying the first OSPF process, and a field for uniquely identifying the first OSPF process A field identifying the first Master.

结合本发明实施例的第一方面的第一种实现方式,本发明实施例的第一方面的第二种实现方式中,所述用于唯一标识所述第一Master的字段为所述第一Master的网络设备标识NEID。With reference to the first implementation of the first aspect of the embodiments of the present invention, in the second implementation of the first aspect of the embodiments of the present invention, the field used to uniquely identify the first Master is the first The network device identifier NEID of the master.

结合本发明实施例的第一方面、第一方面的第一种或第二种实现方式,本发明实施例的第一方面的第三种实现方式还包括:In combination with the first aspect of the embodiments of the present invention, the first or second implementation of the first aspect, the third implementation of the first aspect of the embodiments of the present invention further includes:

当所述第一Master的第二接口上使能虚拟集群功能之后,所述第一Master创建第二OSPF进程,并将所述第二接口加入到所述第二OSPF进程中,所述第二接口是与所述AP相连的接口;After the virtual cluster function is enabled on the second interface of the first Master, the first Master creates a second OSPF process, and adds the second interface to the second OSPF process, and the second The interface is an interface connected to the AP;

所述第一Master在所述第二OSPF进程中分配第二Router ID,所述第二Router ID用于唯一标识在所述第二OSPF进程中的所述第一Master;The first Master allocates a second Router ID in the second OSPF process, and the second Router ID is used to uniquely identify the first Master in the second OSPF process;

所述第一Master运行所述第二OSPF进程。The first Master runs the second OSPF process.

结合本发明实施例的第一方面的第三种实现方式,本发明实施例的第一方面的第四种实现方式中,所述第二Router ID包括用于唯一标识所述第二OSPF进程的字段,和用于唯一标识所述第一Master的字段。With reference to the third implementation manner of the first aspect of the embodiments of the present invention, in the fourth implementation manner of the first aspect of the embodiments of the present invention, the second Router ID includes an ID for uniquely identifying the second OSPF process field, and a field for uniquely identifying the first Master.

结合本发明实施例的第一方面的第四种实现方式,本发明实施例的第一方面的第五种实现方式中,所述用于唯一标识所述第一Master的字段为所述第一Master的网络设备标识NEID。With reference to the fourth implementation manner of the first aspect of the embodiments of the present invention, in the fifth implementation manner of the first aspect of the embodiments of the present invention, the field used to uniquely identify the first Master is the first The network device identifier NEID of the master.

结合本发明实施例的第一方面的第三种、第四种或第五种实现方式,本发明实施例的第一方面的第六种实现方式还包括:In combination with the third, fourth or fifth implementation of the first aspect of the embodiments of the present invention, the sixth implementation of the first aspect of the embodiments of the present invention further includes:

所述第一Master确定所述第一OSPF进程和所述第二OSPF进程收集了重复的拓扑;The first Master determines that the first OSPF process and the second OSPF process have collected duplicate topologies;

所述第一Master将所述重复的拓扑合并为一个拓扑。The first Master merges the repeated topologies into one topology.

结合本发明实施例的第一方面的第六种实现方式,本发明实施例的第一方面的第七种实现方式中,所述第一Master确定所述第一OSPF进程和所述第二OSPF进程收集了重复的拓扑包括:With reference to the sixth implementation manner of the first aspect of the embodiments of the present invention, in the seventh implementation manner of the first aspect of the embodiments of the present invention, the first Master determines the first OSPF process and the second OSPF process Processes that have collected duplicate topologies include:

所述第一Master从所述第一OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID;The first Master acquires the Router ID of the first Master from the first OSPF process as the first Router ID and the second Router ID;

所述第一Master从所述第二OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID;The first Master acquires the Router ID of the first Master from the second OSPF process as the first Router ID and the second Router ID;

所述第一Master确定从所述第一OSPF进程中获取到的所述第一Router ID和所述第二Router ID与从所述第二OSPF进程中获取到的所述第一Router ID和所述第二RouterID相同,则所述第一Master确定所述第一OSPF进程和所述第二OSPF进程收集了重复的拓扑。The first Master determines the first Router ID and the second Router ID obtained from the first OSPF process and the first Router ID and the second Router ID obtained from the second OSPF process If the second RouterID is the same, the first Master determines that the first OSPF process and the second OSPF process have collected duplicate topologies.

结合本发明实施例的第一方面的第七种实现方式,本发明实施例的第一方面的第八种实现方式中,所述第一Master从所述第一OSPF进程中获取到所述第一Master的RouterID为所述第一Router ID和所述第二Router ID包括:With reference to the seventh implementation manner of the first aspect of the embodiments of the present invention, in the eighth implementation manner of the first aspect of the embodiments of the present invention, the first Master obtains the first OSPF process from the first OSPF process The RouterID of a Master includes for the first Router ID and the second Router ID:

所述第一Master从所述第一OSPF进程中获取至少一条路由器信息链路状态宣告RI LSA,所述RI LSA中携带有发送所述RI LSA的节点的身份类型,所述身份类型包括Master或AP;The first Master obtains at least one router information link state announcement RI LSA from the first OSPF process, and the RI LSA carries the identity type of the node sending the RI LSA, and the identity type includes Master or AP;

所述第一Master根据获取到的RI LSA确定身份类型为Master的节点,并从所述第一OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID为所述第一Router ID和所述第二Router ID;The first Master determines the node whose identity type is Master according to the obtained RI LSA, and obtains the Router ID of the node whose identity type is Master from the first OSPF process, and obtains that the Router ID of the first Master is the first a Router ID and the second Router ID;

和/或,and / or,

所述第一Master从所述第二OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID包括:The Router ID that the first Master obtains the first Master from the second OSPF process is that the first Router ID and the second Router ID include:

所述第一Master从所述第二OSPF进程中获取至少一条RI LSA,所述RI LSA中携带有发送所述RI LSA的节点的身份类型,所述身份类型包括Master或AP;The first Master obtains at least one RI LSA from the second OSPF process, the RI LSA carries the identity type of the node sending the RI LSA, and the identity type includes Master or AP;

所述第一Master根据获取到的RI LSA确定身份类型为Master的节点,并从所述第二OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID为所述第一Router ID和所述第二Router ID。The first Master determines the node whose identity type is Master according to the obtained RI LSA, and obtains the Router ID of the node whose identity type is Master from the second OSPF process, and obtains that the Router ID of the first Master is the first A Router ID and the second Router ID.

结合本发明实施例的第一方面的第六种、第七种或第八种实现方式,本发明实施例的第一方面的第九种实现方式中,所述将所述重复的拓扑合并为一个拓扑包括:In combination with the sixth, seventh or eighth implementation of the first aspect of the embodiments of the present invention, in the ninth implementation of the first aspect of the embodiments of the present invention, the merging of the repeated topologies into A topology consists of:

所述第一Master将所述第二接口加入到所述第一OSPF进程中;The first Master adds the second interface to the first OSPF process;

所述第一Master删除所述第二OSPF进程。The first Master deletes the second OSPF process.

结合本发明实施例的第一方面、第一方面的第一种至第九种实现方式中的任一项,本发明实施例的第一方面的第十种实现方式还包括:In combination with the first aspect of the embodiments of the present invention, any one of the first to ninth implementation manners of the first aspect, the tenth implementation manner of the first aspect of the embodiments of the present invention further includes:

当所述第一Master的第三接口上使能虚拟集群功能之后,所述第一Master创建第三OSPF进程,并将所述第三接口加入到所述第三OSPF进程中,所述第三接口是与第二Master相连的接口;After the virtual cluster function is enabled on the third interface of the first Master, the first Master creates a third OSPF process, and adds the third interface to the third OSPF process, and the third The interface is an interface connected to the second Master;

所述第一Master在所述第三OSPF进程中分配第三Router ID,所述第三Router ID用于唯一标识在所述第三OSPF进程中的所述第一Master;The first Master allocates a third Router ID in the third OSPF process, and the third Router ID is used to uniquely identify the first Master in the third OSPF process;

所述第一Master运行所述第三OSPF进程。The first Master runs the third OSPF process.

结合本发明实施例的第一方面的第十种实现方式,本发明实施例的第一方面的第十一种实现方式中,所述第三Router ID为所述第一Master的管理IP地址。With reference to the tenth implementation manner of the first aspect of the embodiments of the present invention, in the eleventh implementation manner of the first aspect of the embodiments of the present invention, the third Router ID is the management IP address of the first Master.

结合本发明实施例的第一方面的第十种或第十一种实现方式,本发明实施例的第一方面的第十二种实现方式还包括:In combination with the tenth or eleventh implementation manner of the first aspect of the embodiments of the present invention, the twelfth implementation manner of the first aspect of the embodiments of the present invention further includes:

所述第一Master将所述第三OSPF进程收集到的所述第一Master与所述第二Master的邻接关系描述加入到所述第一OSPF进程的路由链路状态通告Router LSA中,所述邻接关系描述用于表示所述第一Master与所述第二Master互为OSPF邻接。The first Master adds the adjacency description between the first Master and the second Master collected by the third OSPF process into the Router LSA of the first OSPF process, and the The adjacency description is used to indicate that the first Master and the second Master are OSPF adjacent to each other.

本发明实施例的第二方面提供了一种OSPF配置装置,适用于虚拟集群系统中的第一核心汇聚节点Master,所述虚拟集群系统还包括接入节点AP,所述OSPF配置装置包括:The second aspect of the embodiment of the present invention provides an OSPF configuration device, which is suitable for the first core aggregation node Master in a virtual cluster system, the virtual cluster system also includes an access node AP, and the OSPF configuration device includes:

进程创建模块,用于当第一Master的第一接口上使能虚拟集群功能之后,创建第一OSPF进程,并将所述第一接口加入到所述第一OSPF进程中,所述第一接口是与所述AP相连的接口;A process creation module, configured to create a first OSPF process after the virtual cluster function is enabled on the first interface of the first Master, and add the first interface to the first OSPF process, the first interface is an interface connected to the AP;

标识分配模块,用于在所述第一OSPF进程中分配第一路由器标识Router ID,所述第一Router ID用于唯一标识在所述第一OSPF进程中的所述第一Master;An identification allocation module, configured to allocate a first router identification Router ID in the first OSPF process, and the first Router ID is used to uniquely identify the first Master in the first OSPF process;

进程运行模块,用于运行所述第一OSPF进程。A process running module, configured to run the first OSPF process.

结合本发明实施例的第二方面,本发明实施例的第二方面的第一种实现方式中,所述第一Router ID包括用于唯一标识所述第一OSPF进程的字段,和用于唯一标识所述第一Master的字段。With reference to the second aspect of the embodiments of the present invention, in the first implementation manner of the second aspect of the embodiments of the present invention, the first Router ID includes a field for uniquely identifying the first OSPF process, and a field for uniquely identifying the first OSPF process A field identifying the first Master.

结合本发明实施例的第二方面的第一种实现方式,本发明实施例的第二方面的第二种实现方式中,所述用于唯一标识所述第一Master的字段为所述第一Master的网络设备标识NEID。With reference to the first implementation of the second aspect of the embodiments of the present invention, in the second implementation of the second aspect of the embodiments of the present invention, the field used to uniquely identify the first Master is the first The network device identifier NEID of the master.

结合本发明实施例的第二方面、第二方面的第一种或第二种实现方式,本发明实施例的第二方面的第三种实现方式中,所述进程创建模块还用于:In combination with the second aspect of the embodiment of the present invention, the first or second implementation of the second aspect, in the third implementation of the second aspect of the embodiment of the present invention, the process creation module is further used for:

当所述第一Master的第二接口上使能虚拟集群功能之后,创建第二OSPF进程,并将所述第二接口加入到所述第二OSPF进程中,所述第二接口是与所述AP相连的接口;After the virtual cluster function is enabled on the second interface of the first Master, a second OSPF process is created, and the second interface is added to the second OSPF process, and the second interface is connected to the The interface connected to the AP;

所述标识分配模块还用于:在所述第二OSPF进程中分配第二Router ID,所述第二Router ID用于唯一标识在所述第二OSPF进程中的所述第一Master;The identification allocation module is further configured to: allocate a second Router ID in the second OSPF process, and the second Router ID is used to uniquely identify the first Master in the second OSPF process;

所述进程运行模块还用于:运行所述第二OSPF进程。The process running module is also used for: running the second OSPF process.

结合本发明实施例的第二方面的第三种实现方式,本发明实施例的第二方面的第四种实现方式中,所述第二Router ID包括用于唯一标识所述第二OSPF进程的字段,和用于唯一标识所述第一Master的字段。With reference to the third implementation manner of the second aspect of the embodiment of the present invention, in the fourth implementation manner of the second aspect of the embodiment of the present invention, the second Router ID includes an ID for uniquely identifying the second OSPF process field, and a field for uniquely identifying the first Master.

结合本发明实施例的第二方面的第四种实现方式,本发明实施例的第二方面的第五种实现方式中,所述用于唯一标识所述第一Master的字段为所述第一Master的网络设备标识NEID。With reference to the fourth implementation of the second aspect of the embodiments of the present invention, in the fifth implementation of the second aspect of the embodiments of the present invention, the field used to uniquely identify the first Master is the first The network device identifier NEID of the master.

结合本发明实施例的第二方面的第三种、第四种或第五种实现方式,本发明实施例的第二方面的第六种实现方式中,所述装置还包括:In combination with the third, fourth, or fifth implementation of the second aspect of the embodiments of the present invention, in the sixth implementation of the second aspect of the embodiments of the present invention, the device further includes:

重复拓扑确定模块,用于确定所述第一OSPF进程和所述第二OSPF进程收集了重复的拓扑;A duplicate topology determination module, configured to determine that the first OSPF process and the second OSPF process have collected duplicate topologies;

重复拓扑合并模块,用于将所述重复的拓扑合并为一个拓扑。The repeated topology merging module is used for merging the repeated topologies into one topology.

结合本发明实施例的第二方面的第六种实现方式,本发明实施例的第二方面的第七种实现方式中,所述重复拓扑确定模块具体用于:With reference to the sixth implementation manner of the second aspect of the embodiments of the present invention, in the seventh implementation manner of the second aspect of the embodiments of the present invention, the repeat topology determination module is specifically used for:

从所述第一OSPF进程中获取到所述第一Master的Router ID为所述第一RouterID和所述第二Router ID;Obtaining the Router ID of the first Master from the first OSPF process is the first RouterID and the second Router ID;

从所述第二OSPF进程中获取到所述第一Master的Router ID为所述第一RouterID和所述第二Router ID;Obtaining the Router ID of the first Master from the second OSPF process is the first RouterID and the second Router ID;

确定从所述第一OSPF进程中获取到的所述第一Router ID和所述第二Router ID与从所述第二OSPF进程中获取到的所述第一Router ID和所述第二Router ID相同,则确定所述第一OSPF进程和所述第二OSPF进程收集了重复的拓扑。Determining the first Router ID and the second Router ID obtained from the first OSPF process and the first Router ID and the second Router ID obtained from the second OSPF process If they are the same, it is determined that the first OSPF process and the second OSPF process have collected duplicate topologies.

结合本发明实施例的第二方面的第七种实现方式,本发明实施例的第二方面的第八种实现方式中,所述重复拓扑确定模块通过如下方法从所述第一OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID:With reference to the seventh implementation manner of the second aspect of the embodiments of the present invention, in the eighth implementation manner of the second aspect of the embodiments of the present invention, the repeat topology determination module obtains from the first OSPF process by the following method The Router ID to the first Master is the first Router ID and the second Router ID:

从所述第一OSPF进程中获取至少一条路由器信息链路状态宣告RI LSA,所述RILSA中携带有发送所述RI LSA的节点的身份类型,所述身份类型包括Master或AP;Acquire at least one router information link state announcement RI LSA from the first OSPF process, the RILSA carries the identity type of the node sending the RI LSA, and the identity type includes Master or AP;

根据获取到的RI LSA确定身份类型为Master的节点,并从所述第一OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID为所述第一RouterID和所述第二Router ID;Determine the node whose identity type is Master according to the obtained RI LSA, and obtain the Router ID of the node whose identity type is Master from the first OSPF process, and obtain the Router ID of the first Master as the first RouterID and the Second Router ID;

和/或,and / or,

所述重复拓扑确定模块通过如下方法从所述第二OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID:The repeat topology determination module acquires the Router ID of the first Master from the second OSPF process as the first Router ID and the second Router ID through the following method:

从所述第二OSPF进程中获取至少一条RI LSA,所述RI LSA中携带有发送所述RILSA的节点的身份类型,所述身份类型包括Master或AP;Acquire at least one RI LSA from the second OSPF process, where the RI LSA carries the identity type of the node sending the RILSA, where the identity type includes Master or AP;

根据获取到的RI LSA确定身份类型为Master的节点,并从所述第二OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID为所述第一RouterID和所述第二Router ID。Determine the node whose identity type is Master according to the obtained RI LSA, and obtain the Router ID of the node whose identity type is Master from the second OSPF process, and obtain the Router ID of the first Master as the first RouterID and the Second Router ID.

结合本发明实施例的第二方面的第六种、第七种或第八种实现方式,本发明实施例的第二方面的第九种实现方式中,所述重复拓扑合并模块具体用于:In combination with the sixth, seventh, or eighth implementation of the second aspect of the embodiments of the present invention, in the ninth implementation of the second aspect of the embodiments of the present invention, the repeated topology merging module is specifically used for:

将所述第二接口加入到所述第一OSPF进程中;adding the second interface to the first OSPF process;

删除所述第二OSPF进程。Delete the second OSPF process.

结合本发明实施例的第二方面、第二方面的第一种至第九种实现方式中的任一项,本发明实施例的第二方面的第十种实现方式中,所述进程创建模块还用于:In combination with the second aspect of the embodiments of the present invention, any one of the first to ninth implementations of the second aspect, in the tenth implementation of the second aspect of the embodiments of the present invention, the process creation module Also used for:

当所述第一Master的第三接口上使能虚拟集群功能之后,创建第三OSPF进程,并将所述第三接口加入到所述第三OSPF进程中,所述第三接口是与所述第二Master相连的接口;After the virtual cluster function is enabled on the third interface of the first Master, a third OSPF process is created, and the third interface is added to the third OSPF process, and the third interface is connected to the The interface connected to the second Master;

所述标识分配模块还用于:在所述第三OSPF进程中分配第三Router ID,所述第三Router ID用于唯一标识在所述第三OSPF进程中的所述第一Master;The identification allocation module is further configured to: allocate a third Router ID in the third OSPF process, and the third Router ID is used to uniquely identify the first Master in the third OSPF process;

所述进程运行模块还用于:运行所述第三OSPF进程。The process running module is also used for: running the third OSPF process.

结合本发明实施例的第二方面的第十种实现方式,本发明实施例的第二方面的第十一种实现方式中,所述第三Router ID为所述第一Master的管理IP地址。With reference to the tenth implementation manner of the second aspect of the embodiments of the present invention, in the eleventh implementation manner of the second aspect of the embodiments of the present invention, the third Router ID is the management IP address of the first Master.

结合本发明实施例的第二方面的第十种或第十一种实现方式,本发明实施例的第二方面的第十二种实现方式中,所述装置还包括:In combination with the tenth or eleventh implementation of the second aspect of the embodiments of the present invention, in the twelfth implementation of the second aspect of the embodiments of the present invention, the device further includes:

邻接描述加入模块,用于将所述第三OSPF进程收集到的所述第一Master与所述第二Master的邻接关系描述加入到所述第一OSPF进程的路由链路状态通告Router LSA中,所述邻接关系描述用于表示所述第一Master与所述第二Master互为OSPF邻接。an adjacency description adding module, configured to add the adjacency description of the first Master and the second Master collected by the third OSPF process into the Router LSA of the first OSPF process, The adjacency description is used to indicate that the first Master and the second Master are OSPF adjoining to each other.

本发明实施例提供的OSPF配置方法中,在第一接口上使能虚拟集群功能之后,第一Master自动创建第一OSPF进程,将第一接口加入到第一OSPF进程中,并在第一OSPF进程中自动分配第一Router ID,最后运行该第一OSPF进程。通过这种方法,使得第一Master能够自动分配Router ID,无需人工根据网络拓扑结果来规划Router ID,简化了用户的操作,减少了用户的工作量,有利于虚拟集群系统的配置安装。In the OSPF configuration method provided by the embodiment of the present invention, after the virtual cluster function is enabled on the first interface, the first Master automatically creates the first OSPF process, adds the first interface to the first OSPF process, and The first Router ID is automatically assigned in the process, and finally the first OSPF process is run. Through this method, the first Master can automatically assign the Router ID without manually planning the Router ID according to the network topology results, which simplifies the user's operation, reduces the user's workload, and is conducive to the configuration and installation of the virtual cluster system.

附图说明Description of drawings

图1为虚拟集群系统一个结构图;Fig. 1 is a structural diagram of a virtual cluster system;

图2为本发明实施例中OSPF配置方法一个实施例流程图;Fig. 2 is a flowchart of an embodiment of the OSPF configuration method in the embodiment of the present invention;

图3为本发明实施例中OSPF配置方法另一个实施例流程图;FIG. 3 is a flow chart of another embodiment of the OSPF configuration method in the embodiment of the present invention;

图4为本发明实施例中OSPF配置方法另一个实施例流程图;FIG. 4 is a flow chart of another embodiment of the OSPF configuration method in the embodiment of the present invention;

图5为本发明实施例中OSPF配置装置一个实施例结构图;FIG. 5 is a structural diagram of an embodiment of an OSPF configuration device in an embodiment of the present invention;

图6为本发明实施例中OSPF配置装置另一个实施例结构图;FIG. 6 is a structural diagram of another embodiment of the OSPF configuration device in the embodiment of the present invention;

图7为本发明实施例中OSPF配置装置另一个实施例结构图;FIG. 7 is a structural diagram of another embodiment of the OSPF configuration device in the embodiment of the present invention;

图8为本发明实施例中OSPF配置装置另一个实施例结构图。FIG. 8 is a structural diagram of another embodiment of the OSPF configuration device in the embodiment of the present invention.

具体实施方式Detailed ways

本发明实施例提供了一种OSPF配置方法,用于简化人工OSPF操作。本发明实施例还提供了相关的Master,以下将本别进行说明。An embodiment of the present invention provides an OSPF configuration method for simplifying manual OSPF operations. The embodiment of the present invention also provides a related Master, which will be described separately below.

虚拟集群系统一般由AP和Master组成,AP与Master彼此相连构成了网络拓扑。现阶段的技术通过在虚拟集群系统中运行OSPF来收集系统的内部网络拓扑,以图1所示的虚拟集群系统的一个基本结构为例:图1中,第一Master上第一接口与第二接口与AP相连,第三接口与第二Master相连。Master在每个接口上都运行OSPF进程,这就要求用户人工每个接口上运行的OSPF进程的Process ID,并配置Master在每个OSPF进程中的Router ID,以顺利运行这些OSPF进程。人工配置这些参数需要用户预先感知网络拓扑的结构,并根据网络拓扑的结构进行参数的人工规划,因此需要耗费较多的人力。A virtual cluster system generally consists of an AP and a Master, and the AP and the Master are connected to each other to form a network topology. The current technology collects the internal network topology of the system by running OSPF in the virtual cluster system. Take a basic structure of the virtual cluster system shown in Figure 1 as an example: in Figure 1, the first interface on the first Master and the second The interface is connected to the AP, and the third interface is connected to the second Master. The master runs an OSPF process on each interface, which requires the user to manually set the Process ID of the OSPF process running on each interface, and configure the router ID of the master in each OSPF process so that these OSPF processes can run smoothly. Manual configuration of these parameters requires the user to perceive the structure of the network topology in advance and manually plan the parameters according to the structure of the network topology, which requires a lot of manpower.

本发明实施例提供了一种OSPF配置方法,可以减少Master的Router ID的人工配置操作,其基本流程请参阅图2,包括:The embodiment of the present invention provides an OSPF configuration method, which can reduce the manual configuration operation of the Router ID of the Master. Please refer to FIG. 2 for its basic flow, including:

201、第一Master创建第一OSPF进程,并将第一接口加入到第一OSPF进程中;201. The first Master creates a first OSPF process, and adds the first interface to the first OSPF process;

用户在第一Master的第一接口上人工使能虚拟集群功能,当该第一接口上使能虚拟集群功能之后,第一Master自动创建第一OSPF进程,并将第一接口加入到第一OSPF进程中。其中,第一接口是与AP相连的接口。The user manually enables the virtual cluster function on the first interface of the first master. After the virtual cluster function is enabled on the first interface, the first master automatically creates the first OSPF process and adds the first interface to the first OSPF in progress. Wherein, the first interface is an interface connected to the AP.

202、第一Master在第一OSPF进程中分配第一Router ID;202. The first Master allocates the first Router ID in the first OSPF process;

第一Master将第一接口加入到第一OSPF进程中后,在第一OSPF进程中分配第一Router ID。其中,Router ID用以识别每台运行OSPF协议的路由器,例如可以是一个32位的数字。在一个自治域中,这个数字可以唯一地表示出一台路由器。在虚拟集群系统中,Router ID用于唯一标识每个OSPF进程中的Master节点,第一Router ID用于唯一标识在第一OSPF进程中的第一Master。After adding the first interface to the first OSPF process, the first Master allocates the first Router ID in the first OSPF process. Wherein, the Router ID is used to identify each router running the OSPF protocol, for example, it may be a 32-bit number. In an autonomous domain, this number can uniquely represent a router. In the virtual cluster system, the Router ID is used to uniquely identify the Master node in each OSPF process, and the first Router ID is used to uniquely identify the first Master node in the first OSPF process.

其中,第一Master在第一OSPF进程中分配第一Router ID的方法有很多,将在后面的实施例中详述,本实施例中不做限定。Wherein, there are many methods for the first Master to allocate the first Router ID in the first OSPF process, which will be described in detail in the following embodiments, and are not limited in this embodiment.

203、第一Master运行第一OSPF进程。203. The first Master runs the first OSPF process.

第一Master在第一OSPF进程中分配第一Router ID之后,就可以运行该第一OSPF进程,与AP建立OSPF邻接关系。After the first Master allocates the first Router ID in the first OSPF process, it can run the first OSPF process and establish an OSPF adjacency relationship with the AP.

本实施例提供的方法中,在第一接口上使能虚拟集群功能之后,第一Master自动创建第一OSPF进程,将第一接口加入到第一OSPF进程中,并在第一OSPF进程中自动分配第一Router ID,最后运行该第一OSPF进程。通过这种方法,使得第一Master能够自动分配Router ID,无需人工根据网络拓扑结果来规划Router ID,简化了用户的操作,减少了用户的工作量,有利于虚拟集群系统的配置安装。In the method provided in this embodiment, after the virtual cluster function is enabled on the first interface, the first Master automatically creates the first OSPF process, adds the first interface to the first OSPF process, and automatically Assign the first Router ID, and finally run the first OSPF process. Through this method, the first Master can automatically assign the Router ID without manually planning the Router ID according to the network topology results, which simplifies the user's operation, reduces the user's workload, and is conducive to the configuration and installation of the virtual cluster system.

其中,第一Master在创建了第一OSPF进程后,还可以为第一OSPF进程分配ProcessID。第一Master分配Process ID的方法有很多,例如:第一Master分配的Process ID可以从65534开始,若65534这个Process ID已被占用,则将Process ID减1得到65533,若该Process ID号依然被占用,则将Process号再减1,直到找到空闲的Process ID为止。第一Master也可以通过其他方法来分配Process ID,该Process ID在所述第一Master上用于唯一的标识一个OSPF进程,本发明实施例中不做限定。Wherein, after the first Master creates the first OSPF process, it may also assign a ProcessID to the first OSPF process. There are many ways for the first Master to assign Process IDs. For example, the Process ID assigned by the first Master can start from 65534. If the Process ID of 65534 is already occupied, the Process ID will be reduced by 1 to get 65533. If the Process ID is still occupied If it is occupied, the Process number will be reduced by 1 until a free Process ID is found. The first Master may also use other methods to allocate a Process ID. The Process ID is used to uniquely identify an OSPF process on the first Master, which is not limited in this embodiment of the present invention.

步骤202中提到,第一Router ID用于唯一标识在第一OSPF进程中的第一Master。优选的,作为本发明的又一个实施例,第一Router ID中可以包括用于唯一标识第一OSPF进程的字段,使得第一Master上的不同OSPF进程中第一Master的Router ID不冲突。唯一标识第一OSPF进程的字段可以为第一OSPF的Process ID,也可以为更短的数值或其他形式,只要第一Master上的不同OSPF进程的中该字段的内容不同即可;第一Router ID中还可以包括用于唯一标识该第一Master的字段。更为优选的,用于唯一标识该第一Master的字段可以为第一Master的网络设备标识(NEID,Network Entity ID)。As mentioned in step 202, the first Router ID is used to uniquely identify the first Master in the first OSPF process. Preferably, as another embodiment of the present invention, the first Router ID may include a field for uniquely identifying the first OSPF process, so that the Router IDs of the first Master in different OSPF processes on the first Master do not conflict. The field that uniquely identifies the first OSPF process can be the Process ID of the first OSPF, and can also be a shorter numerical value or other forms, as long as the contents of this field are different in different OSPF processes on the first Master; the first Router The ID may also include a field for uniquely identifying the first Master. More preferably, the field for uniquely identifying the first Master may be a network device identifier (NEID, Network Entity ID) of the first Master.

从图1中可以看出,第一Master的接口中,接口1和接口2接入到了同一个AP上,这两个接口与AP之间的链路属于重复的拓扑。现阶段的技术中人工根据网络拓扑结构来规划Master的Router ID时,可以人工的将重复的拓扑合并,以避免重复拓扑在OSPF进程运行中造成算路错误。本发明实施例在图2所示的实施例的基础上还提供了一种更进一步的OSPF配置方法,能够使得Master自动合并重复拓扑,其流程请参阅图3:It can be seen from FIG. 1 that among the interfaces of the first Master, interface 1 and interface 2 are connected to the same AP, and the links between these two interfaces and the AP belong to a repeated topology. In the current technology, when the router ID of the master is manually planned according to the network topology, the duplicate topologies can be manually merged to avoid path calculation errors caused by the duplicate topologies during the running of the OSPF process. On the basis of the embodiment shown in Figure 2, the embodiment of the present invention also provides a further OSPF configuration method, which can enable the Master to automatically merge duplicate topologies. Please refer to Figure 3 for the process:

301、第一Master创建第一OSPF进程和第二OSPF进程,并将第一接口加入到第一OSPF进程中,第二接口加入到第二OSPF进程中;301. The first Master creates a first OSPF process and a second OSPF process, and adds the first interface to the first OSPF process, and adds the second interface to the second OSPF process;

用户在第一Master的第一接口和第二接口上人工使能虚拟集群功能,当该第一接口上使能虚拟集群功能之后,第一Master自动创建第一OSPF进程,并将第一接口加入到第一OSPF进程中。当该第二接口上使能虚拟集群功能之后,第一Master自动创建第二OSPF进程,并将第二接口加入到第二OSPF进程中。其中,第一接口与第二接口是与相同的AP相连的接口。The user manually enables the virtual cluster function on the first interface and the second interface of the first master. After the virtual cluster function is enabled on the first interface, the first master automatically creates the first OSPF process and adds the first interface to the to the first OSPF process. After the virtual cluster function is enabled on the second interface, the first Master automatically creates a second OSPF process and adds the second interface to the second OSPF process. Wherein, the first interface and the second interface are interfaces connected to the same AP.

302、第一Master在第一OSPF进程中分配第一Router ID,在第二OSPF进程中分配第二Router ID;302. The first Master allocates the first Router ID in the first OSPF process, and allocates the second Router ID in the second OSPF process;

第一Master将第一接口加入到第一OSPF进程中后,在第一OSPF进程中分配第一Router ID;并在将第二接口加入到第二OSPF进程中后,在第二OSPF进程中分配第二RouterID。其中,第一Router ID用于唯一标识在第一OSPF进程中的第一Master,第二Router ID用于唯一标识在第二OSPF进程中的第一Master。After the first Master adds the first interface to the first OSPF process, it allocates the first Router ID in the first OSPF process; and after adding the second interface to the second OSPF process, it allocates it in the second OSPF process Second RouterID. Wherein, the first Router ID is used to uniquely identify the first Master in the first OSPF process, and the second Router ID is used to uniquely identify the first Master in the second OSPF process.

与第一Router ID的分配方法类似的,第二Router ID中可以包括用于唯一标识第二OSPF进程的字段,使得第一Master上的不同OSPF进程中第一Master的Router ID不冲突。唯一标识第二OSPF进程的字段可以为第二OSPF进程的Process ID,也可以为更短的数值或其他形式,只要第一Master上的不同OSPF进程中该字段的内容不同即可;第二Router ID中还可以包括用于唯一标识该第一Master的字段,用于唯一标识该第一Master的字段可以为第一Master的NEID。Similar to the allocation method of the first Router ID, the second Router ID may include a field for uniquely identifying the second OSPF process, so that the Router IDs of the first Master in different OSPF processes on the first Master do not conflict. The field uniquely identifying the second OSPF process can be the Process ID of the second OSPF process, or a shorter numerical value or other forms, as long as the contents of this field are different in different OSPF processes on the first Master; the second Router The ID may further include a field for uniquely identifying the first Master, and the field for uniquely identifying the first Master may be the NEID of the first Master.

303、第一Master运行第一OSPF进程和第二OSPF进程;303. The first Master runs the first OSPF process and the second OSPF process;

第一Master在第一OSPF进程中分配第一Router ID之后,就可以运行该第一OSPF进程;第一Master在第二OSPF进程中分配第二Router ID之后,就可以运行该第二OSPF进程,与AP建立OSPF邻接关系。After the first Master allocates the first Router ID in the first OSPF process, it can run the first OSPF process; after the first Master allocates the second Router ID in the second OSPF process, it can run the second OSPF process, Establish an OSPF adjacency relationship with the AP.

304、第一Master确定第一OSPF进程和第二OSPF进程收集了重复的拓扑;304. The first Master determines that the first OSPF process and the second OSPF process have collected duplicate topologies;

当第一Master运行第一OSPF进程和第二OSPF进程后,第一OSPF进程和第二OSPF进程会收集虚拟集群系统的网络拓扑。第一Master确定第一OSPF进程和第二OSPF进程收集到了重复的拓扑。After the first Master runs the first OSPF process and the second OSPF process, the first OSPF process and the second OSPF process will collect the network topology of the virtual cluster system. The first Master determines that the first OSPF process and the second OSPF process have collected duplicate topologies.

第一Master确定第一OSPF进程和第二OSPF进程收集到了重复的拓扑的方法有很多,例如,第一Master运行的OSPF进程可以获取第一Master所在拓扑中的身份类型为Master的节点的Router ID,若第一Master的两个OSPF进程获取到的身份类型为Master的节点的Router ID相同,则说明第一Master接入重复的拓扑。如图1所示,由于第一OSPF进程和第二OSPF进程都位于闭环拓扑第一接口—AP—第二接口中,故第一OSPF进程能够获取到用于标识第一Master的Router ID为第一Router ID和第二Router ID,第二OSPF进程能够获取到用于标识第一Master的Router ID为第一Router ID和第二Router ID;第一Master判断从第一OSPF进程中获取到的第一Router ID和第二Router ID与从第二OSPF进程中获取到的第一Router ID和第二Router ID相同,故确定第一Master收集了重复的拓扑。There are many ways for the first master to determine that the first OSPF process and the second OSPF process have collected duplicate topologies. For example, the OSPF process run by the first master can obtain the router ID of the node whose identity type is Master in the topology where the first master resides. , if the two OSPF processes of the first Master obtain the same Router ID of the node whose identity type is Master, it means that the first Master accesses a duplicate topology. As shown in Figure 1, since both the first OSPF process and the second OSPF process are located in the first interface—AP—second interface of the closed-loop topology, the first OSPF process can obtain the Router ID used to identify the first Master as the first One Router ID and the second Router ID, the second OSPF process can obtain the Router ID used to identify the first Master as the first Router ID and the second Router ID; the first Master judges the first Router ID obtained from the first OSPF process A Router ID and a second Router ID are the same as the first Router ID and the second Router ID obtained from the second OSPF process, so it is determined that the first Master has collected duplicate topologies.

其中,第一Master运行的OSPF进程为了获取第一Master所在拓扑中的身份类型为Master的节点的Router ID,需要先确定第一Master所在的拓扑中哪些节点的身份类型是Master,哪些节点的身份类型是AP。各节点的身份类型可以在该节点的路由器信息链路状态宣告(RI LSA,Router Information Link State Advertise)中携带,RI LSA携带身份类型的方法有很多,例如可以为RI LSA设置扩展字段,各个节点的身份类型填写在该节点的RI LSA的扩展字段中。这样在获取该节点的RI LSA后,就可以根据该RI LSA的扩展字段确定该节点的身份类型。第一Master从第一OSPF进程中获取至少一条RI LSA,并根据获取到的RI LSA确定身份类型为Master的节点,然后从第一OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID为第一Router ID和第二Router ID。同理的,第一Master从第二OSPF进程中获取至少一条RI LSA,并根据获取到的RI LSA确定身份类型为Master的节点,然后从第二OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID也为第一Router ID和为第二Router ID。Among them, in order to obtain the Router ID of the node whose identity type is Master in the topology where the first Master is located, the OSPF process run by the first Master needs to first determine which nodes in the topology where the first Master is located have the identity type of Master and which nodes have the identity The type is AP. The identity type of each node can be carried in the Router Information Link State Advertise (RI LSA, Router Information Link State Advertise) of the node. There are many ways for the RI LSA to carry the identity type. For example, an extension field can be set for the RI LSA, and each node The identity type of the node is filled in the extension field of the node's RI LSA. In this way, after the RI LSA of the node is obtained, the identity type of the node can be determined according to the extension field of the RI LSA. The first Master obtains at least one RI LSA from the first OSPF process, and determines the node whose identity type is Master according to the obtained RI LSA, and then obtains the Router ID of the node whose identity type is Master from the first OSPF process, and obtains the first The router IDs of a Master are the first router ID and the second router ID. Similarly, the first Master obtains at least one RI LSA from the second OSPF process, and determines the node whose identity type is Master according to the obtained RI LSA, and then obtains the Router of the node whose identity type is Master from the second OSPF process. ID, the Router ID of the first Master is also the first Router ID and the second Router ID.

第一Master确定第一OSPF进程和第二OSPF进程收集到了重复的拓扑也可以为其他方法,此处不做限定。Other methods may also be used for the first Master to determine that the first OSPF process and the second OSPF process have collected duplicate topologies, which are not limited here.

305、第一Master将重复的拓扑合并为一个拓扑。305. The first Master merges the repeated topologies into one topology.

第一Master确定第一OSPF进程和第二OSPF进程收集到了重复的拓扑,如第一Master需要将重复的拓扑和并为一个拓扑,以避免OSPF产生算路错误。具体的,第一Master可以将第二接口加入到第一OSPF进程中,然后删除第二OSPF进程,即可实现重复拓扑的合并。The first Master determines that the first OSPF process and the second OSPF process have collected duplicate topologies. For example, the first Master needs to merge the duplicate topologies into one topology, so as to avoid OSPF path calculation errors. Specifically, the first Master may add the second interface to the first OSPF process, and then delete the second OSPF process, so as to realize the merging of duplicate topologies.

本实施例在图2所示的实施例提供的方法的基础上提供了另一种OSPF配制方法,能够使得第一Master自动识别并合并重复的拓扑,进而避免算路错误,提高了OSPF配置的成功率。This embodiment provides another OSPF configuration method based on the method provided in the embodiment shown in Figure 2, which enables the first Master to automatically identify and merge duplicate topologies, thereby avoiding path calculation errors and improving OSPF configuration accuracy. Success rate.

上述实施例中的OSPF配置方法主要针对第一Master与AP相连的接口而言。但在一般的虚拟集群系统中,Master之间也需要相连。本发明实施例在图2所示的实施例的基础上提供了另一种OSPF配置方法,能够实现Master间的OSPF配置。其流程请参阅图4,包括:The OSPF configuration method in the foregoing embodiments is mainly for the interface connecting the first Master to the AP. But in a general virtual cluster system, the Master also needs to be connected. The embodiment of the present invention provides another OSPF configuration method on the basis of the embodiment shown in FIG. 2 , which can implement OSPF configuration between Masters. Please refer to Figure 4 for its process, including:

401、第一Master创建第一OSPF进程和第三OSPF进程,并将第一接口加入到第一OSPF进程中,第三接口加入到第三OSPF进程中;401. The first Master creates a first OSPF process and a third OSPF process, and adds the first interface to the first OSPF process, and adds the third interface to the third OSPF process;

用户在第一Master的第一接口和第三接口上人工使能虚拟集群功能,当该第一接口上使能虚拟集群功能之后,第一Master自动创建第一OSPF进程,并将第一接口加入到第一OSPF进程中。当该第三接口上使能虚拟集群功能之后,第一Master自动创建第三OSPF进程,并将第三接口加入到第三OSPF进程中。其中,第一接口是与AP相连的接口,第三接口是与第二Master相连的接口。The user manually enables the virtual cluster function on the first interface and the third interface of the first master. After the virtual cluster function is enabled on the first interface, the first master automatically creates the first OSPF process and adds the first interface to the to the first OSPF process. After the virtual cluster function is enabled on the third interface, the first Master automatically creates a third OSPF process, and adds the third interface to the third OSPF process. Wherein, the first interface is an interface connected to the AP, and the third interface is an interface connected to the second Master.

402、第一Master在第一OSPF进程中分配第一Router ID,在第三OSPF进程中分配第三Router ID;402. The first Master allocates the first Router ID in the first OSPF process, and allocates the third Router ID in the third OSPF process;

第一Master将第一接口加入到第一OSPF进程中后,在第一OSPF进程中分配第一Router ID;并在将第三接口加入到第三OSPF进程中后,在第三OSPF进程中分配第第三Router ID。其中,第一Router ID用于唯一标识在第一OSPF进程中的第一Master,第三Router ID用于唯一标识在第三OSPF进程中的第一Master。其中,第三Router ID的形式可以为第一Master的管理IP地址,管理IP地址用于在虚拟集群系统中唯一标识和管理一台设备。第三Router ID也可以为其他形式,本实施例中不做限定。After the first Master adds the first interface to the first OSPF process, it allocates the first Router ID in the first OSPF process; and after adding the third interface to the third OSPF process, it allocates it in the third OSPF process Third Router ID. Wherein, the first Router ID is used to uniquely identify the first Master in the first OSPF process, and the third Router ID is used to uniquely identify the first Master in the third OSPF process. Wherein, the form of the third Router ID may be the management IP address of the first Master, and the management IP address is used to uniquely identify and manage a device in the virtual cluster system. The third Router ID may also be in other forms, which are not limited in this embodiment.

403、第一Master运行第一OSPF进程和第三OSPF进程;403. The first Master runs the first OSPF process and the third OSPF process;

第一Master在第一OSPF进程中分配第一Router ID之后,就可以运行该第一OSPF进程,与AP建立OSPF邻接关系;第一Master在第三OSPF进程中分配第三Router ID之后,就可以运行该第三OSPF进程,与第二Master建立邻接关系。After the first Master allocates the first Router ID in the first OSPF process, it can run the first OSPF process and establish an OSPF adjacency relationship with the AP; after the first Master allocates the third Router ID in the third OSPF process, it can Run the third OSPF process and establish an adjacency relationship with the second Master.

404、第一Master将第三OSPF进程收集到的第一Master与第二Master的邻接关系描述加入到第一OSPF进程的Router LSA中。404. The first Master adds the adjacency description between the first Master and the second Master collected by the third OSPF process to the Router LSA of the first OSPF process.

第一Master与第二Master建立OSPF邻接后,第一Master可以将第一Master与第二Master的邻接关系描述加入到第一OSPF进程的链路状态通告(Router LSA)中,其中,该邻接关系描述用于表示第一Master与第二Master互为OSPF邻接。After the first Master establishes OSPF adjacency with the second Master, the first Master can add the adjacency description between the first Master and the second Master to the Link State Advertisement (Router LSA) of the first OSPF process, wherein the adjacency The description is used to indicate that the first master and the second master are OSPF adjacent to each other.

在第一Master将第一Master与第二Master的邻接关系描述加入到第一OSPF进程的Router LSA中后,第一Master—AP—第二Master就能够成功形成闭环拓扑。After the first Master adds the description of the adjacency relationship between the first Master and the second Master to the Router LSA of the first OSPF process, the first Master-AP-second Master can successfully form a closed-loop topology.

本发明实施例在图2所示的实施例的基础上提供了一种更进一步的OSPF配置方法,其中,第一Master创建第三OSPF进程,并将与第二Master相连的第三接口加入到第三OSPF进程中;在所述第三OSPF进程中分配第三路由器标识Router ID;运行第三OSPF进程与第二Master建立OSPF邻接;最后将与第二Master的邻接关系描述加入到第一OSPF进程的Router LSA中。通过这样的方法,实现了与Master相连的接口的OSPF的自动配置,无需人工根据网络拓扑结果来规划与Master相连的接口的Router ID,简化了用户的操作,减少了用户的工作量,有利于虚拟集群系统的配置安装。The embodiment of the present invention provides a further OSPF configuration method based on the embodiment shown in FIG. 2 , wherein the first Master creates a third OSPF process, and adds the third interface connected to the second Master In the third OSPF process; in the third OSPF process, assign the third router to identify Router ID; run the third OSPF process and establish OSPF adjacency with the second Master; finally add the adjacency description with the second Master to the first OSPF In the Router LSA of the process. Through this method, the OSPF automatic configuration of the interface connected to the Master is realized, and there is no need to manually plan the Router ID of the interface connected to the Master according to the network topology results, which simplifies the user's operation, reduces the user's workload, and is beneficial Configuration and installation of the virtual cluster system.

优选的,第一Master与第二Master之间的数据报文均可以通过第三接口与第二Master之间的链路来传输,无需为第一Master设置额外的接口与第二Master相连,以达到节约接口个数的目的。其中第三接口可以为人为指定,也可以为第一Master自动设置,本发明实施例中不做限定。Preferably, the data message between the first Master and the second Master can be transmitted through the link between the third interface and the second Master, and there is no need to set an additional interface for the first Master to be connected to the second Master, so that To achieve the purpose of saving the number of interfaces. Wherein, the third interface may be designated manually, or may be automatically set by the first Master, which is not limited in this embodiment of the present invention.

为了便于理解上述实施例,下面将以一个具体的应用场景为例进行描述。In order to facilitate understanding of the foregoing embodiments, a specific application scenario will be used as an example for description below.

请仍参阅图1。图示的虚拟集群系统中,第一Master上第一接口与第二接口与AP相连,第三接口与第二Master相连。用户在第一Master的第一接口、第二接口和第三接口上人工使能虚拟集群功能,第一Master自动创建第一OSPF进程、第二OSPF进程和第三OSPF进程,并将第一接口加入到第一OSPF进程中,将第二接口加入到第二OSPF进程中,将第三接口加入到第三OSPF进程中。Please still refer to Figure 1. In the illustrated virtual cluster system, the first interface and the second interface on the first Master are connected to the AP, and the third interface is connected to the second Master. The user manually enables the virtual cluster function on the first interface, the second interface, and the third interface of the first master, and the first master automatically creates the first OSPF process, the second OSPF process, and the third OSPF process, and assigns the first interface Add to the first OSPF process, add the second interface to the second OSPF process, and add the third interface to the third OSPF process.

第一Master在第一OSPF进程中分配第一Router ID,在第二OSPF进程中分配第二Router ID,在第三OSPF进程中分配第三Router ID。其中,第一Router ID包括一个用于唯一标识第一OSPF进程的高位字节,和写有第一Master的NEID的三个低位字节;第二RouterID包括一个用于唯一标识第二OSPF进程的高位字节,和写有第一Master的NEID的三个低位字节;第二Router ID为第一Master的管理IP地址。The first Master allocates the first Router ID in the first OSPF process, allocates the second Router ID in the second OSPF process, and allocates the third Router ID in the third OSPF process. Wherein, the first Router ID includes a high-order byte for uniquely identifying the first OSPF process, and three low-order bytes written with the NEID of the first Master; the second RouterID includes a high-order byte for uniquely identifying the second OSPF process. The high-order byte, and the three low-order bytes written with the NEID of the first Master; the second Router ID is the management IP address of the first Master.

第一Master运行第一OSPF进程、第二OSPF进程和第三OSPF进程,并通过运行的进程收集虚拟集群系统的拓扑。The first Master runs the first OSPF process, the second OSPF process and the third OSPF process, and collects the topology of the virtual cluster system through the running processes.

在收集拓扑时,第一OSPF进程获取到第一Master的第一Router ID和第二RouterID,第二OSPF进程也获取到第一Master的第一Router ID和第二Router ID。第一Master确定第一OSPF进程和第二OSPF进程获取到的第一Router ID和第二Router ID相同,故确认第一OSPF进程和第二OSPF进程收集到了重复的拓扑,于是第一Master将第二接口加入到第一OSPF进程中,然后删除第二OSPF进程。When collecting the topology, the first OSPF process obtains the first Router ID and the second Router ID of the first Master, and the second OSPF process also obtains the first Router ID and the second Router ID of the first Master. The first Master determines that the first and second Router IDs obtained by the first OSPF process and the second OSPF process are the same, and therefore confirms that the first OSPF process and the second OSPF process have collected duplicate topologies, so the first Master assigns the first The second interface is added to the first OSPF process, and then the second OSPF process is deleted.

第三OSPF进程运行后,第一Master与第二Master之间建立了邻接关系,第三OSPF进程会收集到第一Master与第二Master的邻接关系描述。第一Master将该邻接关系描述加入到第一OSPF进程的Router LSA中,使得第一Master—AP—第二Master形成闭环的拓扑。After the third OSPF process runs, an adjacency relationship is established between the first Master and the second Master, and the third OSPF process will collect descriptions of the adjacency relationship between the first Master and the second Master. The first Master adds the adjacency description to the Router LSA of the first OSPF process, so that the first Master-AP-second Master forms a closed-loop topology.

本发明实施例还提供了相关的OSPF配置装置,适用于虚拟集群系统中的节点。下面将以图1中第一Master上的OSPF配置装置为例进行说明,该OSPF的基本结构请参阅图5,包括:The embodiment of the present invention also provides a related OSPF configuration device, which is suitable for nodes in a virtual cluster system. The following will take the OSPF configuration device on the first Master in Figure 1 as an example for illustration. The basic structure of the OSPF is shown in Figure 5, including:

进程创建模块501,用于在第一Master的第一接口上使能虚拟集群功能之后,自动创建第一OSPF进程,并将第一接口加入到第一OSPF进程中,其中第一接口是与AP相连的接口;A process creation module 501, configured to automatically create a first OSPF process after the virtual cluster function is enabled on the first interface of the first Master, and add the first interface to the first OSPF process, wherein the first interface is connected to the AP connected interface;

标识分配模块502,用于在第一OSPF进程中自动分配第一Router ID,该第一Router ID用于唯一标识在第一OSPF进程中的第一Master;An identifier assignment module 502, configured to automatically assign a first Router ID in the first OSPF process, where the first Router ID is used to uniquely identify the first Master in the first OSPF process;

进程运行模块503,用于运行第一OSPF进程。A process running module 503, configured to run the first OSPF process.

本实施例提供的OSPF配置装置中,在第一接口上使能虚拟集群功能之后,进程创建模块501自动创建第一OSPF进程,将第一接口加入到第一OSPF进程中,标识分配模块502在第一OSPF进程中自动分配第一Router ID,最后进程运行模块503运行该第一OSPF进程。通过这种方法,使得OSPF配置装置能够自动分配Router ID,无需人工根据网络拓扑结果来规划Router ID,简化了用户的操作,减少了用户的工作量,有利于虚拟集群系统的配置安装。In the OSPF configuration device provided in this embodiment, after the virtual cluster function is enabled on the first interface, the process creation module 501 automatically creates the first OSPF process, and adds the first interface to the first OSPF process, and the identification allocation module 502 The first Router ID is automatically assigned to the first OSPF process, and finally the process running module 503 runs the first OSPF process. Through this method, the OSPF configuration device can automatically assign the Router ID without manually planning the Router ID according to the network topology results, which simplifies the user's operation, reduces the user's workload, and is beneficial to the configuration and installation of the virtual cluster system.

优选的,作为本发明的又一个实施例,第一Router ID中可以包括用于唯一标识第一OSPF进程的字段,,使得第一Master上的不同OSPF进程中第一Master的Router ID不冲突。唯一标识第一OSPF进程的字段可以为第一OSPF的Process ID,也可以为更短的数值或其他形式,只要第一Master上的不同OSPF进程中该字段的内容不同即可;第一Router ID中还可以包括用于唯一标识该第一Master的字段。更为优选的,用于唯一标识该第一Master的字段可以为第一Master的网络设备标识(NEID,Network Entity ID)。Preferably, as another embodiment of the present invention, the first Router ID may include a field for uniquely identifying the first OSPF process, so that the Router IDs of the first Master in different OSPF processes on the first Master do not conflict. The field that uniquely identifies the first OSPF process can be the Process ID of the first OSPF, or a shorter numerical value or other forms, as long as the contents of this field are different in different OSPF processes on the first Master; the first Router ID may also include a field for uniquely identifying the first Master. More preferably, the field for uniquely identifying the first Master may be a network device identifier (NEID, Network Entity ID) of the first Master.

作为本发明的又一个实施例,进程创建模块501还用于:在第一Master的第二接口上使能虚拟集群功能之后,创建第二OSPF进程,并将第二接口加入到第二OSPF进程中,其中第二接口是与AP相连的接口;As another embodiment of the present invention, the process creation module 501 is also used for: after enabling the virtual cluster function on the second interface of the first Master, create a second OSPF process, and add the second interface to the second OSPF process , wherein the second interface is an interface connected to the AP;

标识分配模块502还用于:在第二OSPF进程中分配第二Router ID,该第二RouterID用于唯一标识在第二OSPF进程中的第一Master;The identifier distribution module 502 is also used for: assigning a second Router ID in the second OSPF process, and the second RouterID is used to uniquely identify the first Master in the second OSPF process;

优选的,第二Router ID中可以包括用于唯一标识第二OSPF进程的字段,,使得第一Master上的不同OSPF进程中第一Master的Router ID不冲突。唯一标识第二OSPF进程的字段可以为第二OSPF的Process ID,也可以为更短的数值或其他形式,只要第一Master上的不同OSPF进程中该字段的内容不同即可;第二Router ID中还可以包括用于唯一标识该第一Master的字段。更为优选的,用于唯一标识该第一Master的字段可以为第一Master的网络设备标识(NEID,Network Entity ID)。Preferably, the second Router ID may include a field for uniquely identifying the second OSPF process, so that the Router IDs of the first Master in different OSPF processes on the first Master do not conflict. The field that uniquely identifies the second OSPF process can be the Process ID of the second OSPF, and can also be a shorter numerical value or other forms, as long as the contents of this field are different in different OSPF processes on the first Master; the second Router ID may also include a field for uniquely identifying the first Master. More preferably, the field for uniquely identifying the first Master may be a network device identifier (NEID, Network Entity ID) of the first Master.

进程运行模块503还用于:运行第二OSPF进程。The process running module 503 is also used for: running the second OSPF process.

本发明实施例在图5所示的实施例的基础上提供了另一种OSPF配置装置,其结构请参阅图6,包括:The embodiment of the present invention provides another OSPF configuration device on the basis of the embodiment shown in FIG. 5, its structure please refer to FIG. 6, including:

进程创建模块601,用于在第一Master的第一接口上使能虚拟集群功能之后,自动创建第一OSPF进程,并将第一接口加入到第一OSPF进程中,在第一Master的第二接口上使能虚拟集群功能之后,自动创建第二OSPF进程,并将第二接口加入到第二OSPF进程中,其中第一接口与第二接口是与同一个AP相连的接口;The process creation module 601 is configured to automatically create the first OSPF process after the virtual cluster function is enabled on the first interface of the first Master, and add the first interface to the first OSPF process, and the second interface of the first Master After the virtual cluster function is enabled on the interface, a second OSPF process is automatically created, and the second interface is added to the second OSPF process, wherein the first interface and the second interface are interfaces connected to the same AP;

标识分配模块602,用于在第一OSPF进程中分配第一Router ID,在第二OSPF进程中分配第二Router ID,该第一Router ID用于唯一标识在第一OSPF进程中的第一Master,该第二Router ID用于唯一标识在第二OSPF进程中的第一Master;An identifier allocation module 602, configured to allocate a first Router ID in the first OSPF process, and allocate a second Router ID in the second OSPF process, the first Router ID is used to uniquely identify the first Master in the first OSPF process , the second Router ID is used to uniquely identify the first Master in the second OSPF process;

进程运行模块603,用于在标识分配模块602分配了第一Router ID和第二RouterID之后,运行第一OSPF进程和第二OSPF进程;A process running module 603, configured to run the first OSPF process and the second OSPF process after the first Router ID and the second Router ID are allocated by the identification allocation module 602;

重复拓扑确定模块604,用于确定第一OSPF进程和第二OSPF进程收集了重复的拓扑;A duplicate topology determination module 604, configured to determine that the first OSPF process and the second OSPF process have collected duplicate topologies;

其中,重复拓扑确定模块604确定重复拓扑的方法有很多。例如,重复拓扑确定模块可以从第一OSPF进程中获取到第一Master的Router ID为第一Router ID和第二RouterID;从第二OSPF进程中获取到第一Master的Router ID为所述第一Router ID和所述第二Router ID;重复拓扑确定模块604确定从所述第一OSPF进程中获取到的所述第一RouterID和所述第二Router ID与从所述第二OSPF进程中获取到的所述第一Router ID和所述第二Router ID相同,因此确定所述第一OSPF进程和所述第二OSPF进程收集了重复的拓扑。Among them, there are many methods for the repeat topology determining module 604 to determine the repeat topology. For example, the repeat topology determination module may obtain the first Router ID and the second Router ID of the first Master from the first OSPF process; obtain the first Router ID of the first Master from the second OSPF process as the first Router ID and the second Router ID; repeat topology determination module 604 determines that the first RouterID and the second Router ID obtained from the first OSPF process are the same as those obtained from the second OSPF process The first Router ID and the second Router ID are the same, so it is determined that the first OSPF process and the second OSPF process have collected duplicate topologies.

优选的,虚拟集群系统中的RI LSA中可以携带有发送盖RI LSA的节点的身份类型,例如可以为RI LSA设置扩展字段,各个节点的身份类型填写在该节点的RI LSA的扩展字段中。其中身份类型包括Master或AP。第一Master从第一OSPF进程中获取至少一条RILSA,并根据获取到的RI LSA确定身份类型为Master的节点,然后从第一OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID为第一Router ID和第二Router ID。第一Master从第二OSPF进程中获取至少一条RI LSA,并根据获取到的RI LSA确定身份类型为Master的节点,然后从第二OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID也为第一Router ID和为第二Router ID。Preferably, the RI LSA in the virtual cluster system can carry the identity type of the node sending the RI LSA, for example, an extension field can be set for the RI LSA, and the identity type of each node is filled in the extension field of the RI LSA of the node. The identity type includes Master or AP. The first Master obtains at least one RILSA from the first OSPF process, and determines the node whose identity type is Master according to the obtained RI LSA, and then obtains the Router ID of the node whose identity type is Master from the first OSPF process, and obtains the first The router ID of the master is the first router ID and the second router ID. The first Master obtains at least one RI LSA from the second OSPF process, and determines the node whose identity type is Master according to the obtained RI LSA, and then obtains the Router ID of the node whose identity type is Master from the second OSPF process, and obtains the first The router ID of a master is also the first router ID and the second router ID.

重复拓扑合并模块605,用于自动将重复的拓扑合并为一个拓扑。具体的合并方法可以为:将第二接口加入到第一OSPF进程中,然后删除第二OSPF进程。The repeated topology merging module 605 is configured to automatically merge repeated topologies into one topology. A specific merging method may be: adding the second interface to the first OSPF process, and then deleting the second OSPF process.

本发明实施例在图5所示的实施例的基础上提供了另一种OSPF配置装置,不仅能实现OSPF的自动配置,重复拓扑确定模块604还能自动识别第一OSPF进程和第二OSPF进程收集了重复的拓扑,然后重复拓扑合并模块605能够自动将重复的拓扑合并为一个拓扑。通过这样的方法,实现了重复拓扑的自动合并,进而避免算路错误,提高了OSPF配置的成功率。The embodiment of the present invention provides another OSPF configuration device on the basis of the embodiment shown in Figure 5, which can not only realize the automatic configuration of OSPF, but also the repeat topology determination module 604 can automatically identify the first OSPF process and the second OSPF process After the repeated topologies are collected, the repeated topology merging module 605 can automatically merge the repeated topologies into one topology. This method realizes automatic merging of duplicate topologies, thereby avoiding path calculation errors and improving the success rate of OSPF configuration.

上述实施例中的OSPF配置装置主要针对第一Master与AP相连的接口而言。但在一般的虚拟集群系统中,Master之间也需要相连。本发明实施例在图5所示的实施例的基础上还提供了另一中OSPF配置装置,用于实现Master间的OSPF配置。其结构请参阅图7,包括:The OSPF configuration apparatus in the foregoing embodiments is mainly aimed at the interface connecting the first Master to the AP. But in a general virtual cluster system, the Master also needs to be connected. On the basis of the embodiment shown in FIG. 5 , the embodiment of the present invention provides another OSPF configuration device for implementing OSPF configuration between Masters. Please refer to Figure 7 for its structure, including:

进程创建模块701,用于在第一Master的第一接口上使能虚拟集群功能之后,自动创建第一OSPF进程,并将第一接口加入到第一OSPF进程中,在第一Master的第三接口上使能虚拟集群功能之后,自动创建第三OSPF进程,并将第三接口加入到第三OSPF进程中,其中第一接口是与AP相连的接口,第三接口是与第二Master相连的接口;The process creation module 701 is configured to automatically create a first OSPF process after the virtual cluster function is enabled on the first interface of the first Master, and add the first interface to the first OSPF process. After the virtual cluster function is enabled on the interface, the third OSPF process is automatically created, and the third interface is added to the third OSPF process. The first interface is the interface connected to the AP, and the third interface is connected to the second Master. interface;

标识分配模块702,用于在第一OSPF进程中分配第一Router ID,在第三OSPF进程中分配第三Router ID,该第一Router ID用于唯一标识在第一OSPF进程中的第一Master,该第三Router ID用于唯一标识在第三OSPF进程中的第一Master。优选的,第三Router ID为第一Master的管理IP地址;An identifier allocation module 702, configured to allocate a first Router ID in the first OSPF process, and allocate a third Router ID in the third OSPF process, where the first Router ID is used to uniquely identify the first Master in the first OSPF process , the third Router ID is used to uniquely identify the first Master in the third OSPF process. Preferably, the third Router ID is the management IP address of the first Master;

进程运行模块703,用于在标识分配模块602分配了第一Router ID和第三RouterID之后,运行第一OSPF进程和第三OSPF进程;在第三OSPF进程运行后,第一Master与第二Master就建立了OSPF邻接关系。A process running module 703, configured to run the first OSPF process and the third OSPF process after the first Router ID and the third Router ID are allocated by the identification allocation module 602; after the third OSPF process runs, the first Master and the second Master An OSPF adjacency relationship is established.

邻接描述加入模块704,用于将第三OSPF进程收集到的第一Master与第二Master的邻接关系描述加入到第一OSPF进程的路由链路状态通告Router LSA中,其中邻接关系描述用于表示第一Master与第二Master互为OSPF邻接。The adjacency description adding module 704 is used to add the adjacency description of the first Master and the second Master collected by the third OSPF process into the routing link state advertisement Router LSA of the first OSPF process, wherein the adjacency description is used to indicate The first master and the second master are OSPF neighbors to each other.

本发明实施例在图5所示的实施例的基础上提供了一种更进一步的OSPF配置装置,其中,进程创建模块701创建第三OSPF进程,并将与第二Master相连的第三接口加入到第三OSPF进程中;标识分配模块702在第三OSPF进程中分配第三路由器标识Router ID;进程运行模块703运行第三OSPF进程与第二Master建立OSPF邻接;最后邻接描述加入模块704将与第二Master的邻接关系描述加入到第一OSPF进程的Router LSA中。通过这样的方法,实现了与Master相连的接口的OSPF的自动配置,无需人工根据网络拓扑结果来规划与Master相连的接口的Router ID,简化了用户的操作,减少了用户的工作量,有利于虚拟集群系统的配置安装。The embodiment of the present invention provides a further OSPF configuration device on the basis of the embodiment shown in FIG. In the 3rd OSPF process; Identification allocation module 702 distributes the 3rd router identification Router ID in the 3rd OSPF process; Process operation module 703 runs the 3rd OSPF process and establishes OSPF adjacency with the second Master; Adjacency description joins module 704 at last with The adjacency description of the second Master is added to the Router LSA of the first OSPF process. Through this method, the OSPF automatic configuration of the interface connected to the Master is realized, and there is no need to manually plan the Router ID of the interface connected to the Master according to the network topology results, which simplifies the user's operation, reduces the user's workload, and is beneficial Configuration and installation of the virtual cluster system.

优选的,本实施例也可以与图6所示的实施例相结合,即进程创建模块701也可以创造第二OSPF进程,并将第二接口加入到第二OSPF进程中;标识分配模块702也可以在第二OSPF进程中分配第二Router ID;进程运行模块703也可以运行第二OSPF进程。OSPF装置也可以包括重复拓扑确定模块和重复拓扑合并模块,用于自动识别并合并重复拓扑。Preferably, this embodiment can also be combined with the embodiment shown in FIG. 6, that is, the process creation module 701 can also create a second OSPF process, and add the second interface to the second OSPF process; the identification distribution module 702 can also The second Router ID may be allocated in the second OSPF process; the process running module 703 may also run the second OSPF process. The OSPF device may also include a repeat topology determining module and a repeat topology merging module, which are used to automatically identify and merge repeat topologies.

优选的,第一Master与第二Master之间的数据报文均可以通过第三接口与第二Master之间的链路来传输,无需为第一Master设置额外的接口与第二Master相连,以达到节约接口个数的目的。其中第三接口可以为人为指定,也可以为第一Master自动设置,本发明实施例中不做限定。Preferably, the data message between the first Master and the second Master can be transmitted through the link between the third interface and the second Master, and there is no need to set an additional interface for the first Master to be connected to the second Master, so that To achieve the purpose of saving the number of interfaces. Wherein, the third interface may be designated manually, or may be automatically set by the first Master, which is not limited in this embodiment of the present invention.

为了便于理解上述实施例,下面将以一个具体的应用场景为例进行描述。In order to facilitate understanding of the foregoing embodiments, a specific application scenario will be used as an example for description below.

图1所示的虚拟集群系统中,第一Master上第一接口与第二接口与AP相连,第三接口与第二Master相连。用户在第一Master的第一接口、第二接口和第三接口上人工使能虚拟集群功能,进程创建模块701自动创建第一OSPF进程、第二OSPF进程和第三OSPF进程,并将第一接口加入到第一OSPF进程中,将第二接口加入到第二OSPF进程中,将第三接口加入到第三OSPF进程中。In the virtual cluster system shown in FIG. 1 , the first interface and the second interface on the first Master are connected to the AP, and the third interface is connected to the second Master. The user manually enables the virtual cluster function on the first interface, the second interface, and the third interface of the first Master, and the process creation module 701 automatically creates the first OSPF process, the second OSPF process, and the third OSPF process, and assigns the first The interface is added to the first OSPF process, the second interface is added to the second OSPF process, and the third interface is added to the third OSPF process.

标识分配模块702在第一OSPF进程中分配第一Router ID,在第二OSPF进程中分配第二Router ID,在第三OSPF进程中分配第三Router ID。其中,第一Router ID包括一个用于唯一标识第一OSPF进程的高位字节,和写有第一Master的NEID的三个低位字节;第二Router ID包括一个用于唯一标识第二OSPF进程的高位字节,和写有第一Master的NEID的三个低位字节;第二Router ID为第一Master的管理IP地址。The identifier allocation module 702 allocates the first Router ID in the first OSPF process, allocates the second Router ID in the second OSPF process, and allocates the third Router ID in the third OSPF process. Wherein, the first Router ID includes a high-order byte used to uniquely identify the first OSPF process, and three low-order bytes written with the NEID of the first Master; the second Router ID includes a high-order byte used to uniquely identify the second OSPF process The high-order byte, and the three low-order bytes written with the NEID of the first Master; the second Router ID is the management IP address of the first Master.

进程运行模块703运行第一OSPF进程、第二OSPF进程和第三OSPF进程,并通过运行的进程收集虚拟集群系统的拓扑。The process running module 703 runs the first OSPF process, the second OSPF process and the third OSPF process, and collects the topology of the virtual cluster system through the running processes.

在收集拓扑时,第一OSPF进程获取到第一Master的第一Router ID和第二RouterID,第二OSPF进程也获取到第一Master的第一Router ID和第二Router ID。OSPF装置中的重复拓扑确定模块确定第一OSPF进程和第二OSPF进程获取到的第一Router ID和第二Router ID相同,故确认第一OSPF进程和第二OSPF进程收集到了重复的拓扑,于是。OSPF装置中的重复拓扑合并模块将第二接口加入到第一OSPF进程中,然后删除第二OSPF进程。When collecting the topology, the first OSPF process obtains the first Router ID and the second Router ID of the first Master, and the second OSPF process also obtains the first Router ID and the second Router ID of the first Master. The duplicate topology determination module in the OSPF device determines that the first and second Router IDs acquired by the first OSPF process and the second OSPF process are the same, so it is confirmed that the first OSPF process and the second OSPF process have collected duplicate topologies, so . The duplicate topology merging module in the OSPF device adds the second interface into the first OSPF process, and then deletes the second OSPF process.

第三OSPF进程运行后,第一Master与第二Master之间建立了邻接关系,第三OSPF进程会收集到第一Master与第二Master的邻接关系描述。邻接描述加入模块704将该邻接关系描述加入到第一OSPF进程的Router LSA中,使得第一Master—AP—第二Master形成闭环的拓扑。After the third OSPF process runs, an adjacency relationship is established between the first Master and the second Master, and the third OSPF process will collect descriptions of the adjacency relationship between the first Master and the second Master. The adjacency description adding module 704 adds the adjacency relationship description to the Router LSA of the first OSPF process, so that the first Master—AP—the second Master forms a closed-loop topology.

上面从单元化功能实体的角度对本发明实施例中的OSPF配置装置进行了描述,下面从硬件处理的角度对本发明实施例中的OSPF配置装置进行描述,请参阅图8,本发明实施例中的OSPF配置装置800另一实施例包括:The OSPF configuration device in the embodiment of the present invention has been described above from the perspective of unitized functional entities, and the OSPF configuration device in the embodiment of the present invention is described below from the perspective of hardware processing. Please refer to FIG. 8, the Another embodiment of the OSPF configuration device 800 includes:

输入装置801、输出装置802、处理器803和存储器804(其中OSPF配置装置800中的处理器803的数量可以一个或多个,图8中以一个处理器803为例)。在本发明的一些实施例中,输入装置801、输出装置802、处理器803和存储器804可通过总线或其它方式连接,其中,图8中以通过总线连接为例。An input device 801 , an output device 802 , a processor 803 and a memory 804 (the number of processors 803 in the OSPF configuration device 800 may be one or more, one processor 803 is taken as an example in FIG. 8 ). In some embodiments of the present invention, the input device 801 , the output device 802 , the processor 803 and the memory 804 may be connected through a bus or in other ways, wherein connection through a bus is taken as an example in FIG. 8 .

其中,通过调用存储器804存储的操作指令,处理器803用于执行如下步骤:Wherein, by calling the operation instructions stored in the memory 804, the processor 803 is configured to perform the following steps:

当第一Master的第一接口上使能虚拟集群功能之后,创建第一OSPF进程,并将第一接口加入到第一OSPF进程中,其中第一接口是与AP相连的接口;After enabling the virtual cluster function on the first interface of the first Master, create a first OSPF process, and add the first interface to the first OSPF process, where the first interface is an interface connected to the AP;

在第一OSPF进程中分配第一Router ID,该第一Router ID用于唯一标识在第一OSPF进程中的第一Master;Assigning a first Router ID in the first OSPF process, the first Router ID is used to uniquely identify the first Master in the first OSPF process;

运行第一OSPF进程。Run the first OSPF process.

本发明的一些实施例中,第一Router ID包括用于唯一标识第一Master所处的OSPF进程的字段,和用于唯一标识第一Master的字段。In some embodiments of the present invention, the first Router ID includes a field for uniquely identifying the OSPF process where the first Master resides, and a field for uniquely identifying the first Master.

本发明的一些实施例中,用于唯一标识第一Master的字段为第一Master的NEID。In some embodiments of the present invention, the field used to uniquely identify the first Master is the NEID of the first Master.

本发明的一些实施例中,处理器803还执行如下步骤:In some embodiments of the present invention, the processor 803 also performs the following steps:

当第一Master的第二接口上使能虚拟集群功能之后,创建第二OSPF进程,并将第二接口加入到第二OSPF进程中,第二接口是与AP相连的接口;After enabling the virtual cluster function on the second interface of the first Master, create a second OSPF process, and add the second interface to the second OSPF process, the second interface is an interface connected to the AP;

在第二OSPF进程中分配第二Router ID,第二Router ID用于唯一标识在第二OSPF进程中的第一Master;Assigning a second Router ID in the second OSPF process, the second Router ID is used to uniquely identify the first Master in the second OSPF process;

运行所述第二OSPF进程。Run the second OSPF process.

本发明的一些实施例中,处理器803还执行如下步骤:In some embodiments of the present invention, the processor 803 also performs the following steps:

确定第一OSPF进程和第二OSPF进程收集了重复的拓扑;Determining that the first OSPF process and the second OSPF process have collected duplicate topologies;

将重复的拓扑合并为一个拓扑。Merge duplicate topologies into one topology.

本发明的一些实施例中,处理器803还执行如下步骤:In some embodiments of the present invention, the processor 803 also performs the following steps:

从第一OSPF进程中获取到第一Master的Router ID为第一Router ID和第二Router ID;Obtaining the Router ID of the first Master from the first OSPF process is the first Router ID and the second Router ID;

从第二OSPF进程中获取到第一Master的Router ID为第一Router ID和第二Router ID;Obtaining the Router ID of the first Master from the second OSPF process is the first Router ID and the second Router ID;

确定从第一OSPF进程中获取到的第一Router ID和第二Router ID与从第二OSPF进程中获取到的第一Router ID和第二Router ID相同,则确定第一OSPF进程和第二OSPF进程收集了重复的拓扑。Determine that the first Router ID and the second Router ID obtained from the first OSPF process are identical to the first Router ID and the second Router ID obtained from the second OSPF process, then determine that the first OSPF process and the second OSPF Process collected duplicate topology.

本发明的一些实施例中,处理器803还执行如下步骤:In some embodiments of the present invention, the processor 803 also performs the following steps:

从第一OSPF进程中获取至少一条RI LSA,RI LSA中携带有发送该RI LSA的节点的身份类型,其中身份类型包括Master或AP;Obtain at least one RI LSA from the first OSPF process, where the RI LSA carries the identity type of the node sending the RI LSA, where the identity type includes Master or AP;

根据获取到的RI LSA确定身份类型为Master的节点,并从第一OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID为第一Router ID和第二Router ID;Determine the node whose identity type is Master according to the obtained RI LSA, and obtain the Router ID of the node whose identity type is Master from the first OSPF process, and obtain the Router ID of the first Master as the first Router ID and the second Router ID;

和/或,and / or,

从第二OSPF进程中获取至少一条RI LSA,RI LSA中携带有发送该RI LSA的节点的身份类型,其中身份类型包括Master或AP;Obtain at least one RI LSA from the second OSPF process, where the RI LSA carries the identity type of the node sending the RI LSA, where the identity type includes Master or AP;

根据获取到的RI LSA确定身份类型为Master的节点,并从第二OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID为第一Router ID和第二Router ID。Determine the node whose identity type is Master according to the obtained RI LSA, and obtain the Router ID of the node whose identity type is Master from the second OSPF process, and obtain the Router ID of the first Master as the first Router ID and the second Router ID.

本发明的一些实施例中,处理器803还执行如下步骤:In some embodiments of the present invention, the processor 803 also performs the following steps:

将第二接口加入到第一OSPF进程中;adding the second interface to the first OSPF process;

删除第二OSPF进程。Delete the second OSPF process.

本发明的一些实施例中,处理器803还执行如下步骤:In some embodiments of the present invention, the processor 803 also performs the following steps:

在第一Master的第三接口上使能虚拟集群功能之后,创建第三OSPF进程,并将第三接口加入到第三OSPF进程中,第三接口是与第二Master相连的接口;After enabling the virtual cluster function on the third interface of the first Master, create a third OSPF process, and add the third interface to the third OSPF process, where the third interface is an interface connected to the second Master;

在第三OSPF进程中分配第三Router ID,其中第三Router ID用于唯一标识在第三OSPF进程中的第一Master,第三Router ID为第一Master的管理IP地址;Distribute the 3rd Router ID in the 3rd OSPF process, wherein the 3rd Router ID is used for uniquely identifying the first Master in the 3rd OSPF process, the 3rd Router ID is the management IP address of the first Master;

运行第三OSPF进程。Run the third OSPF process.

本发明的一些实施例中,处理器803还执行如下步骤:In some embodiments of the present invention, the processor 803 also performs the following steps:

将第三OSPF进程收集到的第一Master与第二Master的邻接关系描述加入到第一OSPF进程的Router LSA中,所述邻接关系描述用于表示第一Master与第二Master互为OSPF邻接。The adjacency description of the first Master and the second Master collected by the third OSPF process is added to the Router LSA of the first OSPF process, and the adjacency description is used to indicate that the first Master and the second Master are OSPF adjacent to each other.

所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统,装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Those skilled in the art can clearly understand that for the convenience and brevity of the description, the specific working process of the above-described system, device and unit can refer to the corresponding process in the foregoing method embodiment, which will not be repeated here.

在本申请所提供的几个实施例中,应该理解到,所揭露的系统,装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed system, device and method can be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of the units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or May be integrated into another system, or some features may be ignored, or not implemented. In another point, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces, and the indirect coupling or communication connection of devices or units may be in electrical, mechanical or other forms.

所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

另外,在本发明各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, each unit may exist separately physically, or two or more units may be integrated into one unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units.

所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本发明各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(ROM,Read-OnlyMemory)、随机存取存储器(RAM,Random Access Memory)、磁碟或者光盘等各种可以存储程序代码的介质。If the integrated unit is realized in the form of a software function unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the essence of the technical solution of the present invention or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium , including several instructions to make a computer device (which may be a personal computer, a server, or a network device, etc.) execute all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic disk or optical disk, and other media that can store program codes.

以上所述,以上实施例仅用以说明本发明的技术方案,而非对其限制;尽管参照前述实施例对本发明进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本发明各实施例技术方案的精神和范围。As mentioned above, the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that: it can still understand the foregoing The technical solutions recorded in each embodiment are modified, or some of the technical features are replaced equivalently; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the various embodiments of the present invention.

Claims (22)

1.一种OSPF配置方法,适用于虚拟集群系统,其特征在于,所述虚拟集群系统包括核心汇聚节点Master与接入节点AP,所述方法包括:1. A kind of OSPF configuration method, is applicable to virtual cluster system, it is characterized in that, described virtual cluster system comprises core aggregation node Master and access node AP, and described method comprises: 当第一Master的第一接口上使能虚拟集群功能之后,所述第一Master创建第一OSPF进程,并将所述第一接口加入到所述第一OSPF进程中,所述第一接口是与所述AP相连的接口;After the virtual cluster function is enabled on the first interface of the first Master, the first Master creates a first OSPF process, and adds the first interface to the first OSPF process, and the first interface is an interface connected to the AP; 所述第一Master在所述第一OSPF进程中分配第一路由器标识Router ID,所述第一Router ID用于唯一标识在所述第一OSPF进程中的所述第一Master;The first Master assigns a first router identifier Router ID in the first OSPF process, and the first Router ID is used to uniquely identify the first Master in the first OSPF process; 所述第一Master运行所述第一OSPF进程。The first Master runs the first OSPF process. 2.根据权利要求1所述的OSPF配置方法,其特征在于,所述第一Router ID包括用于唯一标识所述第一OSPF进程的字段,和用于唯一标识所述第一Master的字段。2. The OSPF configuration method according to claim 1, wherein the first Router ID includes a field for uniquely identifying the first OSPF process and a field for uniquely identifying the first Master. 3.根据权利要求2所述的OSPF配置方法,其特征在于,所述用于唯一标识所述第一Master的字段的内容为所述第一Master的网络设备标识NEID。3. The OSPF configuration method according to claim 2, wherein the content of the field for uniquely identifying the first Master is the network device identifier NEID of the first Master. 4.根据权利要求1至3中任一项所述的OSPF配置方法,其特征在于,所述方法还包括:4. according to the OSPF configuration method described in any one in claim 1 to 3, it is characterized in that, described method also comprises: 当所述第一Master的第二接口上使能虚拟集群功能之后,所述第一Master创建第二OSPF进程,并将所述第二接口加入到所述第二OSPF进程中,所述第二接口是与所述AP相连的接口;After the virtual cluster function is enabled on the second interface of the first Master, the first Master creates a second OSPF process, and adds the second interface to the second OSPF process, and the second The interface is an interface connected to the AP; 所述第一Master在所述第二OSPF进程中分配第二Router ID,所述第二Router ID用于唯一标识在所述第二OSPF进程中的所述第一Master;The first Master allocates a second Router ID in the second OSPF process, and the second Router ID is used to uniquely identify the first Master in the second OSPF process; 所述第一Master运行所述第二OSPF进程。The first Master runs the second OSPF process. 5.根据权利要求4所述的OSPF配置方法,其特征在于,所述方法还包括:5. OSPF configuration method according to claim 4, is characterized in that, described method also comprises: 所述第一Master确定所述第一OSPF进程和所述第二OSPF进程收集了重复的拓扑;The first Master determines that the first OSPF process and the second OSPF process have collected duplicate topologies; 所述第一Master将所述重复的拓扑合并为一个拓扑。The first Master merges the repeated topologies into one topology. 6.根据权利要求5所述的OSPF配置方法,其特征在于,6. OSPF configuration method according to claim 5, is characterized in that, 所述第一Master确定所述第一OSPF进程和所述第二OSPF进程收集了重复的拓扑包括:The first Master determines that the first OSPF process and the second OSPF process have collected duplicate topologies including: 所述第一Master从所述第一OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID;The first Master acquires the Router ID of the first Master from the first OSPF process as the first Router ID and the second Router ID; 所述第一Master从所述第一OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID包括:The Router ID that the first Master obtains the first Master from the first OSPF process is that the first Router ID and the second Router ID include: 所述第一Master从所述第一OSPF进程中获取至少一条第一路由器信息链路状态宣告RI LSA,所述第一RI LSA中携带有发送所述第一RI LSA的节点的身份类型,所述身份类型包括Master或者AP;The first Master acquires at least one first router information link state announcement RI LSA from the first OSPF process, the first RI LSA carries the identity type of the node sending the first RI LSA, and The above identity types include Master or AP; 所述第一Master根据获取到的所述第一RI LSA确定身份类型为Master的节点,并从所述第一OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的RouterID为所述第一Router ID和所述第二Router ID;The first Master determines the node whose identity type is Master according to the obtained first RI LSA, and obtains the Router ID of the node whose identity type is Master from the first OSPF process, and obtains that the RouterID of the first Master is The first Router ID and the second Router ID; 所述第一Master从所述第二OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID;The first Master acquires the Router ID of the first Master from the second OSPF process as the first Router ID and the second Router ID; 所述第一Master从所述第二OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID包括:The Router ID that the first Master obtains the first Master from the second OSPF process is that the first Router ID and the second Router ID include: 所述第一Master从所述第二OSPF进程中获取至少一条第二RI LSA,所述第二RI LSA中携带有发送所述第二RI LSA的节点的身份类型;The first Master obtains at least one second RI LSA from the second OSPF process, and the second RI LSA carries the identity type of the node sending the second RI LSA; 所述第一Master根据获取到的所述第二RI LSA确定身份类型为Master的节点,并从所述第二OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的RouterID为所述第一Router ID和所述第二Router ID;The first Master determines the node whose identity type is Master according to the obtained second RI LSA, and obtains the Router ID of the node whose identity type is Master from the second OSPF process, and obtains that the RouterID of the first Master is The first Router ID and the second Router ID; 所述第一Master确定从所述第一OSPF进程中获取到的所述第一Router ID和所述第二Router ID与从所述第二OSPF进程中获取到的所述第一Router ID和所述第二Router ID相同,则所述第一Master确定所述第一OSPF进程和所述第二OSPF进程收集了重复的拓扑。The first Master determines the first Router ID and the second Router ID obtained from the first OSPF process and the first Router ID and the second Router ID obtained from the second OSPF process If the second Router ID is the same, the first Master determines that the first OSPF process and the second OSPF process have collected duplicate topologies. 7.根据权利要求6所述的OSPF配置方法,其特征在于,所述第一Master从所述第一OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID包括:7. The OSPF configuration method according to claim 6, wherein the first Master obtains the Router ID of the first Master from the first OSPF process as the first Router ID and the The second router ID includes: 所述第一Master从所述第一OSPF进程中获取至少一条路由器信息链路状态宣告RILSA,所述RI LSA中携带有发送所述RI LSA的节点的身份类型,所述身份类型包括Master或AP;The first Master obtains at least one router information link state announcement RILSA from the first OSPF process, and the RI LSA carries the identity type of the node sending the RI LSA, and the identity type includes Master or AP ; 所述第一Master根据获取到的RI LSA确定身份类型为Master的节点,并从所述第一OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID为所述第一Router ID和所述第二Router ID;The first Master determines the node whose identity type is Master according to the obtained RI LSA, and obtains the Router ID of the node whose identity type is Master from the first OSPF process, and obtains that the Router ID of the first Master is the first a Router ID and the second Router ID; 和/或,and / or, 所述第一Master从所述第二OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID包括:The Router ID that the first Master obtains the first Master from the second OSPF process is that the first Router ID and the second Router ID include: 所述第一Master从所述第二OSPF进程中获取至少一条RI LSA,所述RI LSA中携带有发送所述RI LSA的节点的身份类型,所述身份类型包括Master或AP;The first Master obtains at least one RI LSA from the second OSPF process, the RI LSA carries the identity type of the node sending the RI LSA, and the identity type includes Master or AP; 所述第一Master根据获取到的RI LSA确定身份类型为Master的节点,并从所述第二OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID为所述第一Router ID和所述第二Router ID。The first Master determines the node whose identity type is Master according to the obtained RI LSA, and obtains the Router ID of the node whose identity type is Master from the second OSPF process, and obtains that the Router ID of the first Master is the first A Router ID and the second Router ID. 8.根据权利要求5所述的OSPF配置方法,其特征在于,所述将所述重复的拓扑合并为一个拓扑包括:8. The OSPF configuration method according to claim 5, wherein said merging said repeated topology into one topology comprises: 所述第一Master将所述第二接口加入到所述第一OSPF进程中;The first Master adds the second interface to the first OSPF process; 所述第一Master删除所述第二OSPF进程。The first Master deletes the second OSPF process. 9.根据权利要求1至3中任一项所述的OSPF配置方法,其特征在于,所述方法还包括:9. according to the OSPF configuration method described in any one in claim 1 to 3, it is characterized in that, described method also comprises: 当所述第一Master的第三接口上使能虚拟集群功能之后,所述第一Master创建第三OSPF进程,并将所述第三接口加入到所述第三OSPF进程中,所述第三接口是与第二Master相连的接口;After the virtual cluster function is enabled on the third interface of the first Master, the first Master creates a third OSPF process, and adds the third interface to the third OSPF process, and the third The interface is an interface connected to the second Master; 所述第一Master在所述第三OSPF进程中分配第三Router ID,所述第三Router ID用于唯一标识在所述第三OSPF进程中的所述第一Master;The first Master allocates a third Router ID in the third OSPF process, and the third Router ID is used to uniquely identify the first Master in the third OSPF process; 所述第一Master运行所述第三OSPF进程。The first Master runs the third OSPF process. 10.根据权利要求9所述的OSPF配置方法,其特征在于,所述第三Router ID为所述第一Master的管理IP地址。10. The OSPF configuration method according to claim 9, wherein the third Router ID is the management IP address of the first Master. 11.根据权利要求9所述的OSPF配置方法,其特征在于,所述方法还包括:11. OSPF configuration method according to claim 9, is characterized in that, described method also comprises: 所述第一Master将所述第三OSPF进程收集到的所述第一Master与所述第二Master的邻接关系描述加入到所述第一OSPF进程的路由链路状态通告Router LSA中,所述邻接关系描述用于表示所述第一Master与所述第二Master互为OSPF邻接。The first Master adds the adjacency description between the first Master and the second Master collected by the third OSPF process into the Router LSA of the first OSPF process, and the The adjacency description is used to indicate that the first Master and the second Master are OSPF adjacent to each other. 12.一种OSPF配置装置,适用于虚拟集群系统中的第一核心汇聚节点Master,其特征在于,所述虚拟集群系统还包括接入节点AP,所述OSPF配置装置包括:12. An OSPF configuration device, applicable to the first core aggregation node Master in a virtual cluster system, characterized in that, the virtual cluster system also includes an access node AP, and the OSPF configuration device includes: 进程创建模块,用于当第一Master的第一接口上使能虚拟集群功能之后,创建第一OSPF进程,并将所述第一接口加入到所述第一OSPF进程中,所述第一接口是与所述AP相连的接口;A process creation module, configured to create a first OSPF process after the virtual cluster function is enabled on the first interface of the first Master, and add the first interface to the first OSPF process, the first interface is an interface connected to the AP; 标识分配模块,用于在所述第一OSPF进程中分配第一路由器标识Router ID,所述第一Router ID用于唯一标识在所述第一OSPF进程中的所述第一Master;An identification allocation module, configured to allocate a first router identification Router ID in the first OSPF process, and the first Router ID is used to uniquely identify the first Master in the first OSPF process; 进程运行模块,用于运行所述第一OSPF进程。A process running module, configured to run the first OSPF process. 13.根据权利要求12所述的OSPF配置装置,其特征在于,所述第一Router ID包括用于唯一标识所述第一OSPF进程的字段,和用于唯一标识所述第一Master的字段。13. The OSPF configuration device according to claim 12, wherein the first Router ID includes a field for uniquely identifying the first OSPF process and a field for uniquely identifying the first Master. 14.根据权利要求13所述的OSPF配置装置,其特征在于,所述用于唯一标识所述第一Master的字段的内容为所述第一Master的网络设备标识NEID。14. The OSPF configuration device according to claim 13, wherein the content of the field for uniquely identifying the first Master is a network device identifier NEID of the first Master. 15.根据权利要求12至14中任一项所述的OSPF配置装置,其特征在于,所述进程创建模块还用于:15. The OSPF configuration device according to any one of claims 12 to 14, wherein the process creation module is also used for: 当所述第一Master的第二接口上使能虚拟集群功能之后,创建第二OSPF进程,并将所述第二接口加入到所述第二OSPF进程中,所述第二接口是与所述AP相连的接口;After the virtual cluster function is enabled on the second interface of the first Master, a second OSPF process is created, and the second interface is added to the second OSPF process, and the second interface is connected to the The interface connected to the AP; 所述标识分配模块还用于:在所述第二OSPF进程中分配第二Router ID,所述第二Router ID用于唯一标识在所述第二OSPF进程中的所述第一Master;The identification allocation module is further configured to: allocate a second Router ID in the second OSPF process, and the second Router ID is used to uniquely identify the first Master in the second OSPF process; 所述进程运行模块还用于:运行所述第二OSPF进程。The process running module is also used for: running the second OSPF process. 16.根据权利要求15所述的OSPF配置装置,其特征在于,所述装置还包括:16. The OSPF configuration device according to claim 15, wherein the device further comprises: 重复拓扑确定模块,用于确定所述第一OSPF进程和所述第二OSPF进程收集了重复的拓扑;A duplicate topology determination module, configured to determine that the first OSPF process and the second OSPF process have collected duplicate topologies; 重复拓扑合并模块,用于将所述重复的拓扑合并为一个拓扑。The repeated topology merging module is used for merging the repeated topologies into one topology. 17.根据权利要求16所述的OSPF配置装置,其特征在于,所述重复拓扑确定模块具体用于:17. OSPF configuration device according to claim 16, is characterized in that, described repeated topology determination module is specifically used for: 从所述第一OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID;Obtaining the Router ID of the first Master from the first OSPF process is the first Router ID and the second Router ID; 所述从所述第一OSPF进程中获取到所述第一Master的Router ID为所述第一RouterID和所述第二Router ID包括:The Router ID obtained from the first OSPF process of the first Master is the first RouterID and the second Router ID including: 从所述第一OSPF进程中获取至少一条第一路由器信息链路状态宣告RI LSA,所述第一RI LSA中携带有发送所述第一RI LSA的节点的身份类型,所述身份类型包括Master或者AP;Obtain at least one first router information link state announcement RI LSA from the first OSPF process, the first RI LSA carries the identity type of the node sending the first RI LSA, and the identity type includes Master or AP; 根据获取到的所述第一RI LSA确定身份类型为Master的节点,并从所述第一OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID为所述第一Router ID和所述第二Router ID;Determine the node whose identity type is Master according to the obtained first RI LSA, and obtain the Router ID of the node whose identity type is Master from the first OSPF process, and obtain the Router ID of the first Master as the first Router ID and the second Router ID; 从所述第二OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID;Obtaining the Router ID of the first Master from the second OSPF process is the first Router ID and the second Router ID; 所述从所述第二OSPF进程中获取到所述第一Master的Router ID为所述第一RouterID和所述第二Router ID包括:The obtaining the Router ID of the first Master from the second OSPF process is the first RouterID and the second Router ID include: 从所述第二OSPF进程中获取至少一条第二RI LSA,所述第二RI LSA中携带有发送所述第二RI LSA的节点的身份类型;Obtain at least one second RI LSA from the second OSPF process, where the second RI LSA carries the identity type of the node sending the second RI LSA; 根据获取到的所述第二RI LSA确定身份类型为Master的节点,并从所述第二OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID为所述第一Router ID和所述第二Router ID;Determine the node whose identity type is Master according to the obtained second RI LSA, and obtain the Router ID of the node whose identity type is Master from the second OSPF process, and obtain the Router ID of the first Master as the first Router ID and the second Router ID; 确定从所述第一OSPF进程中获取到的所述第一Router ID和所述第二Router ID与从所述第二OSPF进程中获取到的所述第一Router ID和所述第二Router ID相同,则确定所述第一OSPF进程和所述第二OSPF进程收集了重复的拓扑。Determining the first Router ID and the second Router ID obtained from the first OSPF process and the first Router ID and the second Router ID obtained from the second OSPF process If they are the same, it is determined that the first OSPF process and the second OSPF process have collected duplicate topologies. 18.根据权利要求17所述的OSPF配置装置,其特征在于,所述重复拓扑确定模块通过如下方法从所述第一OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID:18. The OSPF configuration device according to claim 17, wherein the repeat topology determination module acquires the Router ID of the first Master from the first OSPF process by the following method as the first Router ID and the second Router ID: 从所述第一OSPF进程中获取至少一条路由器信息链路状态宣告RI LSA,所述RI LSA中携带有发送所述RI LSA的节点的身份类型,所述身份类型包括Master或AP;Acquire at least one router information link state announcement RI LSA from the first OSPF process, the RI LSA carries the identity type of the node sending the RI LSA, and the identity type includes Master or AP; 根据获取到的RI LSA确定身份类型为Master的节点,并从所述第一OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID为所述第一Router ID和所述第二Router ID;Determine the node whose identity type is Master according to the obtained RI LSA, and obtain the Router ID of the node whose identity type is Master from the first OSPF process, and obtain the Router ID of the first Master as the first Router ID and the The second Router ID mentioned above; 和/或,and / or, 所述重复拓扑确定模块通过如下方法从所述第二OSPF进程中获取到所述第一Master的Router ID为所述第一Router ID和所述第二Router ID:The repeat topology determination module acquires the Router ID of the first Master from the second OSPF process as the first Router ID and the second Router ID through the following method: 从所述第二OSPF进程中获取至少一条RI LSA,所述RI LSA中携带有发送所述RI LSA的节点的身份类型,所述身份类型包括Master或AP;Obtain at least one RI LSA from the second OSPF process, where the RI LSA carries the identity type of the node sending the RI LSA, where the identity type includes Master or AP; 根据获取到的RI LSA确定身份类型为Master的节点,并从所述第二OSPF进程中获取身份类型为Master的节点的Router ID,得到第一Master的Router ID为所述第一Router ID和所述第二Router ID。Determine the node whose identity type is Master according to the obtained RI LSA, and obtain the Router ID of the node whose identity type is Master from the second OSPF process, and obtain the Router ID of the first Master as the first Router ID and the Describe the second Router ID. 19.根据权利要求16所述的OSPF配置装置,其特征在于,所述重复拓扑合并模块具体用于:19. The OSPF configuration device according to claim 16, wherein the repeated topology merging module is specifically used for: 将所述第二接口加入到所述第一OSPF进程中;adding the second interface to the first OSPF process; 删除所述第二OSPF进程。Delete the second OSPF process. 20.根据权利要求12至14中任一项所述的OSPF配置装置,其特征在于,所述虚拟集群系统还包括第二Master,所述进程创建模块还用于:20. The OSPF configuration device according to any one of claims 12 to 14, wherein the virtual cluster system also includes a second Master, and the process creation module is also used for: 当所述第一Master的第三接口上使能虚拟集群功能之后,创建第三OSPF进程,并将所述第三接口加入到所述第三OSPF进程中,所述第三接口是与所述第二Master相连的接口;After the virtual cluster function is enabled on the third interface of the first Master, a third OSPF process is created, and the third interface is added to the third OSPF process, and the third interface is connected to the The interface connected to the second Master; 所述标识分配模块还用于:在所述第三OSPF进程中分配第三Router ID,所述第三Router ID用于唯一标识在所述第三OSPF进程中的所述第一Master;The identification allocation module is further configured to: allocate a third Router ID in the third OSPF process, and the third Router ID is used to uniquely identify the first Master in the third OSPF process; 所述进程运行模块还用于:运行所述第三OSPF进程。The process running module is also used for: running the third OSPF process. 21.根据权利要求20所述的OSPF配置装置,其特征在于,所述第三Router ID为所述第一Master的管理IP地址。21. The OSPF configuration device according to claim 20, wherein the third Router ID is the management IP address of the first Master. 22.根据权利要求20所述的OSPF配置装置,其特征在于,所述装置还包括:22. The OSPF configuration device according to claim 20, wherein the device further comprises: 邻接描述加入模块,用于将所述第三OSPF进程收集到的所述第一Master与所述第二Master的邻接关系描述加入到所述第一OSPF进程的路由链路状态通告Router LSA中,所述邻接关系描述用于表示所述第一Master与所述第二Master互为OSPF邻接。an adjacency description adding module, configured to add the adjacency description of the first Master and the second Master collected by the third OSPF process into the Router LSA of the first OSPF process, The adjacency description is used to indicate that the first Master and the second Master are OSPF adjoining to each other.
CN201510222353.0A 2015-05-04 2015-05-04 A kind of OSPF configuration methods and relevant apparatus Active CN104852849B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510222353.0A CN104852849B (en) 2015-05-04 2015-05-04 A kind of OSPF configuration methods and relevant apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510222353.0A CN104852849B (en) 2015-05-04 2015-05-04 A kind of OSPF configuration methods and relevant apparatus

Publications (2)

Publication Number Publication Date
CN104852849A CN104852849A (en) 2015-08-19
CN104852849B true CN104852849B (en) 2018-10-19

Family

ID=53852214

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510222353.0A Active CN104852849B (en) 2015-05-04 2015-05-04 A kind of OSPF configuration methods and relevant apparatus

Country Status (1)

Country Link
CN (1) CN104852849B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109428868B (en) * 2017-08-31 2021-10-12 中兴通讯股份有限公司 Method, encryption device, encryption equipment and storage medium for encrypting OSPFv3
CN110569291B (en) * 2019-09-16 2022-04-15 东信和平科技股份有限公司 Key data query and acquisition method and device for digital currency wallet
CN113542000B (en) * 2021-05-20 2023-11-07 新华三大数据技术有限公司 Process number determining method and device

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1081899A2 (en) * 1999-08-06 2001-03-07 International Business Machines Corporation Method of configurating an OSPF interface
CN102318287A (en) * 2011-06-30 2012-01-11 华为技术有限公司 Methods and device to establish router neighbors
CN103178983A (en) * 2011-12-26 2013-06-26 中兴通讯股份有限公司 Method and device for configuring shortest path first protocol interface area identifications
CN104506438A (en) * 2015-01-09 2015-04-08 烽火通信科技股份有限公司 Method and system for automatic operation of data communication network (DCN)
CN104579728A (en) * 2013-10-17 2015-04-29 中兴通讯股份有限公司 Network element equipment configuration and management method and device as well as network element equipment

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1081899A2 (en) * 1999-08-06 2001-03-07 International Business Machines Corporation Method of configurating an OSPF interface
CN102318287A (en) * 2011-06-30 2012-01-11 华为技术有限公司 Methods and device to establish router neighbors
CN103178983A (en) * 2011-12-26 2013-06-26 中兴通讯股份有限公司 Method and device for configuring shortest path first protocol interface area identifications
CN104579728A (en) * 2013-10-17 2015-04-29 中兴通讯股份有限公司 Network element equipment configuration and management method and device as well as network element equipment
CN104506438A (en) * 2015-01-09 2015-04-08 烽火通信科技股份有限公司 Method and system for automatic operation of data communication network (DCN)

Also Published As

Publication number Publication date
CN104852849A (en) 2015-08-19

Similar Documents

Publication Publication Date Title
US11704144B2 (en) Creating virtual machine groups based on request
CN106487695B (en) A kind of data transmission method, virtual network managing device and data transmission system
CN104184663B (en) Communication means and device based on software defined network and integrated identification network
CN109451540B (en) A resource allocation method and device for network slicing
WO2017032300A1 (en) Data transmission method, virtual network management apparatus, and data transmission system
CN104601680B (en) A kind of method for managing resource and device
CN101895482A (en) Method and device for abstracting logical topology information of point-to-point technical network
CN105282003B (en) Establish the method and system and tunnel control device and virtual switch in tunnel
CN111182037B (en) A kind of mapping method and device of virtual network
CN107809495B (en) Address management method and device
WO2021037133A1 (en) Network management method and device
CN108718247A (en) A kind of Autonomous Domain grade method for simulating network based on virtualization technology
JP2016116184A (en) Network monitoring device and virtual network management method
EP2613500A1 (en) Content-centric network and method of performing routing between domains therefor
CN104852849B (en) A kind of OSPF configuration methods and relevant apparatus
CN102594924B (en) Internet architecture and internet service method and system thereof
CN103780467A (en) Communication connection method, communication device and communication system
CN114448937B (en) Access request response method and device, storage medium
CN116319301A (en) Resource management method and system applicable to multi-modal network
CN111181745A (en) Centralized unit function entity, base station and network management method
CN114024886B (en) Cross-resource-pool network intercommunication method, electronic equipment and readable storage medium
CN103563304A (en) Switch configuration method and cluster management device based on virtual networking
CN110022580A (en) Establish bearing method and device
US8855015B2 (en) Techniques for generic pruning in a trill network
CN104753852A (en) Virtualization platform and security protection method and device

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
EXSB Decision made by sipo to initiate substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant