Building Small Linux VMs for SDN and Kubernetes Experimentation
In my previous blog post, I discussed the need for small Linux VMs to demonstrate connectivity between different SDN segments or run applications that are only available on Linux. In this post, we’ll go through how to build these easily and quickly using Photon OS, an operating system developed by VMware. We’ll also explore how to customize the VM specification to meet specific requirements.
Photon OS: A Small but Powerful Linux Distro
Photon OS is a lightweight, minimalistic Linux distribution that is designed for cloud computing and SDN environments. It is built on top of the Ubuntu LTS base, and it includes only the essential packages needed for a small VM. The best part about Photon OS is that it comes pre-packaged with Virtual Hardware v13 (UEFI Secure Boot), which makes it an ideal choice for SDN and Kubernetes experimentation.
Creating a Small Linux VM using Photon OS
To create a small Linux VM using Photon OS, follow these steps:
1. Go to the Photon OS GitHub page and download the OVA file for the latest version of Photon OS.
2. Import the OVA file into your vCenter environment by right-clicking on the cluster and selecting “Deploy OVF Template.”
3. Create a new VM customization specification by clicking on “Menu” -> “Policies and Profiles” -> “VM Customization Specification” -> “New.” Give the specification a name (e.g., “VMSpec-Photon”), select Linux as the target guest OS, and set the other options as needed.
4. Clone the Photon OS VM to create a new VM using the template.
5. Power on the new VM and enter “root” as the username and “changeme” as the password. Change the password to your liking.
6. Shut down the VM and right-click on it to select “Clone to template.” This will create a template that you can use to deploy more VMs with the same configuration.
Customizing the VM Specification
The good thing about Photon OS is that it allows you to customize the VM specification to meet your specific needs. Here are some of the things you can customize:
1. Networking: You can specify the network interface and set the IP address, subnet mask, gateway, and DNS servers.
2. Storage: You can select the storage format (e.g., thin provisioned, thick provisioned, or eager zeroed) and set the disk size and format.
3. CPU and Memory: You can set the number of CPU cores and amount of RAM for the VM.
4. Disk controller: You can choose the disk controller type (e.g., IDE, SATA, or SCSI).
5. Firmware: You can select the firmware type (e.g., UEFI or BIOS) and set the Secure Boot options.
6. Timezone: You can set the timezone for the VM.
7. Customization script: You can add a customization script to execute post-deployment tasks, such as installing additional software or configuring network settings.
Future Posts and What’s Next
In future posts, we’ll explore how to update the package manager in Photon OS, install additional software, and set up Kubernetes tools for Tanzu environments. We’ll also discuss how to import the VM specification into other vCenter environments and deploy VMs with different network configurations.
Thanks for reading, and I hope this post helps you get started with building small Linux VMs for SDN and Kubernetes experimentation using Photon OS!