# Head Node Selection Algorithm in Cloud Computing Data Center

Authors: Samira Kanwal; Zeshan Iqbal; Aun Irtaza; Muhammad Sajid; Sohaib Manzoor; Nouman Ali
Journal: Mathematical Problems in Engineering
 (2021)

---

## Abstract

Cloud computing provides multiple services such as computational services, data processing, and resource sharing through multiple nodes. These nodes collaborate for all prementioned services in the data center through the head/leader node. This head node is responsible for reliability, higher performance, latency, and deadlock handling and enables the user to access cost-effective computational services. However, the optimal head nodes’ selection is a challenging problem due to consideration of resources such as memory, CPU-MIPS, and bandwidth. The existing methods are monolithic, as they select the head nodes without taking the resources of the nodes. Still, there is a need for the candidate node which can be selected as a head node in case of head node failure. Therefore, in this paper, we proposed a technique, i.e., Head Node Selection Algorithm (HNSA), for optimal head node selection from the data center, which is based on the genetic algorithm (GA). In our proposed method, there are three modules, i.e., initial population generation, head node selection, and candidate node selection. In the first module, we generate the initial population by randomly mapping the task on different servers using a scheduling algorithm. After that, we compute the overall cost and the cost of each node based on resources. In the second module, the best optimal nodes are selected as a head node by applying the genetic operations such as crossover, mutation, and fitness function by considering the available resources. In the selected optimal nodes, one node is chosen as a head node and the other is considered as a candidate node. In the third module, the candidate node becomes the head node in the case of head node failure. The proposed method HNSA is compared against the state-of-the-art algorithms such as Bees Life Algorithm (BLA) and Heterogeneous Earliest Finished Time (HEFT). The simulation analysis shows that the proposed HNSA technique performs better in terms of execution time, memory utilization, service level sgreement (SLA) violation, and energy consumption.


---

## Body

## 1. Introduction

The recent advancements in Internet technologies and cloud computing have transformed the way data is processed. Cloud computing provides an environment including different resources, for example, memory, storage, and processing cores, for hosting applications and processing data according to the user requirement. It offers users flexible, pay-per-use, and on-demand scalable services hosted at a remote data center which can be accessed from anywhere and at anytime. The data center is comprised of a large number of networked servers and nodes that work together in a cluster to share resources. Cloud computing systems rely heavily on nodes coordination for the parallel execution of the tasks. A cluster leader node manages the task of communication and synchronization among the other nodes. Consequently, the selection of an optimal leader node is an ultimate requirement for preventing the network from becoming unstable. The leader election to choose the best node in a data center is a challenging problem because leaders are responsible for managing segregated data, sharing resources among nodes, and overcoming latency. Hence, communication between nodes is impossible without the leader/master nodes, so leader selection must be carefully considered. As the nodes are directly linked to the leader, the leader ensures that there will never be a deadlock among the network nodes and that tasks will be processed efficiently.For an effective leader election process in distributed networks and cloud computing environments, the research community has proposed several protocols [1–8] and algorithms (Biswas et al.) [9–16]. A bully algorithm is proposed in [17–20] for leader election which selects the leader nodes dynamically based on node ID criteria. In [9, 21, 22], the authors proposed a ring algorithm, in which each node shares its ID with all other nodes and keeps track of them in a database. Based on priority, the algorithm selects one node as a leader from this list. In [11, 23–25], node IDs are generated at random, and each node is assigned a priority number. After that, the node with the highest priority number is selected as the leader node. For leader election in [26–28], a message-passing strategy has been proposed. The comparison of these recent techniques that are based on ID and are randomly generated is shown in Table 1. However, these recent techniques failed to consider the maximum resources of the hosts due to increasing the complexity. These approaches introduce latency because of the higher message passing rate and slow response of the nodes. Some recent works related to leader election in IoT are presented in [29–31]. The major drawback of the above-mentioned methods is that the node’s resource profile is never considered. As a result, selecting the weaker leader node becomes equally likely. In high-load situations, the weak leader crashes, necessitating reelection of the leader, which slows down overall processing and delays task execution across network nodes. As a result, node resources must be considered during the leader election phase to ensure that task processing occurs efficiently and the network is stable.Table 1
Comparison of recent approaches.
PaperRandom IDPriority-basedHighest IDResources[32]NoNoYesNo[33]NoYesNoNo[9]NoNoNoYes[10]NoNoNoYes[11]NoYesNoNo[34]YesNoNoNo[35]NoNoYesNo[20]NoNoYesNo[22]NoNoYesNo[23]NoYesYesNo[36]NoYesYesNo[24]NoYesYesNo[37]NoYesYesNo[38]YesNoNoNo[39]YesNoNoNo[28]YesNoNoNoIn this paper, the Head Node Selection Algorithm (HNSA) is proposed to select a leader node in the cloud data center. The HNSA is based on a genetic algorithm (GA). The proposed HNSA selects the node as a head that has more resources than other nodes. The proposed algorithm selects the head node to ensure effective job execution, resource sharing, and communication among the nodes without any delay and in effective manner. Our proposed method gets the metainformation about jobs, VMs, and available hosts in the data centers and computes the fitness value of different hosts that are based on available host resources such as CPU-MIPS, throughput, bandwidth, and RAM. Using the metainformation, generate the initial population of chromosomes for the operation of GA. The chromosome comprises multiple jobs on different hosts, and it is taken as a gene. The chromosome length depends on the total number of jobs that are submitted in the cluster of data centers. To select the head node from each cluster, we locate that host which has the maximum fittest value against the fitness function. This fitness value is calculated after performing the GA operations, that is, crossover and mutation. In our proposed method, the crossover scheme used the swapping technique among the jobs on hosts, whereas, in mutation swapping, the one individual means to swap the job on the host. The fitness value depends on resources like CPU-MIPS, RAM, bandwidth, and throughput; these resources are the factors of our fitness function. This proposed approach is significant to utilize in a unified way to select the head node efficiently. It successfully selects the head node in the cluster for efficient job execution and reduces any delay among the nodes. The proposed technique also considers the sudden failure of the head node. When the head node is failed due to some reason like the host overloaded within the time interval, we select the candidate node as a head node for smooth communication and execution of jobs. So, our approach’s performance is efficient without suffering from any vulnerability like communication delay or failure of the host. To justify and validate the impact of our approach, we perform some experiment and compare our approach against some state-of-the-art algorithms. The following are the main contributions of this research:(i)
A novel method is proposed by using a genetic algorithm- (GA-) based Head Node Selection Algorithm (HNSA) for efficient data processing in the data center of cloud computing(ii)
The proposed model provides efficient data processing and resource sharing due to optimal head node and candidate node selection through the HNSA(iii)
Our proposed technique is efficient in SLA violation, execution time, energy consumption, and memory utilization as compared to state-of-the-art approachesThe remaining part of the paper is structured as follows: In Section2, the state of the art in head node selection is presented. In Section 3, the proposed GA-based head node selection methodology is explained. In Section 4, an experiment is conducted and the outcomes are presented; and, finally, we conclude our work in Section 5.


