Virtual Machine Selection Algorithm Based on User Requirements in Mobile Cloud Computing Environment

The article analyzes the advantages of mobile cloud technologies and problems emerging during the use of those. The network infrastructure created based on cloudlets at the second level of mobile cloud computing with hierarchical structure is analyzed. At the same time, the article explores the issues of satisfaction of demand of mobile equipment for computing and memory resources by using these technologies. The article presents one solution for the allocation of mobile user requests in virtual machines created in cloudlets located near base stations of wireless metropolitan area networks (WMAN) in a balanced way by considering the technical capacity of those. Alongside, the article considers the solution of user problem during designated time and the issue of determining virtual machines satisfying other requirements. For this purpose, different characteristics of the stated problem, virtual machines, as well as communication channels between a user and virtual machines are considered. By using possible values determining the importance of cloudlets, conditions for loading software applications of a user to a virtual machine are explored and an appropriate method is proposed.


Virtual Machine Selection Algorithm Based on User Requirements in Mobile Cloud Computing Environment
Dr Rashid Alakbarov (1) , OqtayAlakbarov (2) (1) Deputy director of Institute of Information Technology, Azerbaijan National Academy of Sciences (2)

Introduction
Mobile users have started to use the services of cloud computing technologies broadly in recent period. The article considers the issues of more efficient use of cloud computing resources by using Mobile Cloud Computing technologies widely used recently. The rapid growth of the use of mobile equipment (notebook, tablet, smartphones, etc.) technologies in the world and connection to the Internet via corresponding telecommunication technologies (GPS, 3G, 3G, Wi-Fi, etc.) has boosted the development of new technologymobile Cloud Computing technology. It is known that, although the capacity of any mobile device (computing and memory resources) is limited, users employ these devices for the solution of problems requiring large computational and memory resources. For this purpose, cloud computing technologies are broadly employed. Thus, it is possible to eliminate the limitations of computing and memory resources existing in mobile user devices by using cloud technologies [1].
Mobile cloud computing is a new platform developed from the combination of mobile equipment and cloud computing and allows the users to implement the solutions of complex problems and the storage of large-volume data in memory [2].
In comparison with traditional wired network, mobile computing networks encounter several problems: the loss of signal in wireless communication channel, low transmission capacity of a channel, security, delays while connecting to network, limited resources, low computational performance, etc. Moreover, the geography, climate, etc. of the location of base stations affect the quality of services (QoS) provided by mobile cloud computing.
While using cloud technologies, the users base their judgment on following criteria [3]:  rapid and reliable delivery of data and outcomes to users, etc.
So, the factors affecting the efficient use of cloud services in mobile cloud computing are as follows [4]:  location of data centers of cloud computing system far from user;  overload of internet network;  occurrence of delays in network;  occurrence of interruptions in communication channels;  use of cloudlets with various technical capacity in network;  non-optimal location of user requests in cloudlets, etc.
The following strategies are considered to be employed for solving the above-mentioned problems [5]:  development of network infrastructure based on cloudlets;  locating the cloudlets in necessary locations in network;  locating the software applications in cloudlets close to users in order to reduce the number of delays;  determination of computational and memory resources of cloudlets;  selection of virtual machines in cloudlets corresponding to the requirements of users;  utilization of minimal communication channel between user and cloudlets;  location of software applications with high frequency of use in cloudlet network in advance, etc.
The article reviews balanced solution for the allocation of mobile user requests (tasks or software applications) in virtual machines placed in cloudlets located near the base stations of Wireless Metropolitan Area Networks (WMAN) taking into account their technical capacity. Section 2 reviews related works on the development of hierarchically structured network infrastructure based on cloudlets. Section 3 reviews the development of hierarchically structured network infrastructure based on cloudlets. At the same time, selection of cloudlets that provide fast solution of user problem using the technical capabilities of cloudlet network (computing performance, network bandwidth and network delays) is analyzed. Section 4 reviews the determination of a virtual machine or a set of virtual machines that ensure users requirements and are capable to solve the task in a short period of time and with minimum cost providing maximum reliability.

