Genetic Algorithm for Service Function Chaining in NFV

Advanced Science and Technology Letters Vol.129 (Mechanical Engineering 2016), pp.223-228 http://dx.doi.org/10.14257/astl.2016.129.44 Genetic Algorit...
Author: Jocelyn Flowers
3 downloads 2 Views 781KB Size
Advanced Science and Technology Letters Vol.129 (Mechanical Engineering 2016), pp.223-228 http://dx.doi.org/10.14257/astl.2016.129.44

Genetic Algorithm for Service Function Chaining in NFV Incheol Jo and Gu-In Kwon Department of Computer Science and Engineering, Inha University, 100 inharo, Nam-gu, Incheon 22212, Korea [email protected], [email protected]

Abstract. Network function virtualization (NFV) is a network architecture concept that virtualizes network functions into building blocks of software. NFV can reduce cost and increase operational efficiency by assigning a network function that specific equipment has to a virtualized general server. Such virtualized functions should be connected or chained together to create communication services. This technology is called a service function chaining (SFC) and SFC should be computed with consideration of two or more conditions such as bandwidth, memory, and CPU of virtualized resources and physical node. It is irrelevant to use conventional distance vector routing algorithm or link state routing algorithm to find the optimal path while maintaining multiple constraints. This paper suggests a method of finding an efficient routing path by using genetic algorithm with consideration of multiple conditions regarding this issue. Keyword: NFV, SDN, SFC, Genetic Algorithm

1

Introduction

NFV is a technology that is used to virtualize hardware-based network functions, such as firewall, IDS, IPS, and load distributor in the software form and it provides existing services in a more integrated and dynamic way [1]. SFC (Service Function Chaining) technology is one of critical technologies that support NFV. SFC is a technology of determining the order of virtualized network functions and processing traffic with one chain. With the application of the NFV/SFC technology, it is possible to design a network service suitable to user characteristics since the optimal path can be set up and changed dynamically to guarantee a high level of QoS (Quality of Service) [2][3][4]. This study analyzes the structure and operation of SFC and proposes the method of finding the approximately optimized service chain with the use of Genetic Algorithm (GA).

ISSN: 2287-1233 ASTL Copyright © 2016 SERSC

Advanced Science and Technology Letters Vol.129 (Mechanical Engineering 2016)

2

Structure and Operation of Service Function Chaining

Generally, when users access internet services, they use a variety of network systems, such as router, switch, firewall, Intrusion Prevention System (IPS), Intrusion Detection System (IDS), and Deep Packet Inspection (DPI). The systems provide services in different network layers. This kind of network services are called Service Function (SF) in the NFV environment. Service function chaining connects sequentially and executes service functions in the virtualized environment [5]. [Fig. 1] illustrates an example of the structure and operation of service function chaining. As shown in the figure, when traffic A is classified into SFC1 by traffic classifier and is processed in the order of FW→IDS→LB→DPI, there are a total of four paths to process the traffic. The paths are called SFP (Service Function Path). SFF (Service Function Forwarder) transmits packets from previous SF to next SF.

Fig. 1. Structure and operation of service function chaining

In the NFV environment, SFP should be designed with consideration of CPU and memory resources of virtualized SF and SFF. One SFC may include hundreds of or thousands of SFPs. Existing distance vector routing algorithm or link state routing algorithm takes into account a single resource, so that they are not proper in addressing the issue. Selecting the best SFP with multiple constrains is known as NP-hard problem. In this paper, we use the genetic algorithm to create a usable SFP and find an effective SFP with consideration of CPU and memory resources. The next section proposes the method of applying the issue of this study to genetic algorithm.

3

Genetic Algorithm

Genetic algorithm is a calculation model based on the evolution of nature world. As an optimization technique, it was developed by John Holland in 1975 [6]. The algorithm finds solutions in the processes of initial population generation, fitness evaluation, selection, crossover, and mutation. Each process is described below.

3.1

Initial population generation and fitness measurement

The initial population is generated in the same way of arranging SFPs that satisfy a given SFC. The most proper number of chromosomes in the initial population is 100-300 [7]. In this case,

224

Copyright © 2016 SERSC

