Goodbye virtual machines, hello microVMs

Small Scale

Advanced Tooling with Ignite

I extended the tooling created for Footloose described in the first article to create, show, configure, and clean up microVM stacks. To get started with the wrapper [8], just download the sources with

git clone https://github.com/richnusgeeks/devops.git
pushd CloudInABox/MicroVMs/scripts

You could use cd instead of pushd, but I prefer pushd for its intelligence. The wrapper script execution should show you a help screen (Figure 4).

Figure 4: Wrapper utility help screen for microVMs.

The top level wrapper script just takes a simple configuration (Listing 3). Simply execute

Listing 3

footloose.cfg

# Name     Count Image                          Kernel                           Cpu Memory Disk Ports([hostPort:]containerPort)
ubuntu1804 1     weaveworks/ignite-ubuntu:18.04 weaveworks/ignite-kernel:5.13.3  2   2G     20G  22,38080,52812,58080
centos8    1     weaveworks/ignite-centos:8     weaveworks/ignite-kernel:5.13.3  2   2G     20G  22,38080,52812,58080
kafka      3     weaveworks/ignite-ubuntu:20.04 weaveworks/ignite-kernel:5.12.18 2   2G     20G  22,2181,8080,9092,38080,52812,58080
spark      3     weaveworks/ignite-ubuntu:20.04 weaveworks/ignite-kernel:5.12.18 2   2G     20G  22,7077,8080,8081,38080,52812,58080
consul     3     weaveworks/ignite-ubuntu:20.04 weaveworks/ignite-kernel:5.13.3  1   2G     20G  22,52812,58080,58500
hashiui    1     weaveworks/ignite-ubuntu:20.04 weaveworks/ignite-kernel:5.13.3  1   2G     20G  22,52812,53000,58080
sudo ./create_micro_vms_stack.sh create

to bring up the defined microVM stack. The creation of a stack also triggers an Ansible ping to the spawned microVMs to ensure SSH connectivity. Figures 5 and 6 show some portions of the creation output of 16 microVM stacks on my laptop. The commands

sudo ./create_micro_vms_stack.sh test <ansible role name, e.g., spark>
sudo /create_micro_vms_stack.sh delete
Figure 5: Starting microVMs stack.
Figure 6: Info about created microVMs stack.

configure the created microVMs with the necessary software and clean up the enacted stack (Figure 7).

Figure 7: topping microVMs stack.

Conclusion

AWS Firecracker is a breakthrough technology that provides the best from both the container and virtual machine worlds. Ignite further creates a user-friendly declarative GitOps mechanism that provides additional functionality over Firecracker to run OCI containers under strong isolation of hardware-assisted virtualization. The resulting microVMs are highly useful in all use cases, ranging from development to production environments. Adoption of these microVM-based instant stacks will boost engineering effectiveness while slashing your infrastructure bill.

Infos

  1. "Goodbye virtual machines, hello container machines" by Ankur Kumar, ADMIN , issue 68, 2022, pg. 46, https://www.admin-magazine.com/Archive/2022/68/Goodbye-virtual-machines-hello-container-machines
  2. "Goodbye cloud VMs, hello laptop VMs" by Ankur Kumar, ADMIN , issue 69, 2022, pg. 22, https://www.admin-magazine.com/Archive/2022/69/Goodbye-cloud-VMs-hello-laptop-VMs
  3. Firecracker: https://firecracker-microvm.github.io/
  4. Firecracker 4,000 microVM demo: https://github.com/firecracker-microvm/firecracker-demo
  5. Ignite GitHub project: https://github.com/weaveworks/ignite
  6. Footloose on GitHub: https://github.com/weaveworks/footloose
  7. Ignite API object documentation: https://ignite.readthedocs.io/en/stable/declarative-config/
  8. Wrapper utilities: https://github.com/richnusgeeks/devops/tree/master/CloudInABox/MicroVMs/scripts

The Author

Ankur Kumar is a passionate free and open source software (FOSS) hacker and researcher and seeker of mystical life knowledge. He explores cutting-edge technologies, ancient sciences, quantum spirituality, various genres of music, mystical literature, and art. You can connect with Ankur on https://www.linkedin.com/in/richnusgeeks and explore his GitHub site at https://github.com/richnusgeeks for other useful FOSS pieces.

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy ADMIN Magazine

SINGLE ISSUES
 
SUBSCRIPTIONS
 
TABLET & SMARTPHONE APPS
Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

comments powered by Disqus
Subscribe to our ADMIN Newsletters
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs



Support Our Work

ADMIN content is made possible with support from readers like you. Please consider contributing when you've found an article to be beneficial.

Learn More”>
	</a>

<hr>		    
			</div>
		    		</div>

		<div class=