Problem Statement
The limitations in technical capacity of mobile devices in mobile cloud computing environment, the quality of wireless communication, the variety of applications are important factors affecting the evaluation of cloud computing. In order to facilitate a specific environment for Cloud Computing in mobile applications, various stages of mobile infrastructure must be taken into consideration causing the overload of a network and transmission delays. Mobile devices in mobile cloud computing connect to cloud computing system via internet network with the help of base stations (GPS, 3G, 4G, Wi-Fi, etc.) and use the required services. At present, users extensively utilize three types of cloud services (IaaS, Paas and SaaS services). There exist some studies devoted to the analysis of separate characteristics of these services [6][7][8]. At present, millions of mobile users broadly utilize mobile add-ons (mobile commerce, mobile education, mobile health, mobile games, etc.) by using the services mobile cloud providers [9,10]. The developed mobile applications are not dependent on the operation systems of mobile devices and the type of a device. Hence, the number of users utilizing the services of cloud technologies is rapidly growing day by day.
On the other hand, it is possible to satisfy extensive computing and memory storage requirements by using traditional centralized cloud services. However, delays occur in these cloud services while obtaining results or data. Hence, it is more desirable that, software is located in servers near the users utilizing them and the rapid solution of the issue is facilitated in real time regime.
The provision of high quality services of cloudlets near base stations depends on the technical capacity of computer equipment used in the development of those (the intensity of processor functioning, the number of cores and virtual machines, memory volume, transmission capacity of network, etc.). It is because the technical capabilities of cloudlets must allow the loading of software applications utilized by a user.
It is known that, various architectures have been proposed for the facilitation of the efficient use of clouds. A hierarchically structured architecture developed with the use of resource manager (RM) is proposed for efficient use of cloudlet resources [11]. RM center of hierarchically structured network stores data about the technical capabilities of virtual machines created in cloud computing. As users access cloud software they connect to proposed RM initially, thereafter, that center connects them to corresponding cloud resource during a short period and a mobile user easily connects to cloud software. MCC architecture is given in Figure  1. Mobile devices connect to mobile networks via base stations (for instance, base transmitter station -3G/4G, access point Wi-Fi, etc.) establishing functional interface and connections (air connections) between network and mobile devices and managing those connections. Requests and information of mobile users (for instance, ID and location) are transferred to Resources Management Center (central processors connected to server) providing mobile network services. Here, mobile network operators can provide services to mobile users, such as home agent (HA) stored in databases and AAA (authentication, authorization, and accounting) services based on subscriber information. Thereafter, the requests of subscribers are sent to a server of Resource Manager Center of proposed model providing the connection via Internet, and a connection is established with corresponding cloud via internet here. Management center stores information regarding computer equipment (server, desktop, notebook, etc.) used during cloud development. At the same time, information is gathered on technical capabilities of cloudlets in manager centers (performance intensity of processor, number of processor cores, and number of virtual machines and their technical characteristics, memory volume, etc.) and on which cloudlets users are located close to in mobile network. Hence, it is among problematic issues to determine on which cloudlet and virtual machine a software application must be located, which satisfies the user requests based on received requests. The article is devoted to the efficient allocation of software applications in cloudlets selected in accordance with the user requests. One of the main problems of mobile cloud computing users often select the type of a virtual machine not corresponding to the resources required by a problem to be solved. The requirements for the characteristics of cloud infrastructure such as mobile device, network coverage and delay vectors determine whether software add-ons will be supported by particular mobile cloud infrastructure (Table 1). Table 1 describes the requirements posed to the computational intensity of a particular type of problem, network transmission capacity and network delays. As users utilize web-mail or social networks, they do not pose particular requirements to large computational resources (low), network transmission capacity (medium) and network delays (high). However, assume that, if a user uses biometric recognition, HD video data, online games, translation and navigation software, solid requirements are posed to above-mentioned attributes of cloud infrastructure. High definition and content applications, such as face recognition in real time require the networks with large coverage area and low delays such as LTE. This, in turn, provides the transmission of algorithms required for face recognition, large images operating in cloud servers to user devices rapidly and without problems. The environment of high transmission capacity and low number of delays for software requiring high volume of transmission can be achieved by using data centers located in the vicinity [12]. Hence, the satisfaction of multiple user requests and resource requirements with various volume and their location in optimal cloudlets and virtual machines are among topical issues. The majority of studies conducted in Mobile Cloud Computing technologies field is devoted to the issues of efficient processing of the user requests in farther located cloud servers. The loading of internet network in centralized Cloud Computing systems is less rapid due to the increase in delays of the user requests in communication channels (in internet networks, internet providers, among base stations, etc.). For this purpose, abovementioned delays can be eliminated (reduced) by establishing cloudlet networks closely located to users. At the same time, the cloudlets process the requests rapidly and provides less energy consumption of mobile devices as well.
Delays can be reduced by providing the solution of the user requests in closely located cloudlets and decreasing the number of communication channels between in the number of inter-cloudlet connections. Energy consumption, delays and interruptions can be reduced by the appropriate allocation of auxiliary (interface) and min parts of software applications utilized by users in mobile devices and cloud servers in a corresponding manner [12].
As the user requests demand various volume of computational and memory resources, the issue of appropriate allocation of requests in cloudlets used in network is deemed as a topical problem. Therefore, the article proposes a solution of the issue of selecting virtual machines capable of providing the more rapid solution of a problem in accordance with user requirements by employing technical capacity of cloudlets and virtual machines created in cloudlets.

