Liberating Virtual Machines from Physical Boundaries Through Execution Knowledge Yoshihisa Abe
Total Page:16
File Type:pdf, Size:1020Kb
Liberating Virtual Machines from Physical Boundaries through Execution Knowledge Yoshihisa Abe CMU-CS-15-147 December 2015 School of Computer Science Carnegie Mellon University Pittsburgh, PA 15213 Thesis Committee: Mahadev Satyanarayanan, Chair Dan Siewiorek Todd Mowry Kaustubh Joshi, AT&T Research Roxana Geambasu, Columbia University Submitted in partial fulfillment of the requirements for the degree of Doctor of Philosophy. Copyright c 2015 Yoshihisa Abe This research was supported by the National Science Foundation under grant numbers CNS-0833882, CCF- 1019104, IIS-1065336, and CNS-1518865; by the Defense Advanced Research Projects Agency under grant numbers FA8721-05-C-0003 and FA8650-11-C-7190; by the Moore Foundation under grant number 2160; by the Alfred P. Sloan Foundation under grant number 20121031; by an Intel Science and Technology Center grant; by the Quality of Life Technologies ERC (NSF-EEC-0540865); and by the Department of Defense under Contract No. FA8721-05-C-0003 for the operation of the Software Engineering Institute, a federally funded research and development center. Additional support was provided by Intel, IBM, Google, Bosch, Vodafone, Crown Castle, and the Conklin Kistler family fund. The views and conclusions contained in this document are those of the author and should not be interpreted as representing the official policies, either expressed or implied, of any sponsoring institution, the U.S. government or any other entity. Keywords: Virtualization, Migration, Operating systems, Cloud computing, Interac- tivity Abstract Hardware virtualization enables remote instantiation of computation through the preserved executability of encapsulated software. The large size of vir- tual machines (VMs), however, poses challenges in exploiting this strong fea- ture under the existence of resource constraints. In this thesis, we claim that the use of execution knowledge achieves the efficiency and timeliness of VM state transfer in such environments. We demonstrate its effectiveness in two concrete contexts in which the challenges materialize: 1) VM delivery over WANs, with network resource limitations, and 2) urgent migration of VMs under contention, with strict time requirements. In the context of VM delivery over WANs, we take advantage of the knowledge about past VM execution in- stances. We conduct the evaluation of vTube, a system for efficiently stream- ing virtual appliances, from both systems and human-centric perspectives. In the context of urgent migration of VMs under contention, we leverage current execution knowledge at the guest OS level. Our approach, called enlight- ened post-copy, uses this knowledge to expedite the resolution of contention between VMs. Our proposed solutions address the corresponding problems by providing VM performance as defined by critical metrics in their specific contexts. iv Acknowledgements I am truly thankful to my adviser, Prof. Mahadev Satyanarayanan, and my internal com- mittee members, Prof. Dan Siewiorek and Prof. Todd Mowry, for guiding me with invalu- able feedback and insights. I am also very grateful to my external committee members and long-term collaborators, Dr. Kaustubh Joshi and Prof. Roxana Geambasu, for their continued support and extensive contributions. The work on interactivity evaluation of VM systems would not have been feasible without our collaboration with Brandon Tay- lor. The past and current members of the Elijah Group, especially Jan Harkes, Benjamin Gilbert, Wolf Richter, and Kiryong Ha, have offered many opportunities for collaboration and productive discussions. Completing this thesis was made possible by Deborah Cavlovich and Catherine Copetas, who always provide great assistance to the members of the Computer Science Department. Last but not least, I am indebted to my parents for their invariable supportiveness throughout my graduate education. v vi Contents 1 Introduction 1 2 Background 7 2.1 Essential Properties of Virtualization . 7 2.1.1 Executability Guarantee . 7 2.1.2 Remote Instantiation of Computation . 9 2.1.3 Means of Encapsulation . 10 2.2 Related Work . 11 2.2.1 VM Delivery and Migration in WAN Environments . 11 2.2.2 VM Migration in Clouds . 12 2.2.3 Impact of Latency on Systems Usability . 14 2.2.4 Execution Knowledge and Proactive State Transfer . 16 3 VM Delivery over Wide-Area Networks 17 3.1 Problem and Objectives . 18 3.1.1 Use Cases . 18 3.1.2 Goals: Metrics of Importance . 21 3.1.3 Past Execution Knowledge . 22 3.2 vTube: Efficient Streaming of Virtual Appliances . 22 3.2.1 System Workflow . 23 3.2.2 Streaming Algorithm . 26 vii 3.3 Architecture and Implementation . 33 3.3.1 vTube Server . 33 3.3.2 vTube Client . 35 3.3.3 Session Handling . 36 3.4 Evaluation . 37 3.4.1 Set-Up . 37 3.4.2 Streaming Behavior . 39 3.4.3 Application-Level Performance . 40 3.4.4 Efficiency of Dynamic Streaming . 43 3.4.5 Trace Coverage . 45 3.4.6 Comparison to VM Distribution Networks . 47 3.5 Summary . 48 4 Interactivity Evaluation of Delivered VMs 49 4.1 Properties of VM Access Methods . 50 4.1.1 VM Streaming and Remote VM Access . 50 4.1.2 Impact of Bandwidth and Round-Trip Latency . 52 4.1.3 Goals of Interactivity Evaluation . 53 4.2 Design of Interactivity Evaluation . 53 4.2.1 Design Variables . 54 4.2.2 System Set-Up . 56 4.2.3 Test Configurations . 58 4.2.4 Procedure . 60 4.2.5 Test Applications . 61 4.3 Results . 64 4.3.1 User Satisfaction . 64 4.3.2 Feelings of Annoyance . 67 4.3.3 Mental Demands . 70 4.3.4 Sense of Accomplishment . 71 viii 4.3.5 Qualitative Observations . 71 4.3.6 Implications on the effectiveness of VM streaming . 75 4.4 Summary . 75 5 Urgent Transfer of VMs under Contention 77 5.1 Problem and Objectives . 78 5.1.1 Mechanics of Migration . 79 5.1.2 Analysis of Live Migration . 80 5.1.3 Goals: Metrics of Importance . 85 5.1.4 Current Execution Knowledge . 86 5.2 Enlightened Post-Copy Migration . 88 5.2.1 Guest’s Enlightenment . 89 5.2.2 Integration into State Transfer . 90 5.2.3 Design Trade-Offs . 90 5.3 Architecture and Implementation . 91 5.3.1 Guest OS . 93 5.3.2 Hypervisor . 94 5.4 Evaluation . 95 5.4.1 Set-Up and Workloads . 95 5.4.2 End-to-End Performance . 98 5.4.3 Comparison with Baseline Approaches . 107 5.4.4 Costs of Enlightenment . 108 5.5 Summary . 109 6 Conclusion 111 6.1 Future Work . 113 6.1.1 Enhancements to VM Streaming . 113 6.1.2 Thick Clients and Thin Clients . 114 6.1.3 Extensions to Enlightened VM Migration . 114 ix 6.1.4 Source of Execution Knowledge . 115 6.1.5 Future Abstraction for Encapsulating Computation . 116 6.2 Concluding Remarks . 116 Bibliography 117 x List of Figures 1.1 Thesis Outline . 5 2.1 Comparison of Virtualized and Non-Virtualized Environments . 9 3.1 Repository of Archival VMs . 20 3.2 vTube Streaming Model . 23 3.3 System Workflow of vTube . 24 3.4 Example of VM State Access Commonality between Two Traces . 25 3.5 Example of VM state Access Orders in Two Traces . 26 3.6 Overview of Clustering Analysis . 27 3.7 Clustering in Individual Traces . 28 3.8 Clustering across Different Traces . 28 3.9 Cluster Selection for Delivery . 29 3.10 Example of Cluster Size Distribution for Riven Virtual Appliance . 31 3.11 Cluster Transfer with Execution Control . 31 3.12 Cluster Streaming in User Session . 32 3.13 vTube Architecture . 34 3.14 Summary of Network Configurations . 38 3.15 Summary of Virtual Appliances . 38 3.16 Behavior of Streaming Riven Virtual Appliance . 40 3.17 Mplayer Performance . 41 3.18 Selenium Performance . 42 xi 3.19 Miss Rates as Function of Trace Count . 46 4.1 Computing Models of VM Streaming and Remote VM Access . 51 4.2 System Set-Up for User Studies . 57 4.3 Ratings of Satisfaction with System Performance . 65 4.4 Bandwidth-Latency Ranges Suitable for VM Streaming and VNC in Terms of Satisfaction . 66 4.5 Ratings of Feelings of Annoyance . 68 4.6 Bandwidth-Latency Ranges Suitable for VM Streaming and VNC in Terms of Annoyance . 69 4.7 Ratings of Mental Demands . 70 4.8 Sense of Accomplishment . 72 5.1 Overview of Migration Timings and State Transfer . 79 5.2 Live Migration Algorithm . 81 5.3 Behavior of Migrating Memcached VM with qemu-kvm . 82 5.4 Behavior of Migrating Memcached VM with Major Hypervisors at 10 Gbps 84 5.5 Scenarios Demanding Migration with Fast Execution Transfer . 87 5.6 Workflow of Enlightened Post-Copy Migration . 89 5.7 Implementation of Enlightened Post-Copy . 92 5.8 Experiment Set-Up . 96 5.9 End-to-End Results with Memcached . 99 5.10 Latency with Memcached at 10 Gbps . ..