KR102028651B1 - Method for selecting shard leader for fast synchronizations in software defined network - Google Patents

Method for selecting shard leader for fast synchronizations in software defined network Download PDF

Info

Publication number
KR102028651B1
KR102028651B1 KR1020170179284A KR20170179284A KR102028651B1 KR 102028651 B1 KR102028651 B1 KR 102028651B1 KR 1020170179284 A KR1020170179284 A KR 1020170179284A KR 20170179284 A KR20170179284 A KR 20170179284A KR 102028651 B1 KR102028651 B1 KR 102028651B1
Authority
KR
South Korea
Prior art keywords
controller
leader
shard
bandwidth
synchronization bandwidth
Prior art date
Application number
KR1020170179284A
Other languages
Korean (ko)
Other versions
KR20190077804A (en
Inventor
서동은
백상헌
구정우
Original Assignee
고려대학교 산학협력단
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 고려대학교 산학협력단 filed Critical 고려대학교 산학협력단
Priority to KR1020170179284A priority Critical patent/KR102028651B1/en
Priority to PCT/KR2018/013444 priority patent/WO2019132230A1/en
Publication of KR20190077804A publication Critical patent/KR20190077804A/en
Application granted granted Critical
Publication of KR102028651B1 publication Critical patent/KR102028651B1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1001Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
    • H04L67/1004Server selection for load balancing
    • H04L67/101Server selection for load balancing based on network conditions
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/40Support for services or applications
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1095Replication or mirroring of data, e.g. scheduling or transport for data synchronisation between network nodes

Abstract

샤드 리더를 선정하는 방법이 개시된다. 상기 샤드 리더를 선정하는 방법은 복수의 컨트롤러를 포함하는 소프트웨어 정의 네트워크 시스템에 포함된 리더 선정 모듈에 의해 수행되고, 주기마다 모든 컨트롤러들에 대한 가용 동기화 대역폭, 모든 샤드들에 대한 평균 요구 동기화 대역폭, 및 모든 컨트롤러들에 대한 한계 동기화 대역폭을 계산하는 단계, 한계 동기화 대역폭의 값이 음수인 컨트롤러가 존재하는 경우, 해당 컨트롤러가 리더로 동작하는 샤드들 중에서, 평균 요구 동기화 대역폭이 최소인 샤드를 선택하고, 해당 샤드의 새로운 리더로 선정되어도 한계 동기화 대역폭이 음수가 되지 않는 컨트롤러를 선택하는 단계; 및 해당 샤드의 리더쉽을 새로운 리더로 선택된 컨트롤러로 옮기고, 리더 매핑 상태를 업데이트 하는 단계를 포함한다.A method of selecting a shard leader is disclosed. The method of selecting a shard reader is performed by a leader selection module included in a software defined network system including a plurality of controllers, and the available synchronization bandwidth for all controllers, the average required synchronization bandwidth for all shards, And calculating a limit synchronization bandwidth for all controllers, if a controller having a negative value of the limit synchronization bandwidth is present, selecting a shard having a minimum average required synchronization bandwidth from among the shards in which the controller acts as a leader. Selecting a controller in which the limit synchronization bandwidth is not negative even if a new leader of the shard is selected; And transferring the leadership of the corresponding shard to the selected controller as a new leader and updating the leader mapping state.

Figure R1020170179284
Figure R1020170179284

Description

소프트웨어 정의 네트워크에서 샤드 리더 선정 방법{METHOD FOR SELECTING SHARD LEADER FOR FAST SYNCHRONIZATIONS IN SOFTWARE DEFINED NETWORK}METHOD FOR SELECTING SHARD LEADER FOR FAST SYNCHRONIZATIONS IN SOFTWARE DEFINED NETWORK}

본 발명의 개념에 따른 실시 예는 소프트웨어 정의 네트워크에서의 빠른 컨트롤러 동기화를 위한 리더 선정 방법에 관한 것으로서, 보다 상세하게는 복수의 컨트롤러들을 포함하는 분산 소프트웨어 정의 네트워크 환경에서 빠른 동기화를 위해 컨트롤러들 간의 가용 네트워크 대역폭 및 샤드의 가용 네트워크 대역폭 요구량을 고려한 샤드 리더 선정 방법에 관한 것이다.
An embodiment according to the concept of the present invention relates to a method for selecting a leader for fast controller synchronization in a software defined network. More specifically, the present invention provides a method for selecting a leader for fast synchronization in a distributed software defined network environment including a plurality of controllers. The present invention relates to a shard leader selection method in consideration of network bandwidth and shard available network bandwidth requirements.

소프트웨어 정의 네트워크(Software Defined Network: SDN)는 최근 네트워크 구축, 관리, 운용 등에서 발생하는 높은 비용과 복잡성을 근본적으로 해결하기 위해 제안된 것으로서, 기존 네트워크 장비의 제어부분과 패킷(또는 플로우) 전달 부분을 분리하는 구조를 갖는다.Software Defined Network (SDN) is proposed to fundamentally solve the high cost and complexity of network construction, management, and operation, and it is designed to replace the control part and packet (or flow) delivery part of existing network equipment. It has a structure to separate.

분산 SDN 컨트롤러 환경에서는 다수의 SDN 컨트롤러들이 서로 독립적인 집합의 네트워크 장비들 (예를 들어 네트워크 스위치)을 제어하게 된다. 또한, 컨트롤러들은 분산 데이터베이스 기술을 통해 서로 독립적으로 관리하는 네트워크에 대한 정보(즉, 데이터베이스)를 공유한다. 구체적으로, 컨트롤러 데이터베이스는 다수의 논리적인 데이터 파티션들(이하, '샤드' 또는 'Shard')로 분할되며, 각각의 샤드(Shard)에 대한 레플리카(Replica)들은 모든 컨트롤러들에게 저장된다. 샤드 별 레플리카들은 독립적인 Raft 그룹으로서 동작한다. 임의의 샤드에 대한 리더 레플리카(Leader Replica)는 데이터 변경 요청(예를 들어 생성, 업데이트, 삭제)을 받으면, 해당 요청에 따른 데이터 변경에 대해 네트워크를 통해 다른 Replica들(즉, Follower Replica들)에게 복제하는 작업을 수행한다. 샤드 리더(Shard Leader)는 과반수의 Follower Replica들에게 복제가 완료된 것을 확인한 뒤에 해당 데이터 변경을 데이터베이스에 반영한다. 또한 임의의 데이터에 대한 변경 요청을 Leader Replica가 받은 시점으로부터 과반수의 Follower Replica들에게 복제가 완료되는 시점 사이에 해당 데이터에 대한 다른 접근 요청(생성, 업데이트, 읽기, 삭제)이 도달할 시, 해당 요청은 큐에 저장되며 이전 요청에 대한 처리 (즉, 복제 및 복제 확인)가 완료되는 시점에 순차적으로 처리가 된다.In a distributed SDN controller environment, multiple SDN controllers control a set of network devices (eg network switches) that are independent of each other. In addition, controllers share information (ie, databases) about networks that are managed independently from each other through distributed database technology. Specifically, the controller database is divided into a number of logical data partitions (hereinafter referred to as 'shards' or 'shards'), and replicas for each shard are stored in all controllers. Shard-specific replicas act as independent Raft groups. When a leader replica for any shard receives a data change request (e.g. create, update, delete), it sends it to other replicas (i.e. Follower Replicas) over the network for the data change according to the request. Perform the task of cloning. The shard leader confirms to the majority of follower replicas that the replication is complete and then reflects the data changes in the database. In addition, when another request for access (creation, update, read, delete) of the data arrives from the time the Leader Replica receives a change request for any data to the majority of Follower Replicas, the replication is completed. Requests are queued and processed sequentially when processing for previous requests (ie, replication and replication confirmation) is complete.

한편, 도 1과 같이 WAN 환경에서 SDN 컨트롤러들 간의 동기화가 수행되는 경우에는 가용 네트워크 대역폭(Available Network Bandwidth: ABW)이 제한적이기 때문에 Leader가 위치한 컨트롤러에서 Follower들이 위치한 컨트롤러들로의 가용 네트워크 대역폭에 의해 해당 샤드에 대한 복제(즉, 동기화) 대역폭이 제한될 수 있다. 즉, 임의의 샤드의 Leader Replica가 위치한 컨트롤러에서 Follower Replica들이 위치한 컨트롤러들로의 가용 네트워크 대역폭이 매우 낮은 경우, 해당 샤드에 포함된 데이터들에 대한 변경 요청들이 저장된 큐에서의 대기 시간이 증가할 수 있고, 이는 복제(동기화)를 지연시켜 결과적으로 해당 샤드에 포함된 데이터들에 대한 접근 요청 스루풋이 저하될 수 있다. Meanwhile, when synchronization between SDN controllers is performed in a WAN environment as shown in FIG. 1, since available network bandwidth (ABW) is limited, the available network bandwidth from the controller where the leader is located to the controllers where the followers are located. Replication (ie, synchronization) bandwidth for that shard may be limited. In other words, if the available network bandwidth from the controller where the leader replica of any shard is located to the controller where the follower replicas are very low, the waiting time in the queue where the change requests for the data contained in the shard are stored may increase. This delays replication (synchronization), and as a result, access request throughput for data contained in the shard may be degraded.