RELATED WORK
In this section related works on selection of virtual machines that meet requirements on solving user issues. Optimal placement of wide range of issues of numerous mobile users on cloudlet virtual machines is of great significance. Most researches on Mobile Cloud Computing are dedicated to effective organization of user requests on remote cloud server [13,14]. High quality functioning of cloudlets located near the base stations depends on the technical capabilities of the computer hardware (the frequency of processors, number, volume of memory, bandwidth, etc.) used for their development. The article [15] investigates the limitations of technical capabilities of mobile devices in mobile cloud computing environments, the quality of wireless communication, and the impact of the variety of application software on the efficient use of cloud computing services. Due to the wireless communication channels used, delays often occur, and simultaneously, network transmitting capability reduces. Moreover, frequent disruptions (depending on weather, landscape, etc.) occur in networks. To address these problems, [16] suggests locating cloudlets close to base stations near users. Some researchers argue that delays in data exchange between remote users and remote clouds often occur due to the cloud servers physically located far from users [17]. Deploying cloud servers close to users greatly reduces delays in data exchange [18]. Mobile devices are unable to use software that requires large computing and memory resources due to limited resource problem, or running such software requires great energy consumption. In this regard, programs are divided into several parts. The main computing part of the program is processed by cloud, whereas mobile devices only solve some simple issues. The article [19] focuses on the parts that require more calculations in cloud, and the other parts associated with the user interface that run in mobile devices. Some researchers review the issue of fast problem solution by distributing software applications among multiple cloudlets [6]. The article [20] highlights virtual machine selection issue that can provide faster resolution of the problem based on user's requirements using technical capabilities of cloudlets and virtual machines created in cloudlets. The article [21] explores the balanced optimal distribution of mobile application software among mobile cloud servers. Some works [22,23] offer building network infrastructure of cloudlets located near Access Points of Wireless Metropolitan Area Networks (WMAN). It is best to build cloudlets near all access points of the mentioned networks. It is not economically efficient and raises the cost of network. On the other hand, cloudlets deployed near any access point may be used a little or not used at all. Therefore, the cloudlets are appropriate to be deployed in the vicinity of more mobile users (shopping malls, libraries, schools, universities, stadiums, stations, airports, etc.). Some studies [24] explore conditions requiring the creation of cloudlets in mobile cloud computing and review the prediction of deploying cloudlets near to base stations. The article [25] examines the problem of reducing energy consumption through optimal distribution of problems resolved by user between cloudlet and remote cloud server. Some researchers suggest that reduced number of communication channels between a user and cloudlet may provide higher quality implementation of cloud computing software in a short period of time, with minimal delays and breakages [26]. Some authors [27] analyze the migration issues in mobile cloud services (placing services in cloudlets closer to users) and indicate some advantages of this method. The article [28] focuses the creation of primary computing resources (virtual machines) using a hierarchical analysis method for efficient use of cloud computing environment. Some works explore conditions requiring the creation of cloudlets in mobile cloud computing and review the prediction of deploying cloudlets near to base stations [29]. The work [27] offers to use cloudlets to eliminate limitations of mobile devices related to computing and memory resources. Another work [30] deals with the elimination of delays by reducing the number of communication channels between users and cloudlets solving the users requests in neighboring cloudlets.

Solution of the Problem
Let us determine the prerequisites for the solution of a problem. These prerequisites are shaped based on the characteristics of cloudlets, virtual machines created in these cloudlets and problems to be solved, as well as the requirements posed to the solution of this problem by a user. These features and requirements are investigated form the point of view of the solution of a problem posed. The stated problem is to determine a virtual machine or a set of virtual machines among virtual machines, which are capable of solving a particular problem with minimal time and financial cost and possessing the characteristics of maximum reliability with the condition to satisfy user requirements.
Denote the number of instructions satisfying the problem solution as i. The software tools determining this number is known. One of the important parameters is the volume of information to be transmitted while solving a problem -d (bytes). This number is generated by the sum of bytes sent to an arbitrarily selected cloudlet or virtual machine by a user or bytes sent from a cloudlet or virtual machine to a user while solving the problem and cyclic (CRC) bytes for error detection added to those in order to protect the data sent. CRC bytes are added in order to determine and correct for tampering issues of transmitted or received bytes in communication channels.
CRC bytes is deemed as an important element of protocol. The information describing the presence of transmission errors and data integrity is recorded here. Various algorithms exist for calculating the added bytes. For instance, CRC 16 is used in Modbus protocol, CRC polynomial is written as 0х8005 in hexadecimal system, and the power of polynomial is 15 [31,32]. It is well known that, in case of power to r of CRC polynomial, the maximum length of block for determining an error would be at least 2 − 1.
Transmitting and receiving parties must decide upon G(x) divisor by using polynomials while establishing CRC algorithms [33]. The largest bits in divisor polynomial must be one. If M(x) polynomial to be transmitted consists of bits m, zeros are added to polynomial in order to be able divide it with G(x). The following algorithm is obtained [34]: 1. Assume that, the power of G(x) is r. Then, r number of zeros are added to division frame. Polynomial ( ) is obtained.