## 2. Related Work

In this section, we have reviewed the existing techniques related to frequent leader/head node selection. Ktari et al. [40] presented an agent-based selection approach employing dynamic trees. The main concern of the authors was to maintain a forest tree in which the root node was selected as the leader which was determined by the highest ID value. In the process of leader election, the ID value was created randomly without taking into account any other resources. Similarly, in [41], a method for leader selection based on the probabilistic investigation of traffic lights was presented.In [42], an approach, namely, old algorithm of the ring, was utilized, which employed the unidirectional interface to join all hubs or nodes. This technique was concerned to ensure that a job was successfully running on all nodes. In this paper, the system worked by randomly producing a distinctive priority number and a node was selected as the leader that had the highest priority. The failure of the leader hub caused the entire procedure to be performed again to find out the new leader. The leader hub selection approach needed about 2(n − 1) messages, communicated all over the network in which initially (n − 1) messages were transmitted to initiate the leader selection procedure. Finally, again (n − 1) messages were passed to nominate the novel leader. Later on, in [43], EffatParvar et al. had tried to enhance the traditional ring algorithm mentioned in [42] by considering the requirement relations together with the verification of numerous distributed protocols employed for leader nomination. The approach in [43] utilized the Temporal Ordering Specification Language (TOSL) along with Analysis of Distributed Processes (ADP).Several changes were introduced in the existing approach, that is, introduction of the bully algorithm [44], which was based on a tree structure and performed the comparison message complexity. Similarly, in [26], an extended form of bully leader selection method was presented in the environment of cloud computing in which the leader node selection was based on a Super Node (SN) [45] improving the leader nomination speed and message complexity was minimized to O(n2/k) to O(n2), in which k was showing the total nodes, while k was presenting the district. Moreover, the approach in [43] had the leader election complexity of O(k2n2), where n was presenting the total nodes and k was an upper bound value on the multiplicity of the labels. Similarly, in [46], a methodology for nominating the leader node was presented. The major motivation of this work was the selection of a single leader node; therefore, the failure of the leader caused the entire network to fail, which resulted in restarting the entire procedure. The approach in [47] had the election complexity of O(logn) and the message complexity in this [24] is O(k2n2).To deal with the problem of single leader election, two approaches have been presented in [9], which worked with nominating multiple leaders to avoid the risk of communication delays and minimized the latency rate. Three empirical techniques were employed in a cohesive way for calculating the proper status of leaders in a polynomial period. Another model for leader node selection was introduced in [48] based on employing the probabilistic grounded framework. The work had presented the improvements on the energy consumption and the consistency problem of channel communication. In literature, few approaches have been concerned with the leader selection in a peer-to-peer and distributed network [49, 50]. The method in [49] proposed an approach for the peer-to-peer network, while for distributed environment a technique was introduced in [51] employing software mediators to improve the speed of leader election procedure and minimize the energy consumption. Moreover, some protocols for fault-tolerance-based leader election in asynchronous distributed systems were presented in [52]. In [22, 53], two new mobility conscious methods for leader election were presented in the environment of ad hoc network systems. These techniques ensured that each connected node in the topology had been associated with a single leader. The approaches in [22, 54–56] have highly relied on a temporarily ordered routing technique called TORA.After performing the analysis of existing techniques, we have analyzed that most of techniques in literature for selecting a leader are highly dependent on a priority number or on a unique identifier that is usually randomly generated by a framework. These approaches do not take into account the network topology and availability of real-time resources before performing the leader node selection procedure [7, 57–60]. Moreover, with the increase in the complexity of the cloud computing environment, the leader election task becomes more challenging. To deal with the mentioned problem, several techniques have been presented; however, still these frameworks do not take into account all resources because of increased computational cost. We are presenting a novel approach for the leader/head node selection which is based on the idea of GA.


## 3. Proposed Research Model