따라서, 컨트롤러들 간의 가용 네트워크 대역폭을 고려하여 샤드 리더들을 컨트롤러들에 배치함으로써 샤드들의 동기화 대역폭이 네트워크에 의해 제한되지 않도록 할 필요가 있다. Therefore, there is a need to arrange shard leaders in controllers in consideration of the available network bandwidth between the controllers so that the synchronization bandwidth of the shards is not limited by the network.

또한, 기존 Raft 컨센서스 알고리즘(Raft Consensus Algorithm)에서 Leader는 앞서 언급한 컨트롤러들 간의 가용 네트워크 대역폭의 고려 없이 Randomized Timeout 기반으로 선출되기 때문에, 동기화 지연으로 인한 제어 평면 성능 저하가 발생할 수 있다. In addition, in the existing Raft Consensus Algorithm, the Leader is elected based on the Randomized Timeout without considering the available network bandwidth among the aforementioned controllers, which may result in deterioration of control plane performance due to synchronization delay.

따라서, 본 발명에서는 빠른 동기화를 위해 컨트롤러들 간의 가용 네트워크 대역폭 및 샤드의 가용 네트워크 대역폭 요구량을 고려한 샤드 리더 선정 방법을 제안한다.
Therefore, the present invention proposes a method of selecting a shard leader considering the available network bandwidth between controllers and the available network bandwidth requirement of the shard for fast synchronization.

USUS 2017-01540912017-0154091 A1A1 USUS 2017-00244532017-0024453 A1A1 JPJP 2016-2198592016-219859 AA

