Creating an image from ISO

Follow these instructions to create a PowerVC image from an operating system installation ISO image file.

Prerequisites

Before creating a virtual machine, ensure that your environment meets these prerequisites:

  • When using PowerVM® NovaLink for management, the NovaLink software must be installed on the hosts.
  • When you use Hardware Management Console (HMC) for management, it must be configured and managing the hosts.
  • PowerVC must be managing the storage, network, and hosts to use with the virtual machine.
  • The installation ISO must be available.

Creating a PowerVC virtual machine

Follow these steps to create a virtual machine for the first time in PowerVC.
Note:
  • If you are running PowerVC software-defined infrastructure, then the NovaLink partition is identified as a Virtual I/O Server (VIOS)
  • If you are running KVM, then its Host Operating System is identified as the VIOS.
Table 1. Creating an initial virtual machine in PowerVC
Step # Action Summary Where to perform Details
1 Create a boot volume. PowerVC Open PowerVC, go to the storage panel, select the Data Volumes tab, select create, and complete the create volume dialog. Ensure that the specified size is large enough to serve as the boot volume for the virtual machine that is selected to deploy later. Next, click Create Volume.
2 Create an image. PowerVC Go to the Images page, click Create, and provide the required information. Ensure that you specify the operating system type and endianness that match the ISO you use for the installation.

Select Add Volume, then select the volume that is used in the prior step, and mark the volume as part of the boot set. Click Create to finish the image creation.

3 Deploy the image. PowerVC The deploy dialog offers storage connectivity group choices that are applicable to where the image volume resides. Add an appropriate network, change any other settings that are wanted, and click Deploy.
4 Shut down the virtual machine. PowerVC After deployment completes and the virtual machine shows Active status, stop the virtual machine. The virtual machine will not boot since the boot disk has no data on it yet.
5 Copy your install ISO to an accessible location. Virtual I/O Server (VIOS) For HMC managed systems, use scp to copy your install ISO image to the VIOS.
NovaLink or KVM For NovaLink managed systems, use scp to copy your install ISO image to the NovaLink partition.
6 Attach the install media to the virtual machine. NovaLink or KVM
  1. Run pvmctl vom upload to copy your install ISO into the virtual optical media repository on the VIOS. You can get the VIOS ID by running pvmctl vios list.
  2. Run pvmctl scsi create to attach the newly uploaded virtual optical repository to the new virtual machine.
VIOS, HMC
  1. In the VIOS, use lsrep to check for a media repository for the ISO file.
  2. Run mkrep -sp rootvg -size <size> to create a new media repository for the ISO file if no media repositories are on the VIOS.
    Note: Make sure that rootvg has sufficient free space. Run chrep -size <size> to increase the repository size.
  3. Run mkvopt -name <name> - file <iso file name> to create the virtual optical disk.
  4. Use the HMC to find the logical partition (LPAR) ID.
  5. In the VIOS, run lsmap -all, then find the vhost from the output.
  6. Run mkdev -fbo -vadapter <vhost of your logical partition> to return the VTD name.
  7. Run loadopt -disk <vopt name> -vtd <vtd> to load the virtual DVD into the virtual DVD drive.
7 Start the virtual machine and run the operating system installer. PowerVC
  1. Restart the virtual machine.
  2. Launch the virtual console by going to the Virtual Machine details page and select the Console tab.
  3. Navigate through the installation screens.
Note: When installing the operating system on a KVM on Power® virtual machine, you must use the virtual machine console through the PowerVC user interface to access the virtual machine. Other access methods such as the virsh console will not work.
8 Prepare the virtual machine for capture. PowerVC See Capturing a virtual machine for instructions.
9 Capture the virtual machine to a new image. PowerVC Shut down the virtual machine. Run the Capture image action against the virtual machine.

Now you have a deployable image that can automatically activate and configure itself.

10 Delete the volume and the image. PowerVC The volume from step 1 and image from step 2 can be deleted unless you want to create more images.