The presented work comprises three main modules. The first is “initial population generation,” the second is “head node selection,” and the third is “candidate node selection” for efficient network performance. Consider a data centerDc with multiple servers called hosts H=h1,h2,h3,…,hi that are grouped in the form of C=C1,C2,C3,…,Cy and each host hi has Rm=Rhi.1,Rhi.2,Rhi.3,…,Rhi.m resources, for example, bandwidth, CPU, throughput, and memory. In the data center, jobs like J=j0,j1,j2,…,jk1,jk that contain multiple tasks to each cluster Cy are submitted. These jobs or tasks are randomly mapped on different hosts Hi that can make chromosomes sets like X=x1,x2,x3,…,xz, where xi=h1j1,h2j3,h3j2j4,…,hijk and hijk represents genes in a chromosome. Apply the genetic operations, that is, crossover and mutation, on the chromosomes that are generated by using the initial population P=p1,p2,p3,…,pq. Afterward, the fitness function is applied against each chromosome for evaluation. Correspondingly, the head nodes are selected from the evaluated chromosome with the highest value. The responsibility of head nodes is to allocate the jobs to each node in the cluster to effectively improve the efficiency load balancing of the network. The structural design of the HNSA is presented in Figure 1.Figure 1
Proposed model of HNSA.


### 3.1. Initial Population Generation

In our proposed algorithm, generate the initial population by mapping the jobs on different hostshi by using the scheduling algorithm. There are many ways to schedule the jobs between the intermediate nodes. In the proposed method, initial population formation is scheduled as follows: j1 on h2, j2 on h1,j3 onhi, and j4 on h3, as illustrated in Figure 2. There are several numbers of chromosomes in each set of the population represented as Pq=X1,X2,X3,...,Xz. Each set of chromosomes contains multiple genes, and the genes represent map jobs on different hosts. For example, the chromosome X1 is represented as X1=h1j2,h2j2,h1j3,…,hi−1jk−1,hijk.Figure 2
Initial population generation.


### 3.2. Head Node Selection

In this phase, we perform some genetic operations like crossover and mutation. In the crossover procedure, select two random population individuals called chromosomes. There are multiple crossover strategies; we use two cut-point techniques because we select two random points for cut by using the following equation:(1)β1,β2=rand2∗k−1+1,where the random number is generated by using rand2k1+1, for selecting the two cut-point positions β1 and β2. These two cut-point positions are selected in two sets of chromosomes which have the highest fitness values. When selecting two random cut points β1 and β2, perform the crossover operation. The crossover operation is performed from two new individuals that are called offspring in the population, as shown in Figure 3. In this way, better offspring are generated for the next population, and repeat this process till the best solution is achieved.Figure 3
Crossover.After the crossover, we perform the mutation process on the offspring that comes from the crossover operation. This mutation process is unary that applies to the single feature of offspring. During the mutation, process deviations are very minimal because generally a very small value is selected. In our method, the substitution process is used in mutation. So, we select any random position from the offspring and substitute this value as shown in Figure4.Figure 4
Mutation.Now, we evaluate the excellence of our proposed method by using the fitness functionFc. In Fc, we calculate the fittest value of all solutions through the following equation:(2)Fc=max∑i=0nfh,where fh is the fitness of each host which is calculated by using the following equation:(3)fh=Θ1Cα+Θ2Rα+Θ3Bα+Θ4Tα,where the system parameters like CPU-MIPS, memory, bandwidth, and throughput are considered. The values of these parameters are altered by considering SLA (Service Level Agreement) that works on the base of knapsack algorithm [61], shown in Table 2. The parameters with higher values of weight will impact the fitness value more as compared to the parameters with fewer values. In our proposed method, we used tournament selection, selecting the individual or the host which has the highest fitness value that is calculated by using the fitness function from a randomly generated population, which will be selected as a head node and candidate node.Table 2
Parameters.
NameAbbreviationWeights (Θ)Available CPU-MIPSCMα0.1Available RAMMα0.3Available bandwidthBdα0.2System throughputThα0.4The objective of our proposed method is to choose the leader node or head node with the higherα resources.


### 3.3. Selection of Candidate Node

After using GA operation, we will select a head node in each cluster. In this phase, choose a candidate node as a head node from each cluster C in a data center. The reason for choosing the candidate node as a head is because the head node is failed before the time interval and then the candidate becomes the head node. The candidate node is the backup of the head node and takes all responsibilities of the head node. The proposed technique will return two optimal hosts from each cluster, and we will choose one as a head node and the other as a candidate node. After each time interval, our system will run to optimize the head node and candidate node (Algorithm1).Algorithm 1: HNS.
Input: List of Jobs and ServersOutput: Head Node, Candidate Node(1)
Population = randomly generate;(2)
whilei = 1 to total population(3)
population list = randomly assign each job to a host(4)
end while(5)
calculate the cost ();(6)
if (time = = scheduling interval)(7)
for (! Stopping criteria)(8)
Perform Crossover Function();(9)
Perform Mutation Function();(10)
Calculate Fitness Function ();(11)
end for(12)
leader and candidate node = host with the maximal value from equation (1) in the first index of the population list is head node and the second is candidate(13)
if (Head Node Failed)(14)
candidate = host at the second index of the population list became a head node(15)
end if(16)
end if


## 3.1. Initial Population Generation