Load balancing on distributed datastore in opendaylight SDN controller cluster (http://ieeexplore.ieee.org/document/8004238/) Load balancing on distributed datastore in opendaylight SDN controller cluster (http://ieeexplore.ieee.org/document/8004238/)

본 발명이 이루고자 하는 기술적인 과제는 소프트웨어 정의 네트워크에서의 빠른 컨트롤러 동기화를 위해 컨트롤러들 간의 가용 네트워크 대역폭 및 샤드의 가용 네트워크 대역폭 요구량을 고려한 샤드 리더 선정 방법을 제공하는 것이다.
The technical problem to be achieved by the present invention is to provide a shard leader selection method considering the available network bandwidth between the controllers and the available network bandwidth requirements of the shard for fast controller synchronization in a software defined network.

본 발명의 실시 예에 따른 소프트웨어 정의 네트워크에서 샤드 리더 선정 방법은 복수의 컨트롤러를 포함하는 소프트웨어 정의 네트워크 시스템에 포함된 리더 선정 모듈에 의해 수행되고,In the software defined network according to an embodiment of the present invention, the method of selecting a shard reader is performed by a leader selection module included in a software defined network system including a plurality of controllers.

컨트롤러 집합 C, 샤드 집합 P, 리더 매핑 상태

Figure 112017128843682-pat00001
, 및 주기 T를 입력으로 하여, 상기 주기 T마다 모든 컨트롤러들에 대한 가용 동기화 대역폭, 모든 샤드들에 대한 평균 요구 동기화 대역폭, 및 모든 컨트롤러들에 대한 한계 동기화 대역폭을 계산하는 단계; 상기 한계 동기화 대역폭의 값이 음수인 컨트롤러가 존재하는지 확인하는 단계; 상기 한계 동기화 대역폭의 값이 음수인 컨트롤러(
Figure 112017128843682-pat00002
)가 존재하는 경우, 해당 컨트롤러(
Figure 112017128843682-pat00003
)가 리더로 동작하는 샤드들 중에서, 평균 요구 동기화 대역폭(RSBW)이 최소인 샤드(
Figure 112017128843682-pat00004
)를 선택하고, 해당 샤드(
Figure 112017128843682-pat00005
)의 새로운 리더로 선정되어도 한계 동기화 대역폭(MSBW)이 음수가 되지 않는 컨트롤러(
Figure 112017128843682-pat00006
)를 선택하는 단계; 및 상기 샤드(
Figure 112017128843682-pat00007
)의 리더쉽을 새로운 리더로 선택된 컨트롤러(
Figure 112017128843682-pat00008
)로 옮기고, 리더 매핑 상태
Figure 112017128843682-pat00009
를 업데이트 하는 단계를 포함한다.
Controller Set C, Shard Set P, Reader Mapping Status
Figure 112017128843682-pat00001
And, inputting period T, calculating the available synchronization bandwidth for all controllers, the average required synchronization bandwidth for all shards, and the limit synchronization bandwidth for all controllers, every period T; Checking whether a controller having a negative value of the limit synchronization bandwidth exists; A controller having a negative value of the threshold synchronization bandwidth
Figure 112017128843682-pat00002
) If present, the controller (
Figure 112017128843682-pat00003
Among the shards that act as readers, the shards with the lowest average required synchronization bandwidth (RSBW) (
Figure 112017128843682-pat00004
), The corresponding shard (
Figure 112017128843682-pat00005
Controller with non-negative limit synchronization bandwidth (MSBW)
Figure 112017128843682-pat00006
Selecting); And the shard (
Figure 112017128843682-pat00007
Controller selected as the new leader
Figure 112017128843682-pat00008
), Leader mapping status
Figure 112017128843682-pat00009
It includes the step of updating.

본 발명의 실시 예에 따른 리더 선정 방법에 의할 경우, 네트워크 대역폭을 고려하여 샤드 리더(Shard Leader)들을 컨트롤러들에 배치함으로써 샤드(Shard)들의 동기화 대역폭이 네트워크에 의해 제한되지 않도록 할 수 있는 효과가 있다. According to the leader selection method according to an embodiment of the present invention, by placing the shard leaders in the controllers in consideration of the network bandwidth, the synchronization bandwidth of the shards may not be limited by the network. There is.

본 발명의 실시 예에 따른 리더 선정 방법에 의할 경우, 소프트웨어 정의 네트워크에서의 빠른 컨트롤러 동기화가 가능하다.
According to the reader selection method according to an embodiment of the present invention, fast controller synchronization is possible in a software defined network.

본 발명의 상세한 설명에서 인용되는 도면을 보다 충분히 이해하기 위하여 각 도면의 상세한 설명이 제공된다.
도 1은 WAN 환경에서 Raft 컨센서스 알고리즘을 통한 SDN 컨트롤러들 간의 동기화를 설명하는 예시적인 도면이다.
도 2는 Raft 컨센서스 알고리즘 기반의 분산 SDN 구조를 설명하는 예시적인 도면이다.
도 3은 분산 SDN 환경에서 리더 선정 모듈을 통한 샤드 리더 선정 과정을 도시한다.
도 4는 컨트롤러들 간의 가용 네트워크 대역폭에 따른 컨트롤러 별 가용 동기화 대역폭 계산 예시를 나타낸다.
도 5는 리더 선정 모듈에 의해 수행되는 리더 선정 방법을 설명하기 위한 흐름도이다.
도 6는 리더 선정 모듈에 의해 수행되는 리더 선정의 동작 예시를 나타낸다.
The detailed description of each drawing is provided in order to provide a thorough understanding of the drawings cited in the detailed description of the invention.
1 is an exemplary diagram illustrating synchronization between SDN controllers via Raft consensus algorithm in a WAN environment.
2 is an exemplary diagram illustrating a distributed SDN structure based on the Raft consensus algorithm.
3 illustrates a shard leader selection process through a leader selection module in a distributed SDN environment.
4 shows an example of calculation of available synchronization bandwidth for each controller according to available network bandwidth between controllers.
5 is a flowchart for describing a leader selection method performed by the leader selection module.
6 shows an example of the operation of leader selection performed by the leader selection module.

본 명세서에 개시되어 있는 본 발명의 개념에 따른 실시 예들에 대해서 특정한 구조적 또는 기능적 설명은 단지 본 발명의 개념에 따른 실시 예들을 설명하기 위한 목적으로 예시된 것으로서, 본 발명의 개념에 따른 실시 예들은 다양한 형태들로 실시될 수 있으며 본 명세서에 설명된 실시 예들에 한정되지 않는다.Specific structural or functional descriptions of the embodiments according to the inventive concept disclosed herein are provided only for the purpose of describing the embodiments according to the inventive concept. It may be embodied in various forms and is not limited to the embodiments described herein.

본 발명의 개념에 따른 실시 예들은 다양한 변경들을 가할 수 있고 여러 가지 형태들을 가질 수 있으므로 실시 예들을 도면에 예시하고 본 명세서에서 상세하게 설명하고자 한다. 그러나 이는 본 발명의 개념에 따른 실시 예들을 특정한 개시 형태들에 대해 한정하려는 것이 아니며, 본 발명의 사상 및 기술 범위에 포함되는 모든 변경, 균등물, 또는 대체물을 포함한다.Embodiments according to the inventive concept may be variously modified and have various forms, so embodiments are illustrated in the drawings and described in detail herein. However, this is not intended to limit the embodiments in accordance with the concept of the invention to the specific forms disclosed, and includes all changes, equivalents, or substitutes included in the spirit and scope of the present invention.

제1 또는 제2 등의 용어는 다양한 구성 요소들을 설명하는데 사용될 수 있지만, 상기 구성 요소들은 상기 용어들에 의해 한정되어서는 안 된다. 상기 용어들은 하나의 구성 요소를 다른 구성 요소로부터 구별하는 목적으로만, 예컨대 본 발명의 개념에 따른 권리 범위로부터 벗어나지 않은 채, 제1 구성 요소는 제2 구성 요소로 명명될 수 있고 유사하게 제2 구성 요소는 제1 구성 요소로도 명명될 수 있다.Terms such as first or second may be used to describe various components, but the components should not be limited by the terms. The terms are used only for the purpose of distinguishing one component from another, for example without departing from the scope of the rights according to the inventive concept, and the first component may be called a second component and similarly the second component. The component may also be referred to as a first component.

어떤 구성 요소가 다른 구성 요소에 "연결되어" 있다거나 "접속되어" 있다고 언급된 때에는, 그 다른 구성 요소에 직접적으로 연결되어 있거나 또는 접속되어 있을 수도 있지만, 중간에 다른 구성 요소가 존재할 수도 있다고 이해되어야 할 것이다. 반면에, 어떤 구성 요소가 다른 구성 요소에 "직접 연결되어" 있다거나 "직접 접속되어" 있다고 언급된 때에는 중간에 다른 구성 요소가 존재하지 않는 것으로 이해되어야 할 것이다. 구성 요소들 간의 관계를 설명하는 다른 표현들, 즉 "~사이에"와 "바로 ~사이에" 또는 "~에 이웃하는"과 "~에 직접 이웃하는" 등도 마찬가지로 해석되어야 한다.When a component is said to be "connected" or "connected" to another component, it may be directly connected to or connected to that other component, but it may be understood that other components may exist in the middle. Should be. On the other hand, when a component is said to be "directly connected" or "directly connected" to another component, it should be understood that no other component exists in the middle. Other expressions describing the relationship between components, such as "between" and "immediately between" or "neighboring to" and "directly neighboring", should be interpreted as well.

본 명세서에서 사용한 용어는 단지 특정한 실시 예를 설명하기 위해 사용된 것으로서, 본 발명을 한정하려는 의도가 아니다. 단수의 표현은 문맥상 명백하게 다르게 뜻하지 않는 한, 복수의 표현을 포함한다. 본 명세서에서, "포함하다" 또는 "가지다" 등의 용어는 본 명세서에 기재된 특징, 숫자, 단계, 동작, 구성 요소, 부분품 또는 이들을 조합한 것이 존재함을 지정하려는 것이지, 하나 또는 그 이상의 다른 특징들이나 숫자, 단계, 동작, 구성 요소, 부분품 또는 이들을 조합한 것들의 존재 또는 부가 가능성을 미리 배제하지 않는 것으로 이해되어야 한다.The terminology used herein is for the purpose of describing particular example embodiments only and is not intended to be limiting of the invention. Singular expressions include plural expressions unless the context clearly indicates otherwise. In this specification, terms such as "comprise" or "have" are intended to indicate that there is a feature, number, step, action, component, part, or combination thereof described herein, but one or more other features. It is to be understood that the present invention does not exclude the possibility of the presence or the addition of numbers, steps, operations, components, parts, or combinations thereof.

다르게 정의되지 않는 한, 기술적이거나 과학적인 용어를 포함해서 여기서 사용되는 모든 용어들은 본 발명이 속하는 기술 분야에서 통상의 지식을 가진 자에 의해 일반적으로 이해되는 것과 동일한 의미를 가진다. 일반적으로 사용되는 사전에 정의되어 있는 것과 같은 용어들은 관련 기술의 문맥상 가지는 의미와 일치하는 의미를 갖는 것으로 해석되어야 하며, 본 명세서에서 명백하게 정의하지 않는 한, 이상적이거나 과도하게 형식적인 의미로 해석되지 않는다.
Unless defined otherwise, all terms used herein, including technical or scientific terms, have the same meaning as commonly understood by one of ordinary skill in the art. Terms such as those defined in the commonly used dictionaries should be construed as having meanings consistent with the meanings in the context of the related art, and are not construed in ideal or excessively formal meanings unless expressly defined herein. Do not.

우선, 본 발명에 대한 설명에 앞서, 본 발명의 배경이 되는 기술에 대해 설명하면 다음과 같다.First, prior to the description of the present invention, a description of the background technology of the present invention is as follows.

SDN(Software Defined Networking)에서는 네트워크의 제어 기능과 데이터 전달 기능이 서로 분리되며, 논리적으로 중앙 집중된 SDN 컨트롤러가 전체 네트워크 장비들 (예를 들어, 네트워크 스위치, 라우터 등)을 제어하게 된다. 최근 단일 SDN 컨트롤러의 확장성의 한계를 극복하고자 복제된 복수의 컨트롤러들로 구성된 분산 SDN 컨트롤러 구조가 제안되었다. 이때, 컨트롤러들 간의 일관성을 유지하기 위해 Raft 컨센서스 알고리즘(Raft Consensus Algorithm)을 사용할 수 있다.In Software Defined Networking (SDN), the network control and data delivery functions are separated from each other, and a logically centralized SDN controller controls the entire network equipment (eg, network switches, routers, etc.). Recently, in order to overcome the limitation of scalability of a single SDN controller, a distributed SDN controller structure including a plurality of replicated controllers has been proposed. At this time, a Raft Consensus Algorithm may be used to maintain consistency among the controllers.

분산 시스템에서는 다수의 노드(예를 들어 서버)들이 그룹을 형성하여 외부 클라이언트에게 서비스를 제공한다. 이때, 노드 장애 발생 시에도 서비스를 제공하기 위해서 모든 노드들이 같은 상태를 유지하여야 한다. 이를 위해 특정 노드의 상태 변경 시, 해당 변경이 다른 노드들의 상태에 반영되어야 한다. 즉, 노드들은 변경된 상태에 대한 합의를 이루어야 한다. 이때, 컨센서스 알고리즘이란 분산 시스템에서 노드들의 상태에 대한 합의를 달성시키기 위한 알고리즘이다.In a distributed system, multiple nodes (eg servers) form groups to provide services to external clients. At this time, all nodes should maintain the same state in order to provide services even in the event of a node failure. For this purpose, when changing the state of one node, the change should be reflected in the state of other nodes. That is, nodes must agree on the changed state. In this case, the consensus algorithm is an algorithm for achieving consensus on the state of nodes in a distributed system.

Raft 컨센서스 알고리즘에서는 RSM(Replicated State Machine) 구조를 가정한다. RSM 구조에선 복제된 다수의 서버들로 구성된 분산 시스템을 가정한다. 외부 클라이언트는 분산 시스템에게 Command들을 전송하고 분산 시스템은 이를 처리한 뒤 클라이언트에게 처리 완료를 알린다. RSM 구조에서는 외부 클라이언트가 RSM의 분산 구조를 모르는 상황을 가정하며 하나의 서버에게 Command들을 전송하는 상황만을 고려한다. 구체적으로, RSM 구조에서 각 서버는 컨센서스 모듈(Consensus Module), 로그(Log), 그리고 상태 머신(State Machine)으로 구성된다. Consensus Module은 클라이언트로부터 받은 Command들을 로컬 Log에 순서대로 저장한다. Consensus Module은 로컬 Log를 외부 서버들의 Log들로 먼저 복제 한 뒤, Log에 저장된 순서에 따라 로컬 State Machine에게 전달하여 해당 순서대로 처리되도록 한다. 여기서 Log 내 Command들이 State Machine에 의해 처리되면, 해당 Log는 Commit 되었다고 한다. Log를 Commit하기 이전에 먼저 복제를 수행하는 이유는 모든 State Machine들이 같은 Log를 유지하여 동일한 Command들을 동일한 순서대로 처리하도록 하기 위함이다. 여기서, Log들 간의 일관성을 보장하기 위한 알고리즘을 컨센서스 알고리즘이라 한다.The Raft consensus algorithm assumes a replicated state machine (RSM) structure. The RSM architecture assumes a distributed system consisting of multiple servers replicated. The external client sends commands to the distributed system, which then processes it and notifies the client of the completion. In the RSM architecture, it is assumed that the external client does not know the distributed structure of RSM and only considers the situation of sending commands to one server. Specifically, in the RSM structure, each server is composed of a consensus module, a log, and a state machine. The Consensus Module stores the commands received from the client in order in the local log. The Consensus Module first replicates the local log to the logs of the external servers, and then delivers it to the local state machine in the order stored in the log for processing in that order. Here, if the commands in the log are processed by the state machine, the log is said to be committed. The reason for duplicating first before committing the log is to make sure that all state machines maintain the same log and process the same commands in the same order. Here, the algorithm for guaranteeing consistency between logs is called a consensus algorithm.

Log 복제 과정은 다음과 같다. Consensus Module은 로컬 Log 내의 Command들이 로컬 State Machine에 의해 처리되기 이전에 먼저 외부 서버들의 Consensus Module들과 통신하여 로컬 Log를 외부 서버들의 Log로 복제한다. 외부 서버들의 Consensus Module들로부터 Log 복제가 완료되었다는 응답을 수신하면, Consensus Module은 로컬 Log에 저장된 Command들을 로컬 State Machine에 순서대로 처리시키고 처리가 완료되면 클라이언트에게 처리 완료를 알린다. 동시에 Consensus Module은 복제되었지만 아직 처리되지 않은 Command들을 처리하라는 메시지를 외부 서버들의 Consensus Module들에게 전송한다. 외부 서버들은 해당 메시지를 받고 각자의 State Machine을 통해 해당 Command들을 처리한다.The log replication process is as follows. The Consensus Module first communicates with the Consensus Modules of external servers before the commands in the local log are processed by the local state machine and replicates the local log to the logs of the external servers. When receiving the response that log replication is completed from Consensus Modules of external servers, the Consensus Module processes the commands stored in the local log in order to the local state machine and informs the client when the processing is completed. At the same time, the Consensus Module sends a message to the Consensus Modules of external servers to process commands that have been replicated but not yet processed. External servers receive the message and process the commands through their state machines.

Raft에서 노드(RSM 구조 설명에서의 서버)는 Leader(리더), Follower(팔로워), Candidate(후보자)의 세 가지 상태 중 하나의 상태를 갖는다. Raft 그룹에 참여하는 모든 노드들은 Follower 상태로 시작한다. 이 때, 다수의 노드들로 구성된 Raft 그룹은 하나의 Leader만을 가질 수 있으며, Raft 그룹에 속한 모든 노드들로의 Command들은 Leader를 통해서만 처리될 수 있다. 따라서 Leader 노드에 장애가 발생하면 해당 Raft 그룹 전체가 서비스 불능 상태가 된다. 이러한 상황에 대처하기 위해 Leader 노드는 주기적인 Heartbeat 메시지를 Follower 노드들에게 전송하여 자신의 생존을 알린다. Follower 노드는 Heartbeat을 받을 시 마다 초기화되는 Randomized Timeout 값을 유지한다. Leader로부터의 Heartbeat 메시지 수신에 대한 Timeout이 발생하면, 해당 Follower는 Leader에 장애가 발생했다고 판단하고 자신의 상태를 Candidate으로 전환한 뒤, 다른 노드들에게 투표요청 메시지(RequestVote)를 보낸다. 과반수의 표를 얻은 Candidate은 Leader가 된다.
In Raft, a node (a server in the RSM structure description) has one of three states: Leader, Follower, and Candidate. All nodes participating in the Raft group begin with a Follower state. At this time, a Raft group composed of multiple nodes can have only one Leader, and commands to all nodes in the Raft group can be processed only through the Leader. Therefore, if a leader node fails, the entire Raft group becomes out of service. To cope with this situation, the Leader node sends periodic Heartbeat messages to the Follower nodes to indicate its survival. Follower nodes maintain a Randomized Timeout value that is initialized each time they receive a heartbeat. When a timeout occurs for receiving a heartbeat message from a leader, the follower determines that the leader has failed, switches its status to Candidate, and sends a request request message to other nodes. Candidates with a majority of the votes become leaders.

이하, 본 명세서에 첨부된 도면들을 참조하여 본 발명의 실시 예들을 상세히 설명한다.
Hereinafter, embodiments of the present invention will be described in detail with reference to the accompanying drawings.

도 2는 분산 소프트웨어 정의 네트워크(Software Defined Network ; SDN) 컨트롤러 구조 예시를 나타낸다. 2 illustrates an example of a distributed software defined network (SDN) controller structure.

본 명세서에서 언급되는 "컨트롤러"는 플로우(트래픽 또는 패킷)의 흐름을 제어하기 위한 관련 구성 요소(예를 들면, 스위치, 라우터 등)를 제어하는 기능 요소(entity)를 의미하는 것으로, 물리적인 구현 형태나 구현 위치 등에 한정되지 않는다. 예컨대, 상기 컨트롤러는 ONF(Open Networking Foundation)나 IETF(Internet Engineering Task Force), ETSI(European Telecommunications Standards Institute) 및/또는 ITU-T(International Telecommunication Union - Telecommunication Standardization Sector) 등에서 정의하고 있는 컨트롤러 기능 요소(entity)를 의미할 수 있다.As used herein, the term "controller" refers to a functional entity that controls the relevant components (e.g., switches, routers, etc.) for controlling the flow of a flow (traffic or packet), and is a physical implementation. It is not limited to a form, an implementation position, etc. For example, the controller may be a controller functional element defined by the Open Networking Foundation (ONF), the Internet Engineering Task Force (IETF), the European Telecommunications Standards Institute (ETSI) and / or the International Telecommunication Union-Telecommunication Standardization Sector (ITU-T). entity).