Advanced Science and Technology Letters Vol.129 (Mechanical Engineering 2016)

one solution is represented as a chromosome. [Fig. 2] shows an example of the representation.

Fig. 2. Representation and fitness of the 23rd chromosome in the population

The method of initializing a population of solutions is divided into a random type and a heuristic type [7]. This study uses the latter type so as to satisfy SFC and make a population. Usually, a size of a population is determined in proportion to complexity of a problem. That is because the larger a population is, the better quality solution has. Nevertheless, a size of a population of solutions should be carefully decided with consideration of storage space and complexity of calculation. In addition, it is necessary to take into account the constraint of representing a solution in binary in order to establish an actual network environment. Once the initial population is generated, fitness of objects should be evaluated. This process is carried out to evaluate how proper objects are relevant to a problem. This study designed the fitness function 𝐹 as the total of CPU and memory amounts left after SF and SFF constituting SFP uses them. The function is written in formula (1), where the variable L, aimed at distributing traffic load, represents the number of the same SFFs used by SFP. For example, if SFP is set to SFF1→FW→SFF1→IDS→SFF1→DPI, all kinds of traffic are transmitted through SFF1. In this case, the probability of SFF1 load gets high. If the result of 𝐶𝑃𝑈𝑟𝑒𝑚𝑎𝑖𝑛 + 𝑀𝑒𝑚𝑟𝑒𝑚𝑎𝑖𝑛 is high, fitness gets high. As a result, selection probability is also high. Nevertheless, to solve the problem situation suggested above, the result is divided by the variable 𝐿 so as to adjust fitness. In this way, selection probability gets low, and thus the problem of load distribution can be solved. The meaning of each variable is presented in [Table 1]. If the result of the fitness function is large, the solution is considered to fit a relevant problem. 𝐹𝑖 =

𝐶𝑃𝑈𝑟𝑒𝑚𝑎𝑖𝑛 +𝑀𝑒𝑚𝑟𝑒𝑚𝑎𝑖𝑛 𝐿

(1)

𝑘

𝐶𝑃𝑈𝑟𝑒𝑚𝑎𝑖𝑛 = ∑(𝐶𝑃𝑈𝑟𝑒𝑚𝑎𝑖𝑛_ 𝑆𝐹𝐹𝑛 − 𝐶𝑝𝑢𝑟𝑒𝑞𝑢𝑒𝑠𝑡_ 𝑆𝐹𝑛 ) 𝑛=1 𝑘

𝑀𝑒𝑚𝑟𝑒𝑚𝑎𝑖𝑛 = ∑(𝑀𝑒𝑚𝑟𝑒𝑚𝑎𝑖𝑛_ 𝑆𝐹𝐹𝑛 − 𝑀𝑒𝑚𝑟𝑒𝑞𝑢𝑒𝑠𝑡_ 𝑆𝐹𝑛 ) 𝑛=1

Copyright © 2016 SERSC

225

Advanced Science and Technology Letters Vol.129 (Mechanical Engineering 2016)

Table 1. Meanings of variables

3.2

Variable

Meaning

𝑘

Number of SFs in use

𝑆𝐹𝑃𝑖

ith SFP

𝐶𝑃𝑈𝑟𝑒𝑚𝑎𝑖𝑛

The total remaining CPU amount of 𝑆𝐹𝑃𝑖

𝐶𝑃𝑈𝑟𝑒𝑚𝑎𝑖𝑛_ 𝑆𝐹𝐹𝑛

The remaining CPU amount of nth SFF in 𝑆𝐹𝑃𝑖

𝐶𝑃𝑈𝑟𝑒𝑞𝑢𝑒𝑠𝑡_ 𝑆𝐹𝑛

The requested CPU amount of nth SF in 𝑆𝐹𝑃𝑖

𝑀𝑒𝑚𝑟𝑒𝑚𝑎𝑖𝑛

The total remaining memory amount of 𝑆𝐹𝑃𝑖

𝑀𝑒𝑚𝑟𝑒𝑚𝑎𝑖𝑛_ 𝑆𝐹𝐹𝑛

The remaining memory amount of nth SFF in 𝑆𝐹𝑃𝑖