In our proposed algorithm, generate the initial population by mapping the jobs on different hostshi by using the scheduling algorithm. There are many ways to schedule the jobs between the intermediate nodes. In the proposed method, initial population formation is scheduled as follows: j1 on h2, j2 on h1,j3 onhi, and j4 on h3, as illustrated in Figure 2. There are several numbers of chromosomes in each set of the population represented as Pq=X1,X2,X3,...,Xz. Each set of chromosomes contains multiple genes, and the genes represent map jobs on different hosts. For example, the chromosome X1 is represented as X1=h1j2,h2j2,h1j3,…,hi−1jk−1,hijk.Figure 2
Initial population generation.


## 3.2. Head Node Selection

In this phase, we perform some genetic operations like crossover and mutation. In the crossover procedure, select two random population individuals called chromosomes. There are multiple crossover strategies; we use two cut-point techniques because we select two random points for cut by using the following equation:(1)β1,β2=rand2∗k−1+1,where the random number is generated by using rand2k1+1, for selecting the two cut-point positions β1 and β2. These two cut-point positions are selected in two sets of chromosomes which have the highest fitness values. When selecting two random cut points β1 and β2, perform the crossover operation. The crossover operation is performed from two new individuals that are called offspring in the population, as shown in Figure 3. In this way, better offspring are generated for the next population, and repeat this process till the best solution is achieved.Figure 3
Crossover.After the crossover, we perform the mutation process on the offspring that comes from the crossover operation. This mutation process is unary that applies to the single feature of offspring. During the mutation, process deviations are very minimal because generally a very small value is selected. In our method, the substitution process is used in mutation. So, we select any random position from the offspring and substitute this value as shown in Figure4.Figure 4
Mutation.Now, we evaluate the excellence of our proposed method by using the fitness functionFc. In Fc, we calculate the fittest value of all solutions through the following equation:(2)Fc=max∑i=0nfh,where fh is the fitness of each host which is calculated by using the following equation:(3)fh=Θ1Cα+Θ2Rα+Θ3Bα+Θ4Tα,where the system parameters like CPU-MIPS, memory, bandwidth, and throughput are considered. The values of these parameters are altered by considering SLA (Service Level Agreement) that works on the base of knapsack algorithm [61], shown in Table 2. The parameters with higher values of weight will impact the fitness value more as compared to the parameters with fewer values. In our proposed method, we used tournament selection, selecting the individual or the host which has the highest fitness value that is calculated by using the fitness function from a randomly generated population, which will be selected as a head node and candidate node.Table 2
Parameters.
NameAbbreviationWeights (Θ)Available CPU-MIPSCMα0.1Available RAMMα0.3Available bandwidthBdα0.2System throughputThα0.4The objective of our proposed method is to choose the leader node or head node with the higherα resources.


## 3.3. Selection of Candidate Node

After using GA operation, we will select a head node in each cluster. In this phase, choose a candidate node as a head node from each cluster C in a data center. The reason for choosing the candidate node as a head is because the head node is failed before the time interval and then the candidate becomes the head node. The candidate node is the backup of the head node and takes all responsibilities of the head node. The proposed technique will return two optimal hosts from each cluster, and we will choose one as a head node and the other as a candidate node. After each time interval, our system will run to optimize the head node and candidate node (Algorithm1).Algorithm 1: HNS.
Input: List of Jobs and ServersOutput: Head Node, Candidate Node(1)
Population = randomly generate;(2)
whilei = 1 to total population(3)
population list = randomly assign each job to a host(4)
end while(5)
calculate the cost ();(6)
if (time = = scheduling interval)(7)
for (! Stopping criteria)(8)
Perform Crossover Function();(9)
Perform Mutation Function();(10)
Calculate Fitness Function ();(11)
end for(12)
leader and candidate node = host with the maximal value from equation (1) in the first index of the population list is head node and the second is candidate(13)
if (Head Node Failed)(14)
candidate = host at the second index of the population list became a head node(15)
end if(16)
end if


## 4. Results and Discussion

A few experiments are performed to examine the performance and efficiency of the proposed method by comparing it against some state-of-the-art algorithms. The details of results and discussion are mentioned in the following subsections.


### 4.1. Experimental Setup

To evaluate the efficiency and performance of the proposed method, an extensive set of experiments are performed by using CloudSim Plus [20] simulator. The CloudSim simulator is based on CloudSim [21]; it is a framework for designing and simulating the data centers. CloudSim Plus simulates the more realistic scenarios because it is an extension of CloudSim. For experimental simulation, numerous sets of heterogeneous hosts/servers (MIPS range: 1000–4000) are used. The processor AMD-Ryzen 5 2500 is used for processing and the Python library is used to create the graph. The parameters execution time, energy consumption, SLA violation, and memory utilization are used to evaluate the performance of the proposed method. The time in which the host finishes the job is called execution time. Energy consumption is how much energy is utilized during the job execution. The memory utilization is how much MIPS are allocated to the host during the interval of time. When the job is not fully executed in the given time frame, the SLA violation occurs. To evaluate and analyze the efficiency of the proposed method, the graphs are generated by using input metrics as used in [62].


### 4.2. Experimental Analysis

In this section, we describe the particular facts about how to experiment. Experiments were used to equate the performance efficiency of the proposed method with some state-of-the-art algorithms. In all experiments, system parameters like RAM, CPU-MIPS, throughput, and bandwidth were used. The system parameter weightage is given according to the SLA, means the user’s requirements, as shown in Table3. The following experiments are performed as explained below.Table 3
System metrics weights.
MetricsΘCM0.5M0.3Bd0.1Th0.1