컨트롤러의 네트워크 상태 데이터베이스 (NSDB: Network State Database) 및 어플리케이션들(즉, 네트워크 서비스)은 다수의 컨트롤러들로 복제되어 고 가용성 및 고 확장성을 지원한다. NSDB는 논리적인 데이터 파티션인 샤드(Shard)로 분할될 수 있으며, 도 2에서는 NSDB가 P1, P2, P3의 3-Shard로 분할이 되어있다.The controller's Network State Database (NSDB) and applications (ie network services) are replicated across multiple controllers to support high availability and high scalability. The NSDB may be divided into shards, which are logical data partitions. In FIG. 2, the NSDB is divided into 3-shards of P1, P2, and P3.

한편, 샤드(Shard)는 모든 컨트롤러들에게 복제된다. 즉, 모든 컨트롤러는 샤드 별 Replica를 유지한다. 샤드(Shard) x의 Replica가 컨트롤러 y에 위치한 경우, 해당 Replica는 Px.y로 표시되며, 도 1에서 컨트롤러 2는 P1.2 (즉, 컨트롤러 2에 위치한 샤드 1의 Replica)를 갖고 있음을 확인할 수 있다. 이때, Replica들 간의 데이터 일관성 유지를 위해 Raft 컨센서스 알고리즘이 사용된다.
On the other hand, shards are replicated to all controllers. That is, every controller maintains a shard-specific replica. If a replica of shard x is located on controller y, the replica is represented by Px.y, and in Figure 1 we see that controller 2 has P1.2 (that is, replica of shard 1 located on controller 2). Can be. At this time, Raft consensus algorithm is used to maintain data consistency between replicas.

도 3은 분산 SDN 환경에서 리더 선정 모듈(Leader Selection Module)을 통한 리더 선정 과정을 도시한다. 모든 컨트롤러는 내부 혹은 외부의 클라이언트 및 애플리케이션에게 컨트롤러들에 위치한 Replica들의 Leader를 선정할 수 있도록 하는 기능인 Make-Leader-Local RPC를 제공한다. 임의의 컨트롤러 내 Make-Leader-Local RPC는 Shard ID를 입력으로 받아 해당 샤드에 대한 컨트롤러 내 Replica를 Leader로 전환한다. 예를 들어, 도 1에서 샤드 2에 대한 리더쉽 (Leadership)을 P2.1에서 P2.2로 이동시키기 위해 컨트롤러 2에게 Make-Leader-Local RPC(Shard 2)를 전송한다. 본 발명의 일 실시예에 따른 리더 선정 모듈(Leader Selection Module)은 Make-Leader-Local RPC를 통해 컨트롤러들의 Leadership을 선정한다.3 illustrates a leader selection process through a leader selection module in a distributed SDN environment. All controllers provide Make-Leader-Local RPC, a feature that allows internal or external clients and applications to select leaders of replicas located in the controllers. The Make-Leader-Local RPC in any controller receives the Shard ID as an input and converts the replica in the controller for the shard to the Leader. For example, in FIG. 1, a Make-Leader-Local RPC (Shard 2) is transmitted to the controller 2 to move the leadership for shard 2 from P2.1 to P2.2. The leader selection module according to an embodiment of the present invention selects the leadership of the controllers through Make-Leader-Local RPC.

본 발명에 의한 리더 선정 모듈은 SDN 시스템에 포함되는 복수의 컨트롤러 중 적어도 하나 이상의 컨트롤러에 포함될 수 있으며, 리더 선정 결과는 복수의 컨트롤러들에 의해 공유된다.The leader selection module according to the present invention may be included in at least one controller among a plurality of controllers included in the SDN system, and the leader selection result is shared by the plurality of controllers.

실시 예에 따라, 리더 선정 모듈은 SDN 시스템에 포함된 복수의 컨트롤러들 중 상위 컨트롤러(또는 슈퍼 컨트롤러)에 포함될 수 있다. 즉, 계층적 구조를 갖는 SDN 시스템에 포함된 상기 상위 컨트롤러에 포함된 리더 선정 모듈에 의해 리더 선정이 수행된 후 수행 결과는 상기 상위 컨트롤러에 의해 하위 컨트롤러들 각각에게 제공될 수도 있다.According to an embodiment, the leader selection module may be included in an upper controller (or super controller) among a plurality of controllers included in the SDN system. That is, after leader selection is performed by the leader selection module included in the upper controller included in the SDN system having a hierarchical structure, the execution result may be provided to each of the lower controllers by the upper controller.

본 명세서에서 사용되는 '모듈'이라 함은 본 발명의 기술적 사상을 수행하기 위한 하드웨어 및 상기 하드웨어를 구동하기 위한 소프트웨어의 기능적, 구조적 결합을 의미할 수 있다. 예컨대, 상기 '-모듈'은 소정의 코드와 상기 소정의 코드가 수행되기 위한 하드웨어 리소스의 논리적인 단위를 의미할 수 있으며, 반드시 물리적으로 연결된 코드를 의미하거나 한 종류의 하드웨어를 의미하는 것은 아니다.
As used herein, the term 'module' may refer to a functional and structural combination of hardware for performing the technical idea of the present invention and software for driving the hardware. For example, the '-module' may mean a logical unit of a predetermined code and a hardware resource for performing the predetermined code, and does not necessarily mean a physically connected code or a kind of hardware.

