Starting and stopping virtual machines is a routine part of using cloud computing resources. There are two basic...
By submitting your personal information, you agree that TechTarget and its partners may contact you regarding relevant content, products and special offers.
options for deploying a VM in the cloud: Users can make a copy of a preconfigured virtual machine image, or golden master, or they can assemble a custom VM image on demand.
To start a VM, select a machine image from the cloud catalog. When deploying an application that uses an Apache Web server and a JBoss application server, select a Linux image with those components already installed on it. If you are a .NET programmer setting up a development environment, choose a Windows OS configured with your favorite development tools. In addition to choosing a VM image that’s equipped with required software, ensure software is up to date and has been patched. Once you select an image, you’re ready to deploy the VM in the cloud.
Golden images: minimal effort for limited options
Using golden images has several advantages. Paramount is that it ensures consistency among VM images. In addition, minimal effort and time is required to start a copy of an existing image. End users do not need to know how to install libraries or additional packages; they can depend on cloud administrators to maintain golden master images.
The disadvantage of this method is end users have limited options; the image catalog likely will contain commonly used images but not infrequently used combinations of components. For a more specialized virtual machine image, you have to start with a golden master and install or remove components as needed. If end users deploy a custom image frequently, they should keep a copy of that image on hand. But this means the user is responsible for keeping the image patched, negating a major benefit of using golden images.
Consider an instance in which specialized images are not necessary: Your Web application has been running in a load-balanced environment for several weeks after you had configured the servers. If you have a sudden spike in application use, you might want to add more servers to the load-balance cluster. In this case, you want identical images running across the cluster. Using a copy of the same golden master ensures you have the same image. If you were to rebuild the image, the system might incorporate a different version of one of the components. This could happen when a new version of a component is released between the time other images are created and when you add VMs to the cluster.
Up-to-date components with assembly on demand
Building images each time you deploy a new instance allows users to create an image with only the components they need. A cloud user likely would start with a base OS image and then install application stack components -- databases, application servers and Web servers. However, without the use of tools, building on demand is impractical for frequent deployments. In this case, consider using a configuration management tool, such as Chef or Puppet, which allows you to specify components you want to include in an image. If it’s vital for images to have the latest versions of applications and patches, assembling them on demand is the best option. For example, if you have a standard configuration for database servers, creating a Chef or Puppet script to build the image ensures you have the latest version of necessary components.
Assembling on demand also helps maintain consistency when configuring across servers, since database administrators are less likely to perform ad hoc patches on out-of-date copies of golden master images.
The two methods of deploying VMs in the cloud -- creating golden master images and creating on-demand iterations -- are not mutually exclusive. When you need to create a cluster of servers, for example, you could use a configuration script to assemble a custom image that becomes a golden master image. Start by creating a VM image with your configuration management tool and then create multiple VM instances using that image. In this scenario, keep the golden master as long as you would need to add more virtual servers to the cluster.
There is no single way to assemble and deploy images in a cloud environment. Golden masters work well in cases when image consistency is paramount; assembly on demand is a better option if you need to ensure machines are running the latest versions of software components.
Dan Sullivan, M.Sc., is an author, systems architect and consultant with over 20 years of IT experience with engagements in advanced analytics, systems architecture, database design, enterprise security and business intelligence. He has worked in a broad range of industries, including financial services, manufacturing, pharmaceuticals, software development, government, retail and education, among others. Dan has written extensively about topics ranging from data warehousing, cloud computing and advanced analytics to security management, collaboration, and text mining.