#### 4.2.1. Evaluation through Host Increment

In the first conducted experiment, the proposed method (HNSA) is compared with some state-of-the-art algorithms in terms of effectiveness. The performance evaluation is based on parameters like execution time, energy consumption, memory utilization, and SLA violation. In this experiment setup, the performance is evaluated by increasing the number of hosts/servers. However, a fixed number of tasks are used in the whole scenario. The host range is 20–100 along with the increment of 20, and the range of the tasks is fixed to 1000. In terms of execution time, the performance of the proposed HNSA is more efficient than those of state-of-the-art algorithms as shown in Figure5. During the performance analysis, the proposed HNSA takes minimum time to completely execute a job as compared to state-of-the-art algorithms like BLA and HEFT. Figures 6 and 7 show that the proposed algorithm also performs better in terms of SLA violation and memory utilization. The utilization of memory is improved because the number of hosts is increased and the number of tasks is fixed. The first conducted experiment’s results validate that the proposed HNSA had a better performance and improved the efficiency in terms of execution time, memory utilization, energy consumption, and SLA violation.Figure 5
Execution time.Figure 6
SLA violation.Figure 7
Memory utilization.


#### 4.2.2. Evaluation through the Task/Job Increment

The second conducted experiment was to calculate the performance efficiency of the proposed method with the same parameters. In this experiment, the number of tasks is incrementing; however, a fixed number of hosts is used. The tasks’ range is from 200 to 20,000 with an increment of 200 and the number of hosts is 50, which is fixed during the whole simulation. Figures8 and 9 show that the performance of the proposed method is efficient in terms of SLA violation and execution time. In this, the experimental results validate the performance efficiency based on parameters like execution time and SLA violation with the increment of tasks. State-of-the-art algorithms like BLA and HEFT had inefficient performance in terms of execution time and SLA violation as compared to HNSA. The results of this second experiment validate that the proposed algorithm takes less time to complete the job execution. Also, it validates that the HNSA reduces the SLA violation as compared to BLA and HEFT algorithms during the workflow execution.Figure 8
Execution time.Figure 9
SLA violation.


#### 4.2.3. Evaluation through Different WeightagesΘ

In this experiment, different weightages are given to parameters like CPU-MIPS, memory, bandwidth, and throughput to analyze the performance efficiency of HNSA against the BLA and HEFT algorithms. During this simulation, we used two different scenarios and gave different weightages to parameters according to the user requirement. In scenario 1, the range of hosts is fixed as 50 and the number of tasks/jobs is increasing by 1000. However, the weightages of resources like RAM, throughput, bandwidth, and CPU are different. The parameter weightages in scenario 1 are CPU 10%, RAM 60%, bandwidth 20%, and throughput 10%, as shown in Table4. Figure 10 validates that the performance of HNSA is better compared to state-of-the-art algorithms in terms of execution time and SLA violation. In scenario 2, the numbers of jobs and hosts are the same during the evaluation of the performance of HNSA against those of some state-of-the-art algorithms using all parameters. However, the weightages of all parameters are different: CPU-MIPS 10%, bandwidth 70%, RAM 10%, and throughput 10% as scenario 1, shown in Table 4. Figure 11 validates the simulation results in scenario 2, where the performance of the HNSA is more efficient compared to the BLA and HEFT algorithms. The second conducted experiment was to calculate the performance efficiency of the proposed method with the same parameters. In this experiment, the number of tasks is incrementing; however, the number of hosts used is fixed. The range of tasks is from 200 to 20,000 with an increment of 200 and the number of hosts is 50, which is fixed during the whole simulation. Figures 10 and 11 show that the proposed method’s performance is efficient in terms of SLA violation and execution time. In this, the experimental results validate the performance efficiency based on parameters like execution time and SLA violation with the increment of tasks. State-of-the-art algorithms like BLA and HEFT had inefficient performance in terms of execution time and SLA violation as compared to HNSA. The results of this second experiment validate that the proposed algorithm takes less time to complete the job execution. It also validates that the HNSA reduces the SLA violation as compared to BLA and HEFT algorithms during the workflow execution.Table 4
Θ of different assumptions.
MetricsAssumption 1Assumption 2CM0.10.1M0.60.1Bd0.20.7Th0.10.1Figure 10
Assumption 1.Figure 11
Assumption 2.


#### 4.2.4. Scheduling Comparison of Jobs

In this experiment, we analyze the performance of the HNSA in comparison to some state-of-the-art algorithms such as HEFT and BLA. In this simulation, ten tasks/jobs are randomly generated, and the length of each task/job is as follows: 61000, 62000, 63000, 64000, 65000, 66000, 67000, 68000, 69000, and 70000. Table5 shows the execution time of each job.Table 5
Execution time.
Jobs/hostsh0h1h2h3h4061.0040.0030.5024.4020.33162.0041.3331.0024.8020.67263.0042.0031.5025.2021.00364.0042.6732.0025.6021.33465.0043.3332.5026.0021.67566.0044.0033.0026.4022.00667.0044.6733.5026.8022.33768.0045.3334.0027.2022.67869.0046.0034.5027.6023.00970.0046.6735.0028.0023.33Figure12 shows the execution time with state-of-the-art algorithms and Figure 13 shows the execution time of tasks on different servers/hosts using the proposed algorithm. The HNSA maps the tasks on those hosts which efficiently meet the job/task requirement and are executed efficiently. Through HNSA, T9 runs on h2/S2 with minimum time as compared to BLA compiling T9 on S3, so HNSA efficiently executes the jobs as compared to BLA.Figure 12
Through BLAFigure 13
Through HNSA