한편, 데이터 접근 요청이 매우 빈번한 샤드(Shard)의 경우, 이에 따라 동기화 또한 빈번하게 발생하게 되고, 동기화 대역폭이 네트워크에 의해 제한되지 않게 하기 위해, 이러한 샤드(Shard)의 Leader는 다른 컨트롤러들로의 가용 네트워크 대역폭이 충분한 컨트롤러에 위치하여야 한다. 이를 위해, 리더 선정 모듈(Leader Selection Module)은 컨트롤러 별 가용 동기화 대역폭(ASBW: Available Synchronization Bandwidth) 및 샤드(Shard) 별 평균 데이터 접근 요청 정도에 따른 평균 요구 동기화 대역폭(RSBW: Required Synchronization Bandwidth)을 주기적으로 측정하고, 이를 기반으로 Leader를 선정한다.On the other hand, in the case of a shard having a very frequent data access request, synchronization also occurs frequently, so that the leader of the shard is transferred to other controllers so that the synchronization bandwidth is not limited by the network. The controller should be located on a controller with sufficient network bandwidth. To this end, the leader selection module periodically determines the available synchronization bandwidth (ASBW) for each controller and the required synchronization bandwidth (RSBW) according to the average data access request for each shard. It is measured by the method, and the leader is selected based on this.

구체적으로, C를 컨트롤러 집합이라고 할 때, 임의의 컨트롤러 c∈C에 대한 가용 동기화 대역폭(ASBW)은

Figure 112017128843682-pat00010
로 나타내고, 이는 해당 컨트롤러에서 다른 컨트롤러들로 단위시간당 전송할 수 있는 동기화 메시지들의 최대 양을 의미한다. Raft 컨센서스 알고리즘을 사용하는 임의의 컨트롤러 c에 대해,
Figure 112017128843682-pat00011
는 해당 컨트롤러에서 다른 컨트롤러들로의 가용 네트워크 대역폭들 값들 중, 높은 상위 절반의 값을 갖는 컨트롤러들 중에 가장 작은 가용 네트워크 대역폭 값으로 결정된다. 예를 들어, 5개의 컨트롤러들 중 하나의 컨트롤러 c1에서 다른 컨트롤러들 c2, c3 ,c4, c5로의 가용 네트워크 대역폭이 각각 40, 20, 50, 10 이라고 하면,
Figure 112017128843682-pat00012
은 가용 네트워크 대역폭이 높은 상위 2개의 컨트롤러인 c2, c4들 중 가장 작은 가용 네트워크 대역폭값을 갖는 c2의 가용 네트워크 대역폭인 40으로 결정된다. Specifically, when C is called a controller set, the available synchronization bandwidth (ASBW) for any controller c∈C is
Figure 112017128843682-pat00010
This represents the maximum amount of synchronization messages that can be transmitted per unit time from the controller to other controllers. For any controller c using the Raft consensus algorithm,
Figure 112017128843682-pat00011
Is determined as the smallest available network bandwidth value among the controllers with the highest upper half of the available network bandwidth values from that controller to other controllers. For example, if the available network bandwidth from one controller c1 of five controllers to the other controllers c2, c3, c4, c5 is 40, 20, 50, 10, respectively,
Figure 112017128843682-pat00012
Is determined to be 40, the available network bandwidth of c2 having the smallest available network bandwidth value among the top two controllers c2 and c4 having high available network bandwidth.

P를 샤드(Shard)들의 집합이라고 할 때, 임의의 샤드(Shard) p∈P에 대한 평균 요구 동기화 대역폭(RSBW)은

Figure 112017128843682-pat00013
로 나타내고, 이는 해당 샤드로의 평균적인 데이터 접근에 의해 발생하는 단위 시간당 평균 동기화 메시지들의 양을 의미한다. 즉, 데이터 접근이 잦은 샤드일수록, 해당 샤드의
Figure 112017128843682-pat00014
는 큰 값을 가지게 된다.When P is called a set of shards, the average required synchronization bandwidth (RSBW) for any shard p 드 P is
Figure 112017128843682-pat00013
This represents the average amount of synchronization messages per unit time generated by the average data access to the shard. In other words, the shard with more data access, the shard
Figure 112017128843682-pat00014
Has a large value.

한편, 임의의 컨트롤러 c가 자신의 가용 동기화 대역폭(

Figure 112017128843682-pat00015
) 중, 자신이 Leader로 동작하는 샤드들의 동기화 메시지들을 전송하는데 사용되는 대역폭을 제외한 나머지 대역폭을 한계 동기화 대역폭(Marginal Synchronization Bandwidth ; MSBW)로 정의한다. 임의의 컨트롤러 c에 대한 한계 동기화 대역폭(MSBW)은
Figure 112017128843682-pat00016
로 나타내고, 가용 동기화 대역폭(
Figure 112017128843682-pat00017
)에서 컨트롤러 c가 Leader로써 동작하는 모든 샤드들에 대한 평균 요구 동기화 대역폭(RSBW)의 합을 뺀 값으로 아래와 같이 계산한다.On the other hand, any controller c has its own available synchronization bandwidth (
Figure 112017128843682-pat00015
) Is defined as Marginal Synchronization Bandwidth (MSBW), except for the bandwidth used to transmit synchronization messages of shards acting as leaders. The limit synchronization bandwidth (MSBW) for any controller c is
Figure 112017128843682-pat00016
, The available sync bandwidth (
Figure 112017128843682-pat00017
) Is calculated by subtracting the sum of the average required synchronization bandwidths (RSBW) for all shards in which controller c operates as a leader.

Figure 112017128843682-pat00018
Figure 112017128843682-pat00018

여기서,

Figure 112017128843682-pat00019
는 샤드(Shard) p의 Leader와 컨트롤러 c간의 매핑 상태(위치)를 나타낸다. 즉, 임의의 샤드(Shard) p∈P 및 컨트롤러 c∈C에 대해,
Figure 112017128843682-pat00020
은 샤드(Shard) p의 Leader가 컨트롤러 c에 위치한 것을 나타내고,
Figure 112017128843682-pat00021
는 샤드(Shard) p의 Leader가 컨트롤러 c에 위치하지 않은 것을 나타낸다. here,
Figure 112017128843682-pat00019
Represents the mapping state (location) between the leader of the shard p and the controller c. That is, for any shard p∈P and controller c∈C,
Figure 112017128843682-pat00020
Indicates that the leader of shard p is located in the controller c,
Figure 112017128843682-pat00021
Indicates that the leader of shard p is not located in the controller c.

리더 선정 모듈(Leader Selection Module)의 목적은 모든 컨트롤러들에 대해 한계 동기화 대역폭(

Figure 112017128843682-pat00022
)이 0보다 음수가 되지 않도록 Leader를 선정하는 것이다. 즉, 리더 선정 모듈은 모든 컨트롤러들에 대해 컨트롤러의 한계 동기화 ㄷ대역폭(MSBW)이 0보다 작은 컨트롤러가 있는지 주기적으로 확인하고, 그러한 컨트롤러가 있을 경우, Leader 재선정을 통해 모든 컨트롤러들의 한계 동기화 대역폭(MSBW)이 0 이상이 되도록 한다.
The purpose of the Leader Selection Module is to provide a marginal synchronization bandwidth for all controllers.
Figure 112017128843682-pat00022
Leader is selected so that) is not negative than zero. That is, the leader selection module periodically checks for all controllers whether there is a controller whose limit synchronization bandwidth (MSBW) is less than 0, and if there is such a controller, the leader reselection module selects the limit synchronization bandwidth of all the controllers. MSBW) should be greater than or equal to zero.

도 5는 본 발명의 실시예에 따른 리더 선정 모듈 또는 리더 선정 모듈을 포함하는 컨트롤러에 의해 수행되는 리더 선정 방법을 설명하기 위한 흐름도이다.5 is a flowchart illustrating a leader selection method performed by a controller including a leader selection module or a leader selection module according to an embodiment of the present invention.

먼저 컨트롤러 집합 C, 샤드(Shard) 집합 P, 그리고 Leader 매핑 상태

Figure 112017128843682-pat00023
, 그리고 컨트롤러들의 가용 동기화 대역폭(ASBW)/평균 요구 동기화 대역폭(RSBW)/한계 동기화 대역폭(MSBW)을 측정하는 주기 T를 입력받는다(S100). First, controller set C, shard set P, and leader mapping state.
Figure 112017128843682-pat00023
And a period T for measuring the available synchronization bandwidth (ASBW) / average required synchronization bandwidth (RSBW) / limit synchronization bandwidth (MSBW) of the controllers (S100).

다음으로 주기 T마다

Figure 112017128843682-pat00024
Figure 112017128843682-pat00025
를 각각 모든 컨트롤러들 및 샤드(Shard)들에 대해 계산한다. 또한, 모든 컨트롤러들에 대해
Figure 112017128843682-pat00026
를 계산한다(S200).Next, every cycle T
Figure 112017128843682-pat00024
And
Figure 112017128843682-pat00025
Is calculated for all controllers and shards, respectively. Also, for all controllers
Figure 112017128843682-pat00026
To calculate (S200).

