Migrating Image Library from Local Drive to Persistent Volume
This guide provides step-by-step instructions for migrating the Private Cloud Director Image Library backend from a local drive (file backend) to a volume (block storage service backend), along with important considerations for High Availability (HA) mode and multi-host Image Library configurations.
Overview
By default, the Image Service in the Private Cloud Director uses a local file-based backend to store VM images. For enhanced scalability, persistence, and centralized management, it is recommended that the image library be migrated to use a persistent storage volume.
Migrating to a persistent storage backend is particularly beneficial in High Availability (HA) environments and supports future scalability through multi-host image library configuration.
Prerequisites
The Private Cloud Director environment is already deployed with a functional Image Library using the file backend.
A block storage service compatible storage backend is configured and available.
At least one available volume for storing the image library.
Image Library role is assigned on one or more hosts.
Administrator access to all relevant nodes and services.
Downtime window for migration (this process involves stopping image services).
Step-by-Step Instructions
Step 1: Prepare the Volume
Create a new volume with sufficient capacity to hold all existing images (plus future growth).
Attach the volume to the host where the Image Library role is currently assigned.
On the host, identify the volume device (e.g., /dev/vdb) and mount it:
Copy existing image data from local image library (default: /opt/pf9/pf9-glance/images) to the mounted volume:
Update the system to mount the volume persistently:
Step 2: Update Image Library Configuration
Edit the image library service configuration file (e.g., /etc/glance/glance-api.conf) and set the following backend settings:
Restart the image library service:
Verify the backend is now using block storage volume:
Info
Ensure the Image Service on each node is configured correctly with the same backend settings and the volume is mounted identically across all nodes.
High Availability and Multi-Host Image Library Considerations
HA Mode Support: Using a blocks storage volume backend for the image library is fully supported in HA mode, as the block storage service provides persistent and shared storage accessible across multiple controller nodes.
Multi-Host Image Library: If multiple hosts have the Image Library role:
The persistent storage backend ensures centralized image access without needing data synchronization between nodes.
All image library nodes must have access to the persistent storage service and appropriate authentication configured.
Last updated
Was this helpful?