Polynomial ( ) is divided by G(x) by the module of 2.
3. The remainder of division is obtained and transmitted; information is calculated as = − / ( ) .

Tampering E(x) can occur during the transmission and the receiver may receive T(x)+E(x). Hence, the receiver performs division [T(x)+E(x)]/G(x).
As T(x)/G(x) is equal to zero, the results depend of E(x)/G(x). G(x) -indivisible errors are detected, whereas divisible errors G(x) cannot be determined. In practice, various options of G(x) are developed. For instance, IEEE 802 standard for Ethernet connections uses polynomial 32 + 26 + 23 + 22 + 16 + 12 + 11 + 10 + 8 + 7+ 5+ 4+ 2+ 1+1 When it is not possible to correct tampering issues, repeat requests are formed. Hence, this number must be multiplied by the coefficient of repeats in case of more accurate calculations.

= ( + )
Here, -is the number of necessary bites, -are bytes added for CRC and is the coefficient of repeats.
It is to be noted that, some instructions are added which generates bytes CRC, adds and corrects the information to be transmitted and generates repeats, alongside with necessary instructions pertaining to the algorithm of problem solutions in the number of instructions in the problem.
The maximum value of the time to be spent on the solution of the problem among user (customer) requests and the maximum value of the problem solution is denoted as T and C, correspondingly.
The features of cloudlets are determined in the set of cloudlets possessing a communication with equalizer. Here, if N number of cloudlets exist as ∈ [1, ], the speed of the problem solution in the nth cloudlet depends of the virtual machines generated there and the minimum and maximum value of this speed can be denoted as , and , , respectively. The maximum and minimum values of the time spent on the solution of problems in the nth cloudlet can be denoted as , and , , respectively.
As we are interested in the solution of a problem with virtual machines created in cloudlets, we are going to employ corresponding features of virtual machines. For this purpose, number of virtual machines and the connection of each of them with an equalizer can be created in an arbitrary cloudlet ∈ [1, ]. In other words, equalizer is familiar with the features of each virtual machine located in cloudlets. The number of virtual machines known to equalizer will be = =1 in this case. Hence, the characteristics of an arbitrary mth virtual machine satisfying condition ∈ [1, ] are as follows: -Velocity of information transmission between a selected virtual machine and a user -bod can be calculated as: It is known that, information can be transmitted through j number of intermediate connections between a user and virtual machine where a problem is solved. If the velocity of transmission in each of these intermediates is denoted as , the final transmission time of these intervals will be * 1 . Hence, the velocity of transmission here can be obtained as: -Amount of time spent on information transmission -2 = = * 1 ; -Final amount of time spent on the solution of a problem in the mth virtual machine and reception of necessary information = 1 + 2 = + ; If the value of using selected mth virtual machine in a unit of time is , the solution value of a problem in the mth virtual machine will be Cm=Tm*cm.
The reliability of a virtual machine is determined with the reliability of two main elements. These are the reliability of a virtual machine as such and the reliability of possible communication channels between a customer and a virtual machine. The reliability of a virtual machine can be determined as a probability of an error not to occur within any period t while it is operating and denoted as ( ). This probability is related to , which denotes the probability of an error to occur during the performance of virtual machine within any time period t [35]: It is to be noted that, both probabilities possess the following features: The frequency of denials can be determined as . This expression is adopted as a main rule of reliability.
If = , we obtain the exponential distribution of the operation time of a selected virtual machine without errors.
As all other parameters are determined with , it is possible to calculate these parameters approximately during the performance of cloudlet and virtual machine and more accurately as the time passes. For this purpose, it is possible to set up the monitoring of a virtual machine in time intervals with the length of ∆ during various number of times of exploitation. If we denote the number of requests to virtual machine in the arbitrary jth interval ( ∈ 1, ) as , and the number of errors during period ∆ as ( ), the approximate value of can be calculated as follows: This parameter converges to its true value as the time passes and it is possible to determine the probability of a virtual machine to operate without a failure. Such that, lim →∞ = .
If we enter the missed index m again into the equality, the probability of a failure not to occur during the period t in the couse of the operation of a virtual machine can be determined as: The communication between a user and selected virtual machine or cloudlet can consist of several parts. Here, it is possible to establish a communication generated directly through the communication or other cloudlets. Several reasons may cause it, and regardless of these reasons, separate parts of communication can be described as parallel or consecutive connections. The probability of reliability of each simple connection can be considered as above or determined approximately. However, it is known that, the probability of reliability of parallel or consecutively connected parts can be determined as below: Final probability of n number of parts connected in parallel Can be determined as Here, ( ) is the probability of a reliable functioning of the ℎ part until period without any failure.
Final probability of n number of consecutively connected parts Can be determined as = =1 ( ). Here, ( ) is the probability of reliable functioning of the ith part until period without a failure.
It is to be noted that, the final communication between a selected virtual machine, user and a virtual machine can be described as consecutively connected elements. Hence, the probability of a user to utilize an arbitrarily selected virtual machine will be: A condition that, this probability would not be smaller than any value 0 (depending on the number of communication channels and node between a user and cloudlet) can be posed during an empirical work.
The high-quality service of cloudlets and virtual machines is dependent on the technical capabilities of computer equipment used in its creation (work intensity of processors, number of cores and virtual machines, the type of virtual machines (tiny, small, medium, large, x large, etc.), memory capacity, transmission capacity of network, etc.) [28]. As final characteristics of tools deemed as necessary and important, resource characteristics for the mth virtual machine can be calculated as Here: -number of resources to be considered in virtual machines, -value of the kth resource of the mth virtual machine, -maximum value of the kth resource for cloudlet network, -empirical or theoretical importance of the kth resource. Here, 0 < <. and =1 = 1 It is obvious that, expression produces a normalized value of the kth resource of the mth virtual machine. While solving the problems posed, the minimum value of resource is determined and it is required that it satisfies constraint ≥ So, the problem of selecting a virtual machine for solving the user problem is constructed as a general programming problem: Specific problems can be obtained from general problems by altering the constraints posed to the problem. In this case, the constraints imposed on reliability and resources are preserved.
If a user is solely interested in the value of the solved problem, the following programming problem is obtained: If a user is solely interested in the duration of the problem solution, the following programming problem is obtained: This section may be divided into subsections or may be combined.