𝑀𝑒𝑚𝑟𝑒𝑞𝑢𝑒𝑠𝑡_ 𝑆𝐹𝑛

The remaining memory amount of nth SFF in 𝑆𝐹𝑃𝑖

Selection

This process is carried out to extract a parent gene from the generated population of solutions. For the process, roulette selection method is used. It is similar to the method of dividing a roulette into some zones and throwing a dart in the rotating roulette. Although it is impossible to know the zone that a dart hits, stochastically it is highly likely for the dart to hit a large zone. By adding all fitness values in the population of solutions, it is necessary to calculate a ratio of the area that each object accounts for. That is written in the below formula (2), where 𝑃𝑖 means the fitness ratio of 𝑖 th chromosome, 𝑃𝑖 is 𝑖 th chromosome’s fitness, and n is the number of chromosomes in the population of solutions. 𝐹𝑖

𝑃𝑖 = ∑𝑛

𝑖=1 𝐹𝑖

3.3

(2)

Crossover

Once a parent gene is selected by roulette selection method, the crossover process which makes a child gene is carried out so as to find a better solution. Crossover method includes one-point crossover, two-point crossover, and uniform crossover. We use two-point crossover to execute operations, where two crossover points are chosen randomly.

226

Copyright © 2016 SERSC

Advanced Science and Technology Letters Vol.129 (Mechanical Engineering 2016)

3.4

Mutation

Generically, a child of parents has the high probability of having dominant genes in accordance with dominant inheritance, but it can have recessive genes. The reverse situation is also the same. It means that the properties not involved in parent genes can be found. If the fitness of a child gene created by crossover operation falls in local optimum and does not increase any more, and if a constant value continues to be generated statistically, mutation operation can be applied. A mutation point can be selected randomly. The proposed algorithm mutates the instance of SFF or SF randomly. If fitness of the solution resulting from the mutation operation is in the range that is considered to be optimized, the algorithm exits. Mutation operation should be executed stochastically. If mutation operation is frequently executed, convergence falls and thus it takes long to execute. For the reason, it is better to execute mutation operation with a constant probability.

4

Conclusion

This study proposed the method of designing service function chain by using genetic algorithm which can search for solutions in cooperation of multiple objects. In other words, the algorithm searches for solutions through selection and crossover, so that they can find better solutions than simple parallel approach to search for solutions. According to the comparison with BackPropagation algorithm that is used often to find an optimal path in neural network, BackPropagation algorithm is similar to genetic algorithm in terms of fitness evaluation of each object, but it requires the calculation of a differential value of fitness function. This makes calculation more complicated. Therefore, BackPropagation algorithm is not proper in SFC. The genetic algorithm for service function chaining is meaningful in the point that it takes into account virtualized resources and represents them as a problem to solve. Acknowledgments. This work was supported by the National Research Foundation of Korea (NRF) grant funded by Korea government (MSIP) (no. 2015R1A2A2A01003501).

References 1. Chiosi, M: Network Functions Virtualization–Introductory White Paper. SDN and 2. OpenFlow World Congress. October 22–24, 2012, Darmstadt, Germany. 3. Mehraghdam, S., Matthias Keller, and Holger Karl. Specifying and placing chains of virtual network functions. In: Cloud Networking (CloudNet), 2014 IEEE 3rd International Conference on. IEEE, 2014. p. 7-13. 4. G. Lee, M. Kim, S. Choo, S. Pack, Y. Kim.: Optimal flow distribution in service function chaining. In The 10th International Conference on Future Internet (pp. 17-20). 2015 5. P. Quinn, A. Beliveau: Service Function Chaining (SFC) Architecture. 6. draft-quinn-sfc-arch-04 (work in progress), 2014.

Copyright © 2016 SERSC

227

Advanced Science and Technology Letters Vol.129 (Mechanical Engineering 2016)

7. John Holland, Adaptation in Natural and Artificial Systems: An Introductory Analysis with Applications to Biology, Control and Artificial Intelligence, U Michigan Press, 1992. 8. David E. Goldberg. Genetic algorithms in search optimization and machine learning. 9. Reading Menlo Park: Addison-Wesley, 1989.

228

Copyright © 2016 SERSC

Suggest Documents