#### 4.2.5. Energy Consumption with the Increment of Tasks and Hosts

In this simulation, the energy consumption is evaluated with two different scenarios. In the first scenario, energy consumption is calculated through the increment of the hosts, and in the second scenario, it is calculated through increment of the number of jobs. Figures14 and 15 show the energy consumption of HNSA and state-of-the-art algorithms in kw/h of each job to be executed. The experiment results of this first scenario show that the HNSA reduces the energy consumption due to efficient host uses for job execution. The optimized resources of the efficient host are used to execute the job in minimum time and other servers/hosts turn off to save energy. So, the HNSA algorithm uses optimized hosts to utilize the maximum resources and turn off the unused hosts and map the tasks/jobs on available optimal hosts.Figure 14
Through hosts.Figure 15
Through tasks.


## 4.1. Experimental Setup

To evaluate the efficiency and performance of the proposed method, an extensive set of experiments are performed by using CloudSim Plus [20] simulator. The CloudSim simulator is based on CloudSim [21]; it is a framework for designing and simulating the data centers. CloudSim Plus simulates the more realistic scenarios because it is an extension of CloudSim. For experimental simulation, numerous sets of heterogeneous hosts/servers (MIPS range: 1000–4000) are used. The processor AMD-Ryzen 5 2500 is used for processing and the Python library is used to create the graph. The parameters execution time, energy consumption, SLA violation, and memory utilization are used to evaluate the performance of the proposed method. The time in which the host finishes the job is called execution time. Energy consumption is how much energy is utilized during the job execution. The memory utilization is how much MIPS are allocated to the host during the interval of time. When the job is not fully executed in the given time frame, the SLA violation occurs. To evaluate and analyze the efficiency of the proposed method, the graphs are generated by using input metrics as used in [62].


## 4.2. Experimental Analysis

In this section, we describe the particular facts about how to experiment. Experiments were used to equate the performance efficiency of the proposed method with some state-of-the-art algorithms. In all experiments, system parameters like RAM, CPU-MIPS, throughput, and bandwidth were used. The system parameter weightage is given according to the SLA, means the user’s requirements, as shown in Table3. The following experiments are performed as explained below.Table 3
System metrics weights.
MetricsΘCM0.5M0.3Bd0.1Th0.1


### 4.2.1. Evaluation through Host Increment

In the first conducted experiment, the proposed method (HNSA) is compared with some state-of-the-art algorithms in terms of effectiveness. The performance evaluation is based on parameters like execution time, energy consumption, memory utilization, and SLA violation. In this experiment setup, the performance is evaluated by increasing the number of hosts/servers. However, a fixed number of tasks are used in the whole scenario. The host range is 20–100 along with the increment of 20, and the range of the tasks is fixed to 1000. In terms of execution time, the performance of the proposed HNSA is more efficient than those of state-of-the-art algorithms as shown in Figure5. During the performance analysis, the proposed HNSA takes minimum time to completely execute a job as compared to state-of-the-art algorithms like BLA and HEFT. Figures 6 and 7 show that the proposed algorithm also performs better in terms of SLA violation and memory utilization. The utilization of memory is improved because the number of hosts is increased and the number of tasks is fixed. The first conducted experiment’s results validate that the proposed HNSA had a better performance and improved the efficiency in terms of execution time, memory utilization, energy consumption, and SLA violation.Figure 5
Execution time.Figure 6
SLA violation.Figure 7
Memory utilization.


### 4.2.2. Evaluation through the Task/Job Increment

The second conducted experiment was to calculate the performance efficiency of the proposed method with the same parameters. In this experiment, the number of tasks is incrementing; however, a fixed number of hosts is used. The tasks’ range is from 200 to 20,000 with an increment of 200 and the number of hosts is 50, which is fixed during the whole simulation. Figures8 and 9 show that the performance of the proposed method is efficient in terms of SLA violation and execution time. In this, the experimental results validate the performance efficiency based on parameters like execution time and SLA violation with the increment of tasks. State-of-the-art algorithms like BLA and HEFT had inefficient performance in terms of execution time and SLA violation as compared to HNSA. The results of this second experiment validate that the proposed algorithm takes less time to complete the job execution. Also, it validates that the HNSA reduces the SLA violation as compared to BLA and HEFT algorithms during the workflow execution.Figure 8
Execution time.Figure 9
SLA violation.


### 4.2.3. Evaluation through Different WeightagesΘ

