Presentation is loading. Please wait.

Presentation is loading. Please wait.

System-level Virtualization for HPC: Recent work on Loadable Hypervisor Modules Systems Research Team Computer Science and Mathematics Division Oak Ridge.

Similar presentations


Presentation on theme: "System-level Virtualization for HPC: Recent work on Loadable Hypervisor Modules Systems Research Team Computer Science and Mathematics Division Oak Ridge."— Presentation transcript:

1 System-level Virtualization for HPC: Recent work on Loadable Hypervisor Modules Systems Research Team Computer Science and Mathematics Division Oak Ridge National Laboratory

2 ORNL Systems Research Team (SRT)‏  Ferrol Aderholdt (TNTech/ORAU)‏  Christian Engelmann  Thomas Naughton  Hong Ong  Stephen Scott  Anand Tikotekar  Geoffroy Vallée

3 Why Virtualization?  Decouple operating system / hardware  Server consolidation (utilization)‏  Development & Testing  Reliability  High availability / Fault Tolerance  Non-stop computing via VM migration  Customization of execution environment  Specialize for an application / user  Environment consistency

4 Motivation  Why do dynamic customization?  Tailor execution environment  Experimentation at runtime  Why do dynamic customization in hypervisor?  Perform system-level adaptation  Basis for future capabilities (e.g., QoS or FT)‏  Dynamic to avoid VM teardown (i.e., avoid recompile-reboot)‏  Debugging / Instrumentation (e.g., perf. analysis)‏  Add functionality as needed

5 Overview  Issue: Current Xen is very monolithic  Static customization via rebuild & reboot  To change must shutdown active VMs & save all state  Limits experimentation / investigation  Plan: Extend Xen hypervisor to allow for changes at runtime

6 Loadable Hypervisor Modules  Mechanism for runtime changes to VMM  Modeled after Linux’s Loadable Kernel Modules  Maximize reuse to help speed development  Maintain consistent file format  Relocatable ELF object with additional segment

7 Xen Terminology  Domains: term used regarding OS’s running on VMM  User domains (domU)‏  Administrative domain (dom0)‏  Hypercall: call from domain to VMM  Analogous to a system call (user to kernel)‏ Hardware Xen (vmm)‏ Host OS (dom0)‏ GuestOS (domU)‏ GuestOS (domU)‏ Xen: Type-I hypervisor

8 LHM: Changes to HostOS (dom0)‏  Headers for LHM compilation  Slightly modify module utilities (rmmod & lsmod)‏  Add /proc entry to access addresses of Xen symbols  Export VMM symbol info to dom0  Modify modules sub-system to detect / support LHM  Patch LHMs with VMM symbol info  Make hypercall to map LHM into VMM

9 LHM: Changes to VMM (xen)‏  New hypercall – HYPERVISOR_do_lhm_op()‏  Map (load) LHM into VMM  Unload LHM from VMM  List loaded LHMs  LHM “mapping” / loading  Allocated memory resources remain in HostOS (dom0)‏  Regions mapped into VMM & write-protected from HostOS

10 Symbols and Locations  Linux kernel info  Standard feature of HostOS (dom0)‏  Provides kernel symbol names, types & addresses  Exported via /proc/kallsyms  Xen hypervisor info  New feature of HostOS (dom0)‏  Provides hypervisor symbol names, types & addresses  Exported via /proc/hallsyms  Add new hypercall for LHM based info /proc/hallsyms Host OS [xen symtab] VMM kernel /proc/kallsyms [linux symtab]

11 Example: Loading a LHM  Compile LHM  Standard Linux build environment (kbuild)‏  Load LHM  Standard Linux utilities (insmod)‏  Enhanced Linux modules subsystem detects LHM  Set LHM flag in struct module  Linux allocates space for module (in dom0)‏  Patches undefined symbols with Xen addresses  Ex. Xen’s printk()‏  Module is “hi-jacked”  Hypercall invoked to map into Xen

12 Build module (gcc)‏ Load module (insmod)‏ init_module()‏ Perform sys_init_module()‏ Load module & fixup symbols - copy data - detect LHM - patch UNDEF symbols hallsyms_lookup() Remove (skip) any Linux ties - skip: sysfs add - skip: module list add Make hcall to “map” module Write protect memory from Linux Kernel User Lookup Xen symbol info Perform hypercall LHM_map_module()‏ - Add new LHM to list - If exist, call LHM’s init()‏ Host OS (dom0)‏ VMM (xen)‏

13 Mapping of LHM

14 Current Status  Initial LHM prototype  Based upon Xen-3.2.1 & Linux-2.6.18.8-xen.hg  Supports x86-32 & x86-64  Limited testing at this point  See SRT website, http://www.csm.ornl.gov/srt/lhm/

15 Conclusion  Virtualization for HPC  Dynamic modification for HPC VMM  Enable new capabilities (e.g., runtime instrumentation)‏  Developed new VMM mechanism  Based on Linux modules  Called Loadable Hypervisor Modules (LHM)‏

16 Future Work  Continue LHM development  Stabilize and release  Continue first LHM use case  Hypervisor instrumentation  Help in debugging & performance analysis (e.g., traces, counters)‏  Investigate other use cases  Adapt VMM policies at runtime (e.g., resilience?)‏  VM Introspection

17 Questions? Supported by: This work was supported by the U.S. Department of Energy, under Contract DE-AC05-00OR22725.

18 Backup / Additional Slides  Extra slides…

19 Hypervisor-level Dynamic Instrumentation  First use case of LHM  Instrument hypervisor code at runtime  Instrument at function boundaries (except Type-4)‏  Instrument without modification to target source (except Type-4)‏  No attempts made to modify active functions (in use on stack)‏  i.e., only affects uses after insertion of instrumentation point

20 Hypervisor-level Dynamic Instrumentation (2)‏  Instrumentation Terminology (Tamches:2001)‏  “code splicing” – add additional functionality to code  “code replacement” – replace functionality of code by overwriting a portion  Locations for Hypervisor Instrumentation Point (HIPT)‏  Type-1: code replacement of an entire function  Type-2: code splicing at the function entry  Type-3: code splicing at the function exit  Type-4: code splicing at pre-defined location in user specified code (label)‏

21 Implementation Details  Add new system call sys_instr() to Host OS  Sets up instrumentation point structure  Invokes appropriate hypercall (add/del) with structure info  Add new hypercall do_instrument() to VMM  Invokes add or delete of instrumentation point  Maintains list of active instrumentation points  HIPT Add  Replace old_address with new_address  Stores clobbered addresses for full restoration at HIPT delete  HIPT Delete  Restores original instructions at old_address (instrumented point)‏  Remove item from list

22 Current Status  Instrumentation support under active development  Requires LHM support in Xen  Architectures  Intel x86-32  Intel x86-64  Future updates on SRT website, http://www.csm.ornl.gov/srt/lhm/


Download ppt "System-level Virtualization for HPC: Recent work on Loadable Hypervisor Modules Systems Research Team Computer Science and Mathematics Division Oak Ridge."

Similar presentations


Ads by Google