approach to using two way search deadlock detection for resource ...

6 downloads 0 Views 560KB Size Report
Abstract−An allocation of resources to a virtual machine specifies the maximum amount ..... detection detects the cycle when the new arc is added maintains the ...
International Journal of Computer & Communication Engineering Research (IJCCER) Volume 3 - Issue 1 January 2015

APPROACH TO USING TWO WAY SEARCH DEADLOCK DETECTION FOR RESOURCE ALLOCATION IN HETEROGENEOUS DISTRIBUTED PLATFORMS Ha Huy Cuong Nguyen Quang Nam University Quang Nam - Vietnam

Van Hung Ho Quang Nam University Quang Nam - Vietnam

Van Son Le Da Nang University Da Nang - Vietnam

[email protected]

[email protected]

[email protected]

Abstract−An allocation of resources to a virtual machine specifies the maximum amount of each individual element of each resource type that will be utilized, as well as the aggregate amount of each resource of each type. An allocation is thus represented by two vectors, a maximum elementary allocation vector and an aggregate allocation vector. There are more general types of resource allocation problems than those we consider here. In this paper, we present an approach for improving the deadlock detection algorithm, to schedule the policies of resource supply for resource allocation on heterogeneous. Deadlock detection algorithm using two way has run time complexity of O(min(m1/2,n2/3), where m is the number of resources and n is the number of processes. We propose the algorithm for allocating multiple resources to competing services running in virtual machines on a heterogeneous distributed platform. The experiments also compare the performance of the proposed approach with other related work.

Keywords:Cloud

computing.

Resource

allocation.

Heterogeneous Distributed Platforms. Deadlock detection.

1. INTRODUCTION “Recently, there has been a dramatic increase in the popularity of cloud computing systems that rent computing resources on-demand, bill on a pay-as-you-go basis, and multiplex many users on the same physical infrastructure. These cloud computing environments provide an illusion of infinite computing resources to cloud users that they can increase or decrease their resource. In many cases, the need for these resources only exists in a very short period of time.”[1,2] The increasing use of virtual machine technology in the data center, both leading to and reinforced by recent innovations in the private sector aimed at providing lowmaintenance cloud computing services, has driven research into developing algorithms for automatic instance placement and resource allocation on virtualized platforms[1,2], including our own previous work. Most of this research has assumed a platform consisting of homogeneous nodes connected by a cluster. However, © http://ijccer.org

e-ISSN: 2321-4198

there is a need for algorithms that are applicable to heterogeneous distributed platform. Heterogeneity happens when collections of homogeneous resources, formerly under different administrative domains, are federated and lead to a set of resources that belong to one of several classes. This is the case when federating multiple clusters at one or more geographic locations e.g., grid computing, sky computing. In the past, grid computing and batch scheduling have both been commonly used for large scale computation. Cloud computing presents a different resource allocation paradigm than either grids or batch schedulers [4,5]. In particular, Amazon C2 [10], is equipped to, handle may smaller computer resource allocations, rather than a few, large request as is normally the case with grid computing. The introduction of heterogeneity allows clouds to be competitive with traditional distributed computing systems, which often consist of various types of architecture as well. In a heterogeneous cloud environment. Recently, reports have appeared many of the studies provide cloud computing resources, the majority of this research to deal with variability in resource capacity for infrastructure and application performance in the cloud. In this paper, we develop a method to predict the lease completion time distribution that is applicable to making a sophisticated trade off decisions in resource allocation and scheduling. Our evaluation shows that these methods deadlock detection using algorithm two ways search can improve efficiency and effectiveness of the cloud computing allocation resource heterogeneous systems. The work is organized in the following way: in section 2, we introduce the related works; in section 3, we introduce existing models; in section 4, we present approaches for improving the parallel deadlock detection algorithm; in section 5, we present our conclusions and suggestions for future work. 2. SYSTEM MODEL RESOURCE ALLOCATION IN HETEROGENEOUS DISTRIBUTED PLATFORM Resource allocation in cloud computing has attracted the attention of the research community in the last few years. Cloud computing presents a different resource allocation paradigm than either grids or batch schedulers[2]. In particular, Amazon C2 [10], is equipped to, handle may smaller computer resource allocations, rather than a few, large request as is normally the case with grid computing. The p-ISSN: 2321-418X Page 11

Ha Huy Cuong Nguyen, et al International Journal of Computer and Communication Engineering Research [Volume 3, Issue 1 January 2015]

introduction of heterogeneity allows clouds to be competitive with traditional distributed computing systems, which often consist of various types of architecture as well. Like traditional distributed system before we can see a heterogeneous distributed system consists of a set of processes that are connected by a communication network. The communication delay is finite but unpredictable[21,22]. 2.1 The application A heterogeneous distributed program is composed of a set of n asynchronous processes p1, p2,…,pn that communicates by message passing over the communication network. We assume that each process is running on a different processor. The processor does not share a common global memory and communicate solely by passing messages over the communication network. There is no physical global clock in the system to which processes have instaneous access. The communication medium may deliver messages out of order, messages may be lost garble or duplicated due to timeout and retransmission, processors may fail and communication links may go down. The system can be modeled as a directed graph in which vertices represent the processes and edge represent unidirectional communication channels. We use the platform graph, off the grid platform. We model a collection of heterogeneous resources and the communication links between them as the nodes and edges of an undirected graph. Seean example in Figure 1 with 8 processors and 11 communication links. Each node is a computing resource (a processor, or a cluster, or node). Example 1A example simple platform

P1 P8

P2

P3

P6 P7

P5

P4

Figure. 1:. A examble simple platform A process can be in two states: running or blocked. In the running state (also called active state), a process has all the needed re and is either executing or is ready for execution. In the blocked state, a process is waiting to acquire some resource. 2.2 The architecture The target heterogeneous platform is represented by a directed graph, the platform graph. There are p nodes P1, P2,…, Pn that represent the processors. In the example of figure 1 there at eight processors, hence n = 8. Each edge represents a physical interconnection. Each edge eij: Pi Pj is labeled by value ci,j which represents the time to transfer a message of unit length between P i and Pj, © http://ijccer.org

e-ISSN: 2321-4198

in either direction: we assume that the link between P i and Pj is bidirectional and symmetric. A variant would be to assume two unidirectional links, one in each direction, with possibly different label values. If there is no communication link between Pi and Pj we let ci,j= +  , so that ci,j< +  means that Pi and Pj are neighbors in the communication graph. 2.2 Wait – For – Graph (WFG) In distributed systems, the sate of the system can be modeled by a directed graph, called a wait for graph (WFG) [21,22,23,24,25]. In a WFG, nodes are processors and there is a directed edge from node P1 to mode, P2 if P1 is blocked and is waiting for P2 to release some resource. A system is deadlocked if and only if there exists a directed cycle or knot in the WFG. Let us first of all describe the deadlock condition problem more precisely. A set S = {s1, s2,…sk}   of k > 1 entities is deadlocked when the following two conditions simultaneously hold: Each entity is  an S is waiting for an event permit that must be generated from another entity in the set; No entity si  S can generate a permission while it is waiting. If these two conditions hold, the entities in the set will be waiting forever, regardless of the nature of the permit and of why they are waiting for the “permission”; for example, it could be because si needs a resource held by sj in order to complete its computation. A useful way to understand the situations in which deadlock may occur is to describe the status of the entities during a computation, with respect to their waiting for some events, by means of a directed graph

W , called wait-for graph.

3. TYPESETTEXT PROBLEM WITH DEFINITIONS The clustering is the subdivision of graph node set into groups. This technique firstly introduced by Fredricson [25]. It partitions the graph into a smaller subdivision of connected sub graph called clusters. The techniques use the tree data structure to store the information about the graph edges and nodes. Definition 1 A clustering C(G) of a graph G=(X,Y) is a subdivision of vertices X disarranges, a nonempty subset of {C1, C2,…,Ck} where Ci  C. Definition 2 A dynamic clustering C(G)={C1,C2,…,Cn} of a dynamic graph G, with length L, consist of a set Clustering C1,C2,…,Cn where Ci is a clustering of a graph Gi. Definition 3 A system has a deadlock if and only if the system has a set of processes, each of which is blocked (e.g.,preempted), waiting for requirements that can never be satisfied. Definition 4 A path (v1,v2,,vk-1,vk), k>=2 is a set of nodes connected by a consecutive ordered sequence of alternating request and grant edges(v1,v2),(v2,v3),…,(vk-1,vk), where every node in the path is distinct and where every other node belongs to the same set P or Q. Definition 5 A cycle is a set of nodes (vi,vi+1,,vj,vi) consisting of a path (vi,vi+1,,vj) and an additional edge between vj and vi. In heterogeneous distributed platform, the state of the system can be modeled by a directed graph, called a wait for graph (WFG). In a WFG, nodes are processes and there is a directed edge from node P1 to node P2 if P1 is blocked and is waiting for P2 to release some resource. A system is deadlocked if and only if there exists a directed cycle or knot in the WFG. p-ISSN: 2321-418X

Page 12

Ha Huy Cuong Nguyen, et al International Journal of Computer and Communication Engineering Research [Volume 3, Issue 1 January 2015]

We consider a service hosting platform composed of H heterogeneous hosts, or nodes. Each node comprises D types of different resource, such as CPUs, network cards, hard drives, or system memory. For each type of resource under consideration a node may have one or more distinct resource elements (a single real CPU, hard drive, or memory bank) [16,17,18]. Services are instantiated within virtual machines that provide analogous virtual elements. For some types of resources, like system memory or hard disk space, it is relatively easy to pool distinct elements together at the hypervisor or operating system level so that hosted virtual machines can effectively interact with only a single larger element. For other types of resources, like CPU cores, the situation is more complicated. These resources can be partitioned arbitrarily among virtual elements, but they cannot be effectively pooled together to provide a single virtual element with a greater resource capacity than that of a physical element. For these types of resources, it is necessary to consider the maximum capacity allocated to individual virtual elements, as well as the aggregate allocation to all virtual elements of the same type. An allocation of resources to a virtual machine specifies the maximum amount of each individual element of each resource type that will be utilized, as well as the aggregate amount of each resource of each type. Expectedly, an allocation is thus represented by two vectors, a maximum elementary allocation vector and an aggregate allocation vector. Note that in a valid allocation it is not necessarily the case that each value in the second vector in an integer multiple of the corresponding value in the first vector, as resource demands may be unevenly distributed across virtual resource element. 4. DEADLOCK DETECTION FOR RESOURCE ALLOCATION USING TWO WAY SEARCH IN HETEROGENOUS DISTRIBUTED PLATFORM In this paper, we will approach proposed algorithm for deadlock detection maintains a property of n-vertex directed graph when the new is added in the graph using two-way search. The time bound for the incremental cycle algorithm for deadlock detection take O(min{m1/2,n2/3},m) time bound for the m edge insertion in the directed graph. It reports the cycle when the algorithm detects for edge (v,m) that there exist a path from vertex w to v. The algorithm defined here maintains the topological order also if the cycle is not detected and the graph is acyclic. The topological order of the direct acyclic graph is a sequence of vertices such that for every edge (v,w), v < w. In the previous topological ordering algorithm the cycle can be detected in O(m+n) time by either using the depth first search method[23] or by recursively deletion of the vertices. As for some deadlock problem the graph is not fixed and the new edge added in the graph, the incremental cycle detection detects the cycle when the new arc is added maintains the topological order of the graph. The algorithm defines here work better for cycle detection and finding the topological ordering for the arc addition than running the algorithm from scratch for the static graph. The assumption is made that the vertex set is © http://ijccer.org

e-ISSN: 2321-4198

fixed and initially the edge set is empty. Here ‘n’ denotes the number of vertices and ‘m’ denotes the number of arcs added. The idea uses in the algorithm is the two way search or compatible search. 4.1 Algorithmic Approach to Deadlock Detection Algorithm Deadlock Detection two - way search [27,28,29,30] Step 1: A= {w}; B= {v}; FA= {(w, y) where (w, x) is the edge}; BB= {(x,v) where (x,v) is an edge in the graph}. Step 2: For (u, y)  Aand ( x, z )  B where (u,z) do Select (u,y) and (x,z) from set FA and BB where (u

Suggest Documents