In this experiment, different weightages are given to parameters like CPU-MIPS, memory, bandwidth, and throughput to analyze the performance efficiency of HNSA against the BLA and HEFT algorithms. During this simulation, we used two different scenarios and gave different weightages to parameters according to the user requirement. In scenario 1, the range of hosts is fixed as 50 and the number of tasks/jobs is increasing by 1000. However, the weightages of resources like RAM, throughput, bandwidth, and CPU are different. The parameter weightages in scenario 1 are CPU 10%, RAM 60%, bandwidth 20%, and throughput 10%, as shown in Table4. Figure 10 validates that the performance of HNSA is better compared to state-of-the-art algorithms in terms of execution time and SLA violation. In scenario 2, the numbers of jobs and hosts are the same during the evaluation of the performance of HNSA against those of some state-of-the-art algorithms using all parameters. However, the weightages of all parameters are different: CPU-MIPS 10%, bandwidth 70%, RAM 10%, and throughput 10% as scenario 1, shown in Table 4. Figure 11 validates the simulation results in scenario 2, where the performance of the HNSA is more efficient compared to the BLA and HEFT algorithms. The second conducted experiment was to calculate the performance efficiency of the proposed method with the same parameters. In this experiment, the number of tasks is incrementing; however, the number of hosts used is fixed. The range of tasks is from 200 to 20,000 with an increment of 200 and the number of hosts is 50, which is fixed during the whole simulation. Figures 10 and 11 show that the proposed method’s performance is efficient in terms of SLA violation and execution time. In this, the experimental results validate the performance efficiency based on parameters like execution time and SLA violation with the increment of tasks. State-of-the-art algorithms like BLA and HEFT had inefficient performance in terms of execution time and SLA violation as compared to HNSA. The results of this second experiment validate that the proposed algorithm takes less time to complete the job execution. It also validates that the HNSA reduces the SLA violation as compared to BLA and HEFT algorithms during the workflow execution.Table 4
Θ of different assumptions.
MetricsAssumption 1Assumption 2CM0.10.1M0.60.1Bd0.20.7Th0.10.1Figure 10
Assumption 1.Figure 11
Assumption 2.


### 4.2.4. Scheduling Comparison of Jobs

In this experiment, we analyze the performance of the HNSA in comparison to some state-of-the-art algorithms such as HEFT and BLA. In this simulation, ten tasks/jobs are randomly generated, and the length of each task/job is as follows: 61000, 62000, 63000, 64000, 65000, 66000, 67000, 68000, 69000, and 70000. Table5 shows the execution time of each job.Table 5
Execution time.
Jobs/hostsh0h1h2h3h4061.0040.0030.5024.4020.33162.0041.3331.0024.8020.67263.0042.0031.5025.2021.00364.0042.6732.0025.6021.33465.0043.3332.5026.0021.67566.0044.0033.0026.4022.00667.0044.6733.5026.8022.33768.0045.3334.0027.2022.67869.0046.0034.5027.6023.00970.0046.6735.0028.0023.33Figure12 shows the execution time with state-of-the-art algorithms and Figure 13 shows the execution time of tasks on different servers/hosts using the proposed algorithm. The HNSA maps the tasks on those hosts which efficiently meet the job/task requirement and are executed efficiently. Through HNSA, T9 runs on h2/S2 with minimum time as compared to BLA compiling T9 on S3, so HNSA efficiently executes the jobs as compared to BLA.Figure 12
Through BLAFigure 13
Through HNSA


### 4.2.5. Energy Consumption with the Increment of Tasks and Hosts

In this simulation, the energy consumption is evaluated with two different scenarios. In the first scenario, energy consumption is calculated through the increment of the hosts, and in the second scenario, it is calculated through increment of the number of jobs. Figures14 and 15 show the energy consumption of HNSA and state-of-the-art algorithms in kw/h of each job to be executed. The experiment results of this first scenario show that the HNSA reduces the energy consumption due to efficient host uses for job execution. The optimized resources of the efficient host are used to execute the job in minimum time and other servers/hosts turn off to save energy. So, the HNSA algorithm uses optimized hosts to utilize the maximum resources and turn off the unused hosts and map the tasks/jobs on available optimal hosts.Figure 14
Through hosts.Figure 15
Through tasks.


## 4.2.1. Evaluation through Host Increment

In the first conducted experiment, the proposed method (HNSA) is compared with some state-of-the-art algorithms in terms of effectiveness. The performance evaluation is based on parameters like execution time, energy consumption, memory utilization, and SLA violation. In this experiment setup, the performance is evaluated by increasing the number of hosts/servers. However, a fixed number of tasks are used in the whole scenario. The host range is 20–100 along with the increment of 20, and the range of the tasks is fixed to 1000. In terms of execution time, the performance of the proposed HNSA is more efficient than those of state-of-the-art algorithms as shown in Figure5. During the performance analysis, the proposed HNSA takes minimum time to completely execute a job as compared to state-of-the-art algorithms like BLA and HEFT. Figures 6 and 7 show that the proposed algorithm also performs better in terms of SLA violation and memory utilization. The utilization of memory is improved because the number of hosts is increased and the number of tasks is fixed. The first conducted experiment’s results validate that the proposed HNSA had a better performance and improved the efficiency in terms of execution time, memory utilization, energy consumption, and SLA violation.Figure 5
Execution time.Figure 6
SLA violation.Figure 7
Memory utilization.


## 4.2.2. Evaluation through the Task/Job Increment

The second conducted experiment was to calculate the performance efficiency of the proposed method with the same parameters. In this experiment, the number of tasks is incrementing; however, a fixed number of hosts is used. The tasks’ range is from 200 to 20,000 with an increment of 200 and the number of hosts is 50, which is fixed during the whole simulation. Figures8 and 9 show that the performance of the proposed method is efficient in terms of SLA violation and execution time. In this, the experimental results validate the performance efficiency based on parameters like execution time and SLA violation with the increment of tasks. State-of-the-art algorithms like BLA and HEFT had inefficient performance in terms of execution time and SLA violation as compared to HNSA. The results of this second experiment validate that the proposed algorithm takes less time to complete the job execution. Also, it validates that the HNSA reduces the SLA violation as compared to BLA and HEFT algorithms during the workflow execution.Figure 8
Execution time.Figure 9
SLA violation.


## 4.2.3. Evaluation through Different WeightagesΘ