Experiments
As mentioned above, providing users with quality services depends on the technical capabilities (frequency of processors, number of cores and virtual machines, type of virtual machines (tiny, small, medium, large, In the course of the experiment, working frequencies of processors are accepted to be equal. Additionally, the values of the usage of all virtual machine are equal at a time and vary depending on the type of machine. If this value for t = 2 is accepted to be equal to c, this value can be calculated as c (t) = c t = c * t − 1for arbitrary t = 2, 4, 8, 16, 24. Here, t − 1 can be called the coefficient. It is seen that the coefficient increases non-linearly depending on the type of virtual machine (Figure 2).  Afterwards, the specificationR m is calculated with the use of weight coefficients: For m:=1 to M do begin R m = 0; For k:=1 to K do Obviously, the probability characteristics of the virtual machines deployed in cloudlets located neighboring to local fields can be approximately identical. Therefore, if not to take into account the probability condition in the tasks (1) -(3), simpler tasks can be obtained. For example, solution of the task C m → min C m ≤ C R m ≥ R min (4) taken from the task (2) seems obvious. Here, the parameter C of the second condition indicates the value to be assigned by the user to solve the task. The parameter R min indicates the minimum value of the virtual machine to be selected for the problem solving and depends on the problem to be solved. The parameters C m and R m are calculated through software. As a solution to the problem, the virtual machine that provides the second and third conditions and is the smallest value for C m is selected.

Conclusions
The article proposed a solution of a problem of allocation of mobile user requests in virtual machines by considering the technical capabilities of virtual machines created in cloudlets located near bases stations of wireless metropolitan area networks. The features of user problem and virtual machines were explored while solving the problem. A technique for determining the reliability indicators of virtual machines and the communication between a virtual machine and a user is described. An expression was given for obtaining the reserve resource indicators of virtual machines as a normalized value. Finally, a general programming problem was constructed which can propose a solution satisfying time, value and other requirements for the solution of user problem. In some special cases, specific programming problems were constructed for proposing a solution for a problem.
The solution methods presented in the article can be used while solving similar problems.