A default operating system (OS) image is a bootable disk containing an OS and all of the configuration settings for the OS, such as drivers. You use a default OS image to create bootable virtual machines with specific configurations.
To use default OS images, you must install the latest version of OpenShift Virtualization. You then create a persistent volume claim (PVC) by using the OpenShift Container Platform web console to upload a default OS image to the PVC. After uploading, you create virtual machines or virtual machine templates from the uploaded images by using the wizard in the web console.
Follow these steps to create a persistent volume claim (PVC), which you use to upload and save default operating system (OS) images.
You must be logged in as a user with the
os-images.kubevirt.io:edit RBAC role or as an administrator.
Select a local image of a bootable disk that you want to upload and save as a default OS image.
In the OpenShift Container Platform web console, click Storage > Persistent Volume Claims in the sidebar menu. The Persistent Volume Claim page displays.
Click the Create Persistent Volume Claim button and select the With Data upload form option.
Complete the Upload Data to Persistent Volume Claim form to create a PVC that is used to upload and save default OS images.
Click Browse and locate a bootable image to upload and save as a default OS image.
Select the Attach this data to a Virtual Machine operating system check box.
Select the OS of the bootable disk that you want to upload from the Operating System list.
Select the storage class you want to use in the Storage Class list.
Enter the size of the PVC you are creating in the Size fields.
Select the Access Mode.
Click Create to create the PVC.
The Persistent Volume Claim Details screen displays information about the PVC that you created.
After you have created a persistent volume claim (PVC) for default operating system (OS) images, you create a new virtual machine or virtual machine template from a default OS image that you uploaded to the PVC.
You can create virtual machines and virtual machine templates from default OS images with non-administrator user privileges. You need administrator privileges to upload and save default OS images to PVCs.
When you created the PVC, you selected the Attach this data to a Virtual Machine operating system check box.
In the OpenShift Container Platform web console, click Workloads > Virtualization in the sidebar menu. The Virtualization page displays. Use web console Help or existing documentation to create virtual machine templates.
Create a virtual machine or virtual machine template from an uploaded default OS image.
Select Create Virtual Machine > New with Wizard. The Create Virtual Machine wizard displays.
On the General wizard page, select an OS from the Operating System list that displays the (Source available) label next to the OS and version name. The (Source available) label indicates default OS images are available for this OS.
Ensure that the Clone available operating system source check box is selected.
Click the Review and Confirm button.
On the Review and confirm your settings wizard page, review information about your virtual machine and change them, if required.
Click Create Virtual Machine to create your virtual machine. The Successfully created virtual machine page displays with links to See virtual machine details or Go to list, to display the list of virtual machines and virtual machine templates.