In this experiment, different weightages are given to parameters like CPU-MIPS, memory, bandwidth, and throughput to analyze the performance efficiency of HNSA against the BLA and HEFT algorithms. During this simulation, we used two different scenarios and gave different weightages to parameters according to the user requirement. In scenario 1, the range of hosts is fixed as 50 and the number of tasks/jobs is increasing by 1000. However, the weightages of resources like RAM, throughput, bandwidth, and CPU are different. The parameter weightages in scenario 1 are CPU 10%, RAM 60%, bandwidth 20%, and throughput 10%, as shown in Table4. Figure 10 validates that the performance of HNSA is better compared to state-of-the-art algorithms in terms of execution time and SLA violation. In scenario 2, the numbers of jobs and hosts are the same during the evaluation of the performance of HNSA against those of some state-of-the-art algorithms using all parameters. However, the weightages of all parameters are different: CPU-MIPS 10%, bandwidth 70%, RAM 10%, and throughput 10% as scenario 1, shown in Table 4. Figure 11 validates the simulation results in scenario 2, where the performance of the HNSA is more efficient compared to the BLA and HEFT algorithms. The second conducted experiment was to calculate the performance efficiency of the proposed method with the same parameters. In this experiment, the number of tasks is incrementing; however, the number of hosts used is fixed. The range of tasks is from 200 to 20,000 with an increment of 200 and the number of hosts is 50, which is fixed during the whole simulation. Figures 10 and 11 show that the proposed method’s performance is efficient in terms of SLA violation and execution time. In this, the experimental results validate the performance efficiency based on parameters like execution time and SLA violation with the increment of tasks. State-of-the-art algorithms like BLA and HEFT had inefficient performance in terms of execution time and SLA violation as compared to HNSA. The results of this second experiment validate that the proposed algorithm takes less time to complete the job execution. It also validates that the HNSA reduces the SLA violation as compared to BLA and HEFT algorithms during the workflow execution.Table 4
Θ of different assumptions.
MetricsAssumption 1Assumption 2CM0.10.1M0.60.1Bd0.20.7Th0.10.1Figure 10
Assumption 1.Figure 11
Assumption 2.


## 4.2.4. Scheduling Comparison of Jobs

In this experiment, we analyze the performance of the HNSA in comparison to some state-of-the-art algorithms such as HEFT and BLA. In this simulation, ten tasks/jobs are randomly generated, and the length of each task/job is as follows: 61000, 62000, 63000, 64000, 65000, 66000, 67000, 68000, 69000, and 70000. Table5 shows the execution time of each job.Table 5
Execution time.
Jobs/hostsh0h1h2h3h4061.0040.0030.5024.4020.33162.0041.3331.0024.8020.67263.0042.0031.5025.2021.00364.0042.6732.0025.6021.33465.0043.3332.5026.0021.67566.0044.0033.0026.4022.00667.0044.6733.5026.8022.33768.0045.3334.0027.2022.67869.0046.0034.5027.6023.00970.0046.6735.0028.0023.33Figure12 shows the execution time with state-of-the-art algorithms and Figure 13 shows the execution time of tasks on different servers/hosts using the proposed algorithm. The HNSA maps the tasks on those hosts which efficiently meet the job/task requirement and are executed efficiently. Through HNSA, T9 runs on h2/S2 with minimum time as compared to BLA compiling T9 on S3, so HNSA efficiently executes the jobs as compared to BLA.Figure 12
Through BLAFigure 13
Through HNSA


## 4.2.5. Energy Consumption with the Increment of Tasks and Hosts

In this simulation, the energy consumption is evaluated with two different scenarios. In the first scenario, energy consumption is calculated through the increment of the hosts, and in the second scenario, it is calculated through increment of the number of jobs. Figures14 and 15 show the energy consumption of HNSA and state-of-the-art algorithms in kw/h of each job to be executed. The experiment results of this first scenario show that the HNSA reduces the energy consumption due to efficient host uses for job execution. The optimized resources of the efficient host are used to execute the job in minimum time and other servers/hosts turn off to save energy. So, the HNSA algorithm uses optimized hosts to utilize the maximum resources and turn off the unused hosts and map the tasks/jobs on available optimal hosts.Figure 14
Through hosts.Figure 15
Through tasks.


## 5. Conclusion

In our methodology, we focused on the problem of the head node selection in the cloud data center. In the data center, the leader node is to ensure efficient execution of the task/jobs and deliver the well-organized services to the users according to their requirements. So, the selection of a head/leader node is a challenging task. However, in literature, most of the techniques are proposed to overcome the issues of head node selection. Still, there is a problem with all proposed techniques because these techniques failed to consider the resources of the host/server. So, we proposed an optimized algorithm called the HNSA, inspired by the processes of the genetic algorithm. Our proposed algorithm is based on a random population approach, which combined the behaviors of individual mean jobs on hosts. Through the HNSA, select the head node and candidate node based on available resources. The reason for the candidate node selection is that if the head node is failed within the time interval, then the candidate node becomes head node without long delay. To validate the performance efficiency and reliability of the proposed HNSA, we performed some simulations and compared these results against those of some state-of-the-art algorithms. The performance evaluation parameters are execution time, SLA violation, memory utilization, and energy consumption. Our results validate that our proposed HNSA is more efficient compared to state-of-the-art algorithms. In the future, we will implement new protocols, and this technique will also be implemented in IoT environment, wireless network, and fog computing.



---

*Source: 3418483-2021-07-26.xml*