다음으로

Figure 112017128843682-pat00027
의 값이 음수인 컨트롤러 c가 존재하는지 확인한다(S300).
Figure 112017128843682-pat00028
의 값이 음수인 컨트롤러 c가 존재하지 않을 경우, T 시간이 지난 후 다시
Figure 112017128843682-pat00029
의 값이 음수인 컨트롤러 c가 존재하는지 확인한다. to the next
Figure 112017128843682-pat00027
Check whether the controller c having a negative value is present (S300).
Figure 112017128843682-pat00028
If no controller c with a negative value of c does not exist, retry after T time
Figure 112017128843682-pat00029
Check if there is a controller c with a negative value.

만일

Figure 112017128843682-pat00030
의 값이 음수인 컨트롤러 c가 존재할 경우, 해당 컨트롤러(즉,
Figure 112017128843682-pat00031
)가 Leader로 동작하는 샤드(Shard)들 중, RSBW가가 최소인 샤드(즉,
Figure 112017128843682-pat00032
)를 선택하고, 해당 샤드의 새로운 Leader로 선정되어도 한계 동기화 대역폭(MSBW)이 음수가 되지 않는 컨트롤러(즉,
Figure 112017128843682-pat00033
)를 선택한다(S400). if
Figure 112017128843682-pat00030
If a controller c with a negative value of c exists, that controller (that is,
Figure 112017128843682-pat00031
Among the shards where) acts as the leader, the shards with the smallest RSBW price (ie
Figure 112017128843682-pat00032
), The controller whose non-negative limit bandwidth (MSBW) is not negative even if it is selected as the new leader of the shard (i.e.
Figure 112017128843682-pat00033
Select (S400).

다음, 리더 선정 모듈은

Figure 112017128843682-pat00034
에게 Make-Leader-Local RPC(
Figure 112017128843682-pat00035
)를 전송하여
Figure 112017128843682-pat00036
의 Leadership을
Figure 112017128843682-pat00037
에서
Figure 112017128843682-pat00038
로 옮기고, 이에 맞게
Figure 112017128843682-pat00039
를 업데이트 한다(S500).Next, the leader selection module
Figure 112017128843682-pat00034
Make-Leader-Local RPC (
Figure 112017128843682-pat00035
) By sending
Figure 112017128843682-pat00036
Leadership
Figure 112017128843682-pat00037
in
Figure 112017128843682-pat00038
Move to
Figure 112017128843682-pat00039
Update the (S500).

이와 같이 Leadership을 옮기는 과정을 한계 동기화 대역폭(

Figure 112017128843682-pat00040
) 값이 음수인 컨트롤러가 존재하지 않을 때까지 반복한다.
This process of moving leadership is not limited to limit synchronization bandwidth (
Figure 112017128843682-pat00040
Repeat until no controller with negative value exists.

도 6은 리더 선정 모듈(또는 리더 선정 모듈을 포함하는 컨트롤러)에 의해 수행되는 리더 선정 방법의 동작 예시를 나타낸다. 3개의 컨트롤러 C1, C2, C3와 3개의 Shard P1, P2, P3로 구성된 분산 SDN 환경을 가정한다. 점선 기준 왼쪽 표들은 초기 상태의 가용 동기화 대역폭(ASBW), 평균 요구 동기화 대역폭(RSBW), 한계 동기화 대역폭(MSBW) 값들을 나타낸다. 도 6을 참조하면, C2의 한계 동기화 대역폭(MSBW)은 음수인 것을 확인할 수 있다. 이는 C2의 가용 동기화 대역폭(ASBW)이 15이지만, C2에 위치한 샤드 리더들(즉, P2)의 평균 요구 동기화 대역폭(RSBW)의 합이 30이기 때문에, C2의 한계 동기화 대역폭(MSBW)이 -15가 되는 것이다. 이러한 상황이 지속되면 P2에 대한 동기화가 지연되어 P2에 대한 데이터 접근 성능이 크게 저하될 수 있다. 6 illustrates an example of an operation of a leader selection method performed by a leader selection module (or a controller including a leader selection module). Assume a distributed SDN environment consisting of three controllers C1, C2, C3 and three Shards P1, P2, and P3. The left-hand table based on the dashed lines shows the available synchronization bandwidth (ASBW), the average required synchronization bandwidth (RSBW), and the limit synchronization bandwidth (MSBW) values of the initial state. Referring to FIG. 6, it can be seen that the limit synchronization bandwidth (MSBW) of C2 is negative. This is because the available synchronization bandwidth (ASBW) of C2 is 15, but since the sum of the average required synchronization bandwidth (RSBW) of the shard leaders (i.e., P2) located at C2 is 30, the limit synchronization bandwidth (MSBW) of C2 is -15. To be. If this situation persists, the synchronization for P2 may be delayed, resulting in a significant degradation in data access performance for P2.

본 발명의 일 실시예에 따른 샤드 리더 선정 방법은 한계 동기화 대역폭(MSBW)이 음수인 컨트롤러 C2를 파악하고, C2에 위치한 샤드 리더(Shard Leader)들 중 평균 요구 동기화 대역폭(RSBW)이 가장 작은 샤드를 찾는다. 한편, 도 6에서는 C2에 위치한 Shard Leader가 하나뿐이므로(죽, P2 Shard에 대한 Leader) 해당 Shard의 Leadership을 C2에서 다른 컨트롤러로 옮기도록 한다. 이때, P2의 평균 요구 동기화 대역폭(RSBW)인 30보다 더 큰 한계 동기화 대역폭(MSBW)을 가진 컨트롤러인 C3가 선택되고, 리더 선정 모듈은 C3에게 Make-Leader-Local RPC(P2)를 전송하여 C3가 P2의 Leadership을 갖도록 한다. 점선 기준 오른쪽 표들은 P2의 Leadership이 C2에서 C3로 이동한 후의 상태를 나타내며, 모든 컨트롤러들의 한계 동기화 대역폭(MSBW)들이 양수인 상태인 것을 확인할 수 있다.In the method of selecting a shard reader according to an embodiment of the present invention, a controller C2 having a negative limit synchronization bandwidth (MSBW) is identified, and a shard having the smallest average required synchronization bandwidth (RSBW) among shard leaders located at C2. Find it. Meanwhile, in FIG. 6, since there is only one shard leader located in C2 (porridge, leader for P2 shard), the leadership of the shard is moved from C2 to another controller. At this time, C3, a controller having a limit synchronization bandwidth (MSBW) greater than 30, which is the average required synchronization bandwidth (RSBW) of P2, is selected, and the reader selection module sends Make-Leader-Local RPC (P2) to C3 to C3. Have P2 leadership. The table on the right of the dotted line shows the state after P2's leadership has moved from C2 to C3, and it can be seen that the limit synchronization bandwidths (MSBW) of all controllers are positive.

본 발명은 도면에 도시된 실시 예를 참고로 설명되었으나 이는 예시적인 것에 불과하며, 본 기술 분야의 통상의 지식을 가진 자라면 이로부터 다양한 변형 및 균등한 타 실시 예가 가능하다는 점을 이해할 것이다. 따라서, 본 발명의 진정한 기술적 보호 범위는 첨부된 등록청구범위의 기술적 사상에 의해 정해져야 할 것이다.
Although the present invention has been described with reference to the embodiments illustrated in the drawings, this is merely exemplary, and it will be understood by those skilled in the art that various modifications and equivalent other embodiments are possible. Therefore, the true technical protection scope of the present invention will be defined by the technical spirit of the appended claims.

100 : 콘트롤러 110 : 샤드
200 : 리더 선정 모듈
100: controller 110: shard
200: reader selection module

Claims (5)

복수의 컨트롤러를 포함하는 소프트웨어 정의 네트워크 시스템에 포함된 리더 선정 모듈에 의해 수행되는 샤드(Shard) 리더(Leader)를 선정하는 방법에 있어서,
(a) 컨트롤러 집합 C, 샤드 집합 P, 리더 매핑 상태
Figure 112019057492001-pat00041
, 및 컨트롤러들의 가용 동기화 대역폭(ASBW)/평균 요구 동기화 대역폭(RSBW)/한계 동기화 대역폭(MSBW)을 측정하는 주기 T를 입력으로 하여, 상기 주기 T마다 모든 컨트롤러들에 대한 가용 동기화 대역폭(
Figure 112019057492001-pat00042
), 모든 샤드들에 대한 평균 요구 동기화 대역폭(
Figure 112019057492001-pat00043
), 및 모든 컨트롤러들에 대한 한계 동기화 대역폭(
Figure 112019057492001-pat00044
)을 계산하는 단계;
(b) 상기 한계 동기화 대역폭(
Figure 112019057492001-pat00045
)의 값이 음수인 컨트롤러가 존재하는지 확인하는 단계;
(c) 상기 한계 동기화 대역폭(
Figure 112019057492001-pat00046
)의 값이 음수인 컨트롤러(
Figure 112019057492001-pat00047
)가 존재하는 경우, 해당 컨트롤러(
Figure 112019057492001-pat00048
)가 리더로 동작하는 샤드들 중에서, 평균 요구 동기화 대역폭(RSBW)이 최소인 샤드(
Figure 112019057492001-pat00049
)를 선택하고, 해당 샤드(
Figure 112019057492001-pat00050
)의 새로운 리더로 선정되어도 한계 동기화 대역폭(MSBW)이 음수가 되지 않는 컨트롤러(
Figure 112019057492001-pat00051
)를 선택하는 단계; 및
(d) 상기 평균 요구 동기화 대역폭(RSBW)이 최소인 샤드(
Figure 112019057492001-pat00052
)의 리더쉽을 상기 한계 동기화 대역폭(
Figure 112019057492001-pat00053
)의 값이 음수인 컨트롤러(
Figure 112019057492001-pat00054
)에서 새로운 리더로 선택된 컨트롤러(
Figure 112019057492001-pat00055
)로 옮기고, 리더 매핑 상태
Figure 112019057492001-pat00056
를 업데이트하는 단계를 포함하고,
상기 단계 (d)는 상기 한계 동기화 대역폭(
Figure 112019057492001-pat00077
)의 값이 음수인 컨트롤러가 존재하지 않을 때까지 반복적으로 수행되는,
샤드 리더 선정 방법.
A method of selecting a shard leader performed by a leader selection module included in a software defined network system including a plurality of controllers, the method comprising:
(a) Controller set C, shard set P, leader mapping status
Figure 112019057492001-pat00041
And a period T for measuring the available synchronization bandwidth (ASBW) / average required synchronization bandwidth (RSBW) / limit synchronization bandwidth (MSBW) of the controllers as inputs, and the available synchronization bandwidth for all controllers at each period T (
Figure 112019057492001-pat00042
), Average required sync bandwidth for all shards (
Figure 112019057492001-pat00043
), And the limit synchronization bandwidth for all controllers (
Figure 112019057492001-pat00044
Calculating;
(b) the limit synchronization bandwidth (
Figure 112019057492001-pat00045
Checking whether there is a controller having a negative value;
(c) the limit synchronization bandwidth (
Figure 112019057492001-pat00046
Controller with negative value ()
Figure 112019057492001-pat00047
) If present, the controller (
Figure 112019057492001-pat00048
Among the shards that act as readers, the shards with the lowest average required synchronization bandwidth (RSBW) (
Figure 112019057492001-pat00049
), The corresponding shard (
Figure 112019057492001-pat00050
Controller with non-negative limit synchronization bandwidth (MSBW)
Figure 112019057492001-pat00051
Selecting); And
(d) the shard with the minimum required synchronization bandwidth (RSBW) (
Figure 112019057492001-pat00052
Leadership of the limit synchronization bandwidth (
Figure 112019057492001-pat00053
Controller with negative value ()
Figure 112019057492001-pat00054
Controller selected as the new leader ()
Figure 112019057492001-pat00055
), Leader mapping status
Figure 112019057492001-pat00056
Updating the;
Step (d) is the limit synchronization bandwidth (
Figure 112019057492001-pat00077
Is performed repeatedly until no controller with a negative value of) exists,
How to choose a shard leader.
제1항에 있어서,
상기 한계 동기화 대역폭(
Figure 112017128843682-pat00057
)의 값이 음수인 컨트롤러가 존재하지 않을 경우, T 시간이 지난 후 다시 한계 동기화 대역폭(
Figure 112017128843682-pat00058
)의 값이 음수인 컨트롤러가 존재하는지 확인하는 단계를 더 포함하는
샤드 리더 선정 방법.
The method of claim 1,
The limit synchronization bandwidth (
Figure 112017128843682-pat00057
If no controller with a negative value is present, the limit synchronization bandwidth (
Figure 112017128843682-pat00058
Checking whether a controller having a negative value of) exists.
How to choose a shard leader.
삭제delete 복수의 컨트롤러를 포함하는 소프트웨어 정의 네트워크 시스템에 포함된 리더 선정 모듈에 의해 수행되는 샤드(Shard) 리더(Leader)를 선정하는 방법에 있어서,
(a) 컨트롤러 집합 C, 샤드 집합 P, 리더 매핑 상태
Figure 112019057492001-pat00078
, 및 컨트롤러들의 가용 동기화 대역폭(ASBW)/평균 요구 동기화 대역폭(RSBW)/한계 동기화 대역폭(MSBW)을 측정하는 주기 T를 입력으로 하여, 상기 주기 T마다 모든 컨트롤러들에 대한 가용 동기화 대역폭(
Figure 112019057492001-pat00079
), 모든 샤드들에 대한 평균 요구 동기화 대역폭(
Figure 112019057492001-pat00080
), 및 모든 컨트롤러들에 대한 한계 동기화 대역폭(
Figure 112019057492001-pat00081
)을 계산하는 단계;
(b) 상기 한계 동기화 대역폭(
Figure 112019057492001-pat00082
)의 값이 음수인 컨트롤러가 존재하는지 확인하는 단계;
(c) 상기 한계 동기화 대역폭(
Figure 112019057492001-pat00083
)의 값이 음수인 컨트롤러(
Figure 112019057492001-pat00084
)가 존재하는 경우, 해당 컨트롤러(
Figure 112019057492001-pat00085
)가 리더로 동작하는 샤드들 중에서, 평균 요구 동기화 대역폭(RSBW)이 최소인 샤드(
Figure 112019057492001-pat00086
)를 선택하고, 해당 샤드(
Figure 112019057492001-pat00087
)의 새로운 리더로 선정되어도 한계 동기화 대역폭(MSBW)이 음수가 되지 않는 컨트롤러(
Figure 112019057492001-pat00088
)를 선택하는 단계; 및
(d) 상기 평균 요구 동기화 대역폭(RSBW)이 최소인 샤드(
Figure 112019057492001-pat00089
)의 리더쉽을 상기 한계 동기화 대역폭(
Figure 112019057492001-pat00090
)의 값이 음수인 컨트롤러(
Figure 112019057492001-pat00091
)에서 새로운 리더로 선택된 컨트롤러(
Figure 112019057492001-pat00092
)로 옮기고, 리더 매핑 상태
Figure 112019057492001-pat00093
를 업데이트하는 단계를 포함하고,
상기 한계 동기화 대역폭(
Figure 112019057492001-pat00062
)은 복수의 컨트롤러 중 어느 하나의 컨트롤러(c)의 가용 동기화 대역폭(
Figure 112019057492001-pat00063
)에서 해당 컨트롤러(c)가 리더로 동작하는 샤드들의 동기화 메시지들을 전송하는데 사용되는 대역폭을 제외한 나머지 대역폭으로, 수학식에 의해 정의되고,
상기 수학식은
Figure 112019057492001-pat00064
이고,
상기
Figure 112019057492001-pat00065
는 임의의 샤드(p∈P)의 리더와 컨트롤러(c∈C)의 매핑 상태를 나타내는 이진 변수이며,
Figure 112019057492001-pat00066
은 샤드(p)의 리더가 컨트롤러(c)에 위치한 것을 의미하고,
Figure 112019057492001-pat00067
는 샤드(p)의 리더가 컨트롤러(c)에 위치하지 않은 것을 의미하는,
샤드 리더 선정 방법.
A method of selecting a shard leader performed by a leader selection module included in a software defined network system including a plurality of controllers, the method comprising:
(a) Controller set C, shard set P, leader mapping status
Figure 112019057492001-pat00078
And a period T for measuring the available synchronization bandwidth (ASBW) / average required synchronization bandwidth (RSBW) / limit synchronization bandwidth (MSBW) of the controllers as inputs, and the available synchronization bandwidth for all controllers at each period T (
Figure 112019057492001-pat00079
), Average required sync bandwidth for all shards (
Figure 112019057492001-pat00080
), And the limit synchronization bandwidth for all controllers (
Figure 112019057492001-pat00081
Calculating;
(b) the limit synchronization bandwidth (
Figure 112019057492001-pat00082
Checking whether there is a controller having a negative value;
(c) the limit synchronization bandwidth (
Figure 112019057492001-pat00083
Controller with negative value ()
Figure 112019057492001-pat00084
) If present, the controller (
Figure 112019057492001-pat00085
Among the shards that act as readers, the shards with the lowest average required synchronization bandwidth (RSBW) (
Figure 112019057492001-pat00086
), The corresponding shard (
Figure 112019057492001-pat00087
Controller with non-negative limit synchronization bandwidth (MSBW)
Figure 112019057492001-pat00088
Selecting); And
(d) the shard with the minimum required synchronization bandwidth (RSBW) (
Figure 112019057492001-pat00089
Leadership of the limit synchronization bandwidth (
Figure 112019057492001-pat00090
Controller with negative value ()
Figure 112019057492001-pat00091
Controller selected as the new leader ()
Figure 112019057492001-pat00092
), Leader mapping status
Figure 112019057492001-pat00093
Updating the;
The limit synchronization bandwidth (
Figure 112019057492001-pat00062
) Is the available synchronization bandwidth (c) of any one of the plurality of controllers (c)
Figure 112019057492001-pat00063
) Is defined by the equation as the remaining bandwidth except the bandwidth used to transmit the synchronization messages of the shards that the controller (c) acts as a reader,
The equation is
Figure 112019057492001-pat00064
ego,
remind
Figure 112019057492001-pat00065
Is a binary variable representing the mapping state of the reader and controller (c∈C) of any shard (p∈P),
Figure 112019057492001-pat00066
Means that the leader of the shard (p) is located in the controller (c),
Figure 112019057492001-pat00067
Means that the leader of shard p is not located in controller c,
How to choose a shard leader.
복수의 컨트롤러를 포함하는 소프트웨어 정의 네트워크 시스템에 포함된 리더 선정 모듈에 의해 수행되는 샤드(Shard) 리더(Leader)를 선정하는 방법에 있어서,
(a) 컨트롤러 집합 C, 샤드 집합 P, 리더 매핑 상태
Figure 112019057492001-pat00094
, 및 컨트롤러들의 가용 동기화 대역폭(ASBW)/평균 요구 동기화 대역폭(RSBW)/한계 동기화 대역폭(MSBW)을 측정하는 주기 T를 입력으로 하여, 상기 주기 T마다 모든 컨트롤러들에 대한 가용 동기화 대역폭(
Figure 112019057492001-pat00095
), 모든 샤드들에 대한 평균 요구 동기화 대역폭(
Figure 112019057492001-pat00096
), 및 모든 컨트롤러들에 대한 한계 동기화 대역폭(
Figure 112019057492001-pat00097
)을 계산하는 단계;
(b) 상기 한계 동기화 대역폭(
Figure 112019057492001-pat00098
)의 값이 음수인 컨트롤러가 존재하는지 확인하는 단계;
(c) 상기 한계 동기화 대역폭(
Figure 112019057492001-pat00099
)의 값이 음수인 컨트롤러(
Figure 112019057492001-pat00100
)가 존재하는 경우, 해당 컨트롤러(
Figure 112019057492001-pat00101
)가 리더로 동작하는 샤드들 중에서, 평균 요구 동기화 대역폭(RSBW)이 최소인 샤드(
Figure 112019057492001-pat00102
)를 선택하고, 해당 샤드(
Figure 112019057492001-pat00103
)의 새로운 리더로 선정되어도 한계 동기화 대역폭(MSBW)이 음수가 되지 않는 컨트롤러(
Figure 112019057492001-pat00104
)를 선택하는 단계; 및
(d) 상기 평균 요구 동기화 대역폭(RSBW)이 최소인 샤드(
Figure 112019057492001-pat00105
)의 리더쉽을 상기 한계 동기화 대역폭(
Figure 112019057492001-pat00106
)의 값이 음수인 컨트롤러(
Figure 112019057492001-pat00107
)에서 새로운 리더로 선택된 컨트롤러(
Figure 112019057492001-pat00108
)로 옮기고, 리더 매핑 상태
Figure 112019057492001-pat00109
를 업데이트하는 단계를 포함하고,
새로운 리더로 선택된 컨트롤러(
Figure 112019057492001-pat00068
)로 리더쉽을 옮기는 단계는 상기 새로운 리더로 선택된 컨트롤러(
Figure 112019057492001-pat00069
)는 Make-Leader-Local RPC를 통해 리더쉽을 새로운 리더로 선택된 컨트롤러(
Figure 112019057492001-pat00070
)로 옮기는,
샤드 리더 선정 방법.
A method of selecting a shard leader performed by a leader selection module included in a software defined network system including a plurality of controllers, the method comprising:
(a) Controller set C, shard set P, leader mapping status
Figure 112019057492001-pat00094
And a period T for measuring the available synchronization bandwidth (ASBW) / average required synchronization bandwidth (RSBW) / limit synchronization bandwidth (MSBW) of the controllers as inputs, and the available synchronization bandwidth for all controllers at each period T (
Figure 112019057492001-pat00095
), Average required sync bandwidth for all shards (
Figure 112019057492001-pat00096
), And the limit synchronization bandwidth for all controllers (
Figure 112019057492001-pat00097
Calculating;
(b) the limit synchronization bandwidth (
Figure 112019057492001-pat00098
Checking whether there is a controller having a negative value;
(c) the limit synchronization bandwidth (
Figure 112019057492001-pat00099
Controller with negative value ()
Figure 112019057492001-pat00100
) If present, the controller (
Figure 112019057492001-pat00101
Among the shards that act as readers, the shards with the lowest average required synchronization bandwidth (RSBW) (
Figure 112019057492001-pat00102
), The corresponding shard (
Figure 112019057492001-pat00103
Controller with non-negative limit synchronization bandwidth (MSBW)
Figure 112019057492001-pat00104
Selecting); And
(d) the shard with the minimum required synchronization bandwidth (RSBW) (
Figure 112019057492001-pat00105
Leadership of the limit synchronization bandwidth (
Figure 112019057492001-pat00106
Controller with negative value ()
Figure 112019057492001-pat00107
Controller selected as the new leader ()
Figure 112019057492001-pat00108
), Leader mapping status
Figure 112019057492001-pat00109
Updating the;
The controller selected as the new leader (
Figure 112019057492001-pat00068
The step of transferring the leadership to the controller selected as the new leader (
Figure 112019057492001-pat00069
) Uses the Make-Leader-Local RPC to select which controller (
Figure 112019057492001-pat00070
Transferred to)
How to choose a shard leader.
KR1020170179284A 2017-12-26 2017-12-26 Method for selecting shard leader for fast synchronizations in software defined network KR102028651B1 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
KR1020170179284A KR102028651B1 (en) 2017-12-26 2017-12-26 Method for selecting shard leader for fast synchronizations in software defined network
PCT/KR2018/013444 WO2019132230A1 (en) 2017-12-26 2018-11-07 Method for selecting shard leader in software-defined network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020170179284A KR102028651B1 (en) 2017-12-26 2017-12-26 Method for selecting shard leader for fast synchronizations in software defined network

Publications (2)

Publication Number Publication Date
KR20190077804A KR20190077804A (en) 2019-07-04
KR102028651B1 true KR102028651B1 (en) 2019-10-04

Family

ID=67067676

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020170179284A KR102028651B1 (en) 2017-12-26 2017-12-26 Method for selecting shard leader for fast synchronizations in software defined network

Country Status (2)

Country Link
KR (1) KR102028651B1 (en)
WO (1) WO2019132230A1 (en)

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101247817B1 (en) * 2011-04-28 2013-03-26 한국기술교육대학교 산학협력단 Network selection system, network selection method and mobile system
US9569513B1 (en) 2013-09-10 2017-02-14 Amazon Technologies, Inc. Conditional master election in distributed databases
KR101650691B1 (en) * 2015-01-22 2016-08-24 아토리서치(주) Method and apparatus for operating distributed controllers of software defined network
KR101660849B1 (en) * 2015-03-06 2016-09-28 성균관대학교산학협력단 Autonomous control method in software defined network
JP2016219859A (en) 2015-05-14 2016-12-22 富士通株式会社 Controller, controller control device, and control method
US10091087B2 (en) 2015-07-20 2018-10-02 Cisco Technology, Inc. Methods and systems for load balancing based on data shard leader
WO2017186939A1 (en) * 2016-04-29 2017-11-02 Sanctum Networks Limited A data driven orchestrated network being responsive to environmental conditions using a light weight distributed controller

Also Published As

Publication number Publication date
WO2019132230A1 (en) 2019-07-04
KR20190077804A (en) 2019-07-04

Similar Documents

Publication Publication Date Title
US11894972B2 (en) System and method for data replication using a single master failover protocol
US11120044B2 (en) System and method for maintaining a master replica for reads and writes in a data store
US10929240B2 (en) System and method for adjusting membership of a data replication group
US9411873B2 (en) System and method for splitting a replicated data partition
US10248704B2 (en) System and method for log conflict detection and resolution in a data store
US9489434B1 (en) System and method for replication log branching avoidance using post-failover rejoin
KR101433816B1 (en) Server cluster
CN114301972B (en) Hierarchical deployment method and system for blockchain nodes based on cloud edge cooperation
US20190370376A1 (en) High-availability network device database synchronization
US10216593B2 (en) Distributed processing system for use in application migration
KR102028651B1 (en) Method for selecting shard leader for fast synchronizations in software defined network
Pashkov et al. On high availability distributed control plane for software-defined networks
JP6036848B2 (en) Information processing system
Oleiwi et al. Design and Implementation of Distributed Controller Clustering for Solving the Issue of Single Failure in SDN Networks.
Sagkriotis et al. Scalable data plane caching for kubernetes
US20230224243A1 (en) Highly-Available Cluster Leader Election in a Distributed Routing System
US20230283663A1 (en) Randomization of heartbeat communications among multiple partition groups
Lin et al. An optimized multi-Paxos protocol with centralized failover mechanism for cloud storage applications
JP6553125B2 (en) Database server, database management method, and program
CN117120993A (en) Geographically dispersed hybrid cloud clusters
LIGHTWEIGHT et al. Dept. of Computer Science, Kyonggi University, San 94-6 Iui-dong, Yeongtong-gu, Suwon-si Gyeonggi-do 443-760, Korea E-mail: jhahn (Okyonggi. ac. kr
Kamisinski et al. A Fault-Tolerant and Consistent SDN Controller

Legal Events

Date Code Title Description
A201 Request for examination
E902 Notification of reason for refusal
E701 Decision to grant or registration of patent right