A Multiserver User-Space Unikernel for a Distributed Virtualization System
Total Page:16
File Type:pdf, Size:1020Kb
A Multiserver User-space Unikernel for a Distributed Virtualization System Pablo Pessolani Departamento de Ingeniería en Sistemas de Información Facultad Regional Santa Fe, UTN Santa Fe, Argentina [email protected] Abstract— Nowadays, most Cloud applications are developed application components began to be deployed in Containers. using Service Oriented Architecture (SOA) or MicroService Containers (and similar OS abstractions such as Jails [7] and Architecture (MSA). The scalability and performance of them Zones [8]) are isolated execution environments or domains is achieved by executing multiple instances of its components in in user-space to execute groups of processes. Although different nodes of a virtualization cluster. Initially, they were Containers share the same OS, they provide enough security, deployed in Virtual Machines (VMs) but, they required enough performance and failure isolation. As Containers demand computational, memory, network and storage resources to fewer resources than VMs [9], they are a good choice to hold an Operating System (OS), a set of utilities, libraries, and deploy swarms. the application component. By deploying hundreds of these Another option to reduce resource requirements is to use application components, the resource requirements increase a the application component embedded in a Unikernel [10, lot. To minimize them, usually small OSs with small memory footprint are used. Another way to reduce the resource 11]. A Unikernel is defined as “specialized, single-address- requirements is integrating the application components in a space machine image constructed by using library operating Unikernel. This article proposes a Unikernel called MUK, system” [12]. A Unikernel is a technology which integrates based on a multiserver OS, to be used as a tool to integrate monolithically network, storage, and file systems services Cloud application components. MUK was built to run in user- with the application component resulting in a single space of a Distributed Virtualization System. Both technologies executable code. This way of building an environment to run facilitate the scattering of application components in a the application optimizes resource usage because only those virtualization cluster keeping the isolation properties and services that the application requires are integrated. minimal attack surface of a Unikernel. Therefore, the size of the resulting executable code, memory footprint and the application attack surface are reduced to a Keywords: virtualization, multiserver, middleware minimum. Those facts improve application security, and make application components easily distributable, replicable I. INTRODUCTION and deployable. It is unlikely that the application component embedded Nowadays, there is a need to build and to deploy into a Unikernel will be completely autonomous. Probably, it distributed applications to satisfy the performance needs of needs to communicate with other components running within Cloud information systems. They must be able to manipulate other Unikernels, and with external servers such as storage big data volumes (sounds, videos, photographs, documents, servers, file servers, logging-servers, database servers, key- etc.) in huge and complex databases. Most of these Cloud value servers, etc. A provider-class Cloud application must applications are developed using the SOA [1] or MSA [2] coordinate the actions among its components and with the methodologies. Both software architectures, consist of external servers to provide fault tolerance and replicated factoring a monolithic application into multiple components services. Peer to peer and group communications, leader that communicate with each other through some standardized election mechanisms, fault detection, distributed locking, protocol (such as SOAP [3]), with a weak coupling between etc., are requirements to coordinate actions among them. distributed components. All of these are complex services The application scalability and performance is achieved which must be considered in the application design and by deploying multiple instances of its components in development stages and in the application-Unikernel build. different nodes of a virtualization cluster (usually called This article presents a Unikernel called MUK, based on a "swarms"). Initially, Virtual Machines (VMs) were used, but multi-server user-space OS instead of a Library OS. As its they required enough computational, memory, network and components (servers) are autonomous by definition, the storage resources to hold a complete Operating System (OS), integration with the application is facilitated. The chosen OS its utilities, libraries, and the application component. When used as a base to build MUK was Minix Over Linux (MoL) deploying a swarm of VMs, the resource needs increase [13], a user-space Minix branch which run as a set of Linux proportionally. To reduce that demand, OSs with small processes. Minix is a POSIX-compliant OS, and because memory footprint are often used. MoL is a port of it to user-space, it is compliant too. As Later, as management tools such as Docker [4], MUK is the Unikernel version of MoL, it keeps the POSIX- Kubernetes [5], Mesos [6] (among others) were improved, compliance which allows it to execute legacy applications Instead of running the application on the hosts-OS, a under its environment. This feature represents an important VOS (Virtual Operating Systems) [15] is needed to improve advantage over some other Unikernels which provide their security and fault isolation and provide a greater variety of own non-compliance APIs forcing developers to port their options for applications. The DVS enables the execution of legacy applications. multiple instances of different VOS each one executing in its MUK runs inside a Distributed Container of a Distributed own DC. A subset of nodes is allocated for each DC, but Virtualization System (DVS) [14]. A Distributed Container they can share the nodes between several DCs (Fig. 1). This covers several related Linux Containers scattered on nodes of higher degree of granularity of resource allocation allows a a virtualization cluster. The Unikernel and DVS technologies better use of the infrastructure and provides greater elasticity facilitate the distribution of application components as and efficiency. swarms across the nodes of a DVS cluster. A DVS provides MUK and its integrated application components, several A. DVS Architecture services required by distributed applications such as The main components of the DVS architecture model are location-transparent IPC, a Group Communication System (Fig. 2): (GCS), fault detection, replication, leader election mechanisms, easy deployment and management, etc. All Generic Applications - A Generic Applications - B these features are the platform requirements to develop and DC A Guest DVOS - A Guest DVOS - B DC B to deploy elastic, high availability, high performance, Container-1 Container-2 Container-3 Container-4 Distributed Virtualization distributed Cloud application. Distributed Virtualization Kernel (DVK) The rest of this article is organized as follows. Section II Management System (DVMS) refers to related works and background technologies. Section Host OS - 1 Host OS - 2 Host OS - 3 III describes the architecture of MoL as a Unikernel (MUK) and the design and implementation of its prototype. Partial performance evaluation results of the prototype are reported Node 1 Node 2 Node 3 in section IV and finally, Section V presents conclusions, in- Figure 2. Distributed Virtualization System architecture model. progress works, and future research projects. 1) Distributed Virtualization Kernel (DVK): It is the II. RELATED WORKS AND BACKGROUND TECHNOLOGIES core software layer that integrates the resources of the The most commonly adopted virtualization technologies cluster, manages and limits the resources assigned to each are VMs and Containers as isolated execution environments. DC. It provides interfaces for low-level protocols and Both are partitions of a physical computer, so that their services, which can be used to build a VOS, such as IPC, computing resources are limited by the latter. The architecture model of a DVS [14] is based on several GCS, synchronization, replication, locking, leader election, Virtualization and DOS [15, 16] technologies getting the fault detection, mutual exclusion, performance parameter benefits of both worlds. Due to its features, it is a good sensing, processes migration mechanism, etc. choice to offer high performance provider-class Cloud 2) Distributed Virtualization Management System (DVMS): services. In this sense, it presents attractive features for It is the software layer that allows the DVS administrator to Cloud service providers such as high availability, replication, both manage and monitor the resources of the cluster. elasticity, load balancing and process migration. In a DVS, 3) Container: It is a host-OS abstraction which provides an the administrator can build execution domains, called isolated environment to run the components of a VOS. A set Distributed Containers (DC), which can be extended beyond of related Containers makes up a DC. the limits of a physical machine or cluster node (Fig. 1). 4) Distributed Container (DC): It is a set of single Containers, each one being set up by the DVMS in the host- OS of each node. There is one DC per VOS, and a DC can span from one to all nodes. Only processes belonging to the same DC can communicate transparently between them