Export and import images using GUI

Starting PowerVC 2.0.2, export or import API are enhanced to result into an OVA package. PowerVC GUI allows to export or import OVA package across multiple PowerVC instance. You can also register an existing IBM COS container to upload or download an image from IBM Cloud Object Storage.

Prerequisites
  1. Register the backup node: Register the remote or local PowerVC management node as backup node. This node is configured to host the cinder-backup service which performs import or export operations. For details, see Registering a backup node.
  2. Register the IBM COS: Register an existing IBM COS container if you want to upload or download an image OVA to Cloud Object Storage container (optional). For details, see IBM Cloud Object Storage.

Export an image to a backup node without uploading to IBM Cloud Object Storage

When an image is exported, its compressed OVA tar.gz is created on the backup node that has been selected. If it is not a targeted export, the scheduler selects the most appropriate backup node that has cinder backup service up, has sufficient space available and is the least used that is, with minimum number of image backups on it.

You can export an image to a backup node either through the GUI or through the Export or import image API.

Perform these steps to export an image without uploading it to Cloud Object Storage.
  1. Go to the Image list page, select an image to export, and click Export.
  2. Provide a display name. Select a backup node where you want to export the image. If a node is not selected, one of the available backup nodes is selected by the scheduler. For exporting to backup node without uploading to COS, deselect Upload to COS, and click Export.
You can view the uploaded images on the Images list tab of the Backup nodes page. Images that are successfully exported are in Available state. The image OVA file is available in the backup_ova_path set in the /etc/cinder/cinder.conf file in the backup node. By default, the path is /var/opt/ibm/powervc/image-ovas. To discover any OVA files prior to the import operation, this directory and any OVA file that is copied to this directory must be created with 0755 permission and cinder:cinder owner and group. Make sure that no export operation is in progress.

Upload an exported image to IBM Cloud Object Storage

If you have an existing IBM Cloud Object Storage account, you can register the IBM Cloud Object Storage bucket into PowerVC. This allows you to export an image and upload to COS. You also have an option to select the COS bucket that you want the image to be uploaded to. The image OVA exported to the remote backup is uploaded to the COS bucket. If no COS bucket is specified, the default COS (if set) associated for the backup node is chosen and used for upload.

Note: The Upload to COS option is selected by default. If no COS bucket is selected and no COS default is associated with the chosen backup node, the export image operation fails. For exporting to the backup node without uploading to COS, deselect Upload to COS, and click Export. You can also set Upload to COS to false using Export or import image API.
Perform these steps to upload an image to COS while exporting it to the backup node.
  1. Go to the Image list page, select an image to export, and click Export.
  2. Select a backup node.
  3. The Upload to COS option is selected by default. Select the COS bucket where you want the image to be uploaded.
  4. Click Export.
After the image OVA is exported to the backup node, it is then uploaded to the COS bucket and the image OVA file is deleted from the backup node. You can view the image backup on the Images list tab of the Backup nodes page. Images that are successfully uploaded are in Uploaded state.
You can also upload an image to COS while exporting to backup node by using the Export or import image API.
Note: In a case where the image upload fails, the image OVA is not deleted from the backup node. You can retry uploading the image by using the Upload to COS option or the Export or import image API.
The uploaded image OVA is listed in the IBM COS bucket on the IBM Cloud console as well under the objects list for the bucket.

Import an image from a backup node

When you import an image from the backup node to PowerVC an image is created on PowerVC and the volumes are restored on SAN storage.

Perform these steps to import an image from the backup node.
  1. Go to the Image list, select an image backup from the Backup nodes tab, and then click Import.
  2. Provide a display name for the image.
  3. Select a storage template to be associated with the image volumes.
  4. Backup node for an available image backup is preselected as the backup node on which the image OVA exists. Provide if any description is required.
  5. Click Import image.
Upon successful import, the image, which is in Active state, is listed in the Image list.

Import an image from a backup node after downloading it from IBM Cloud Object Storage

You can import an image from IBM Cloud Object Storage to PowerVC. The image OVA is downloaded from COS to the backup node, and imported to PowerVC. An image is created on PowerVC.

Perform these steps to import an image from the backup node after downloading it from COS.
  1. Go to the Image list, select an image OVA from the COS tab, and then click Import.
  2. Provide a display name for the image.
  3. Select a storage template to be associated with the image volumes.
  4. Select a backup node. You can select any backup node irrespective of the one from where the image was uploaded.
  5. Provide if any description is required.
  6. Click Import image.
Upon successful download of image and import to the backup node, the image will be listed as Active in PowerVC.

For API details, see Export or import image.

Import a RAW image or OVA image (created using powervc-image CLI) from a backup node

Complete these steps to import a raw image from the backup node.
  1. Register backup node (local or remote) in PowerVC.
  2. Copy or download the raw / OVA images on /var/opt/ibm/powervc/image-ovas to the backup node. This location is a configurable and can be changed by modifying backup_ova_path which is set in the /etc/cinder/cinder.conf file in the backup node. By default, the path is /var/opt/ibm/powervc/image-ovas. To discover any raw / OVA files prior to the import operation, this directory and any raw / OVA file that is copied to this directory must be created with 0755 permission and cinder:cinder owner and group.
    Notes:
    • Make sure that no export operation is in progress.
    • For OVA images created using powervc-image CLI, only uncompressed files are supported (with .ova extension). If OVAs are compressed, extract them before performing steps 1 and 2.
  3. On the GUI, navigate to Storage > Backup nodes.
  4. Click on the registered backup node and navigate to Image list. Click Discover. If you are using REST API, see Discover Images API. The images discovered are listed under Image list.
  5. Import OVA files by using GUI by completing the steps mention in the Import an image from a backup node of this topic or by using the REST API. Raw files can only be imported through Import REST API.