Introduction

Branch

master

Purpose

This is functional specification for the feature "Base image update facility", the purpose is that we need to be able to update existing VM with new base image.

Feature Specifications

  • When base image update has been performed (e.g. Windows patches applied to the golden master image) then on vm restart there is a need of pointing the VM at the new golden master.
  • We need to be able to update existing VMs with a new base image to support the pooled desktop.
  • Since the template should be immutable, if the new version of template is created, then it is another template. So vm should boot up using the new template.
  • Adding to this, we should have a method to reset a vm on reboot, i.e, discard the root disk and create a new one whenever the vm is rebooted.
  • Currently we support base image update and reset a vm on reboot for the VMs deployed using templates.

Use cases

The usual way to point out to the new base image is to destroy the machine and recreate with the new disk.

But this causes problem due to the change of ipaddress.To persist the network identity of the existing VMs even after base image update this feature can be used.

Reset a vm on reboot is needed in the usecases like, secure environments that need a fresh start on every boot and to the desktops that should not retain state.

Architecture and Design description

  • The orchestration being requested is : disconnect the root disk >> destroy root disk >> create a new disk from (possibly new) template >> attach new disk as root disk to the vm
  • Some changes to the RestoreVM api can achieve this as this api persists the netowrk identity.
  • Adding the same what we do for the upgrade of system vm template.
  • The api should just take a reference to the new template.
  • To support reset a vm on its reboot we need to add a (boolean) parameter in the service offering which decides whether the VM’s root disk should be discard  or not whenever vm is rebooted.

web services APIs

restoreVirtualMachine: This api is to reset the virtual machine with new volume .

This needs to be modified by providing the new template id to the api from which it creates the new volume using the new template id.

UI flow

  • To support reset vm on boot, a checkbox (Say volatile VM) need to be there while creating service offering and display the same after creation. 

Test cases

TBD

Appendix

Appendix A:

Appendix B:

  • No labels