Configure the Optional Image Conversion File System¶
By default, qcow2 to raw image-conversion is done using the docker_lv file system. To avoid filling up the docker_lv file system, you can create a new file system dedicated for image conversion as described in this section.
Prerequisites
- The requested size of the image-conversion file system should be big enough to accommodate any image that is uploaded to Glance. 
- The recommended size for the file system must be at least twice as large as the largest converted image from qcow2 to raw. 
- The conversion file system can be added before or after stx-openstack is applied. 
- The conversion file system must be added on both controllers. Otherwise, stx-openstack will not use the new file system. 
- If the conversion file system is added after stx-openstack is applied, changes to stx-openstack will only take effect once the application is reapplied. 
- The image-conversion file system can only be added on the controllers, and must be added, with the same size, to both controllers. Alarms will be raised, if: - The conversion file system is not added on both controllers. 
- The size of the file system is not the same on both controllers. 
 
Adding a New Filesystem for Image-Conversion¶
- Use the host-fs-add command to add a file system dedicated to qcow2 to raw image-conversion. - ~(keystone_admin)]$ system host-fs-add <hostname or id> <fs-name=size> - Where: - hostname or id
- is the location where the file system will be added 
- fs-name
- is the file system name 
- size
- is an integer indicating the file system size in Gigabytes 
 - For example: - ~(keystone_admin)]$ system host-fs-add controller-0 image-conversion=8 +----------------+--------------------------------------+ | Property | Value | +----------------+--------------------------------------+ | uuid | 52bfd1c6-93b8-4175-88eb-a8ee5566ce71 | | name | image-conversion | | size | 8 | | logical_volume | conversion-lv | | created_at | 2020-09-18T17:08:54.413424+00:00 | | updated_at | None | +----------------+--------------------------------------+ 
- When the image-conversion filesystem is added, a new partition /opt/conversion is created and mounted. 
- Use the following command to list the file systems. - ~(keystone_admin)]$ system host-fs-list controller-0 +--------------------+------------------+-------------+----------------+ | UUID | FS Name | Size in GiB | Logical Volume | +--------------------+------------------+-------------+----------------+ | b5ffb565-4af2-4f26 | backup | 25 | backup-lv | | a52c5c9f-ec3d-457c | docker | 30 | docker-lv | | 52bfd1c6-93b8-4175 | image-conversion | 8 | conversion-lv | | a2fabab2-054d-442d | kubelet | 10 | kubelet-lv | | 2233ccf4-6426-400c | scratch | 16 | scratch-lv | +--------------------+------------------+-------------+----------------+ 
Resizing the File System¶
You can change the size of the image-conversion file system at runtime using the following command:
~(keystone_admin)]$ system host-fs-modify <hostname or id> <fs-name=size>
For example:
~(keystone_admin)]$ system host-fs-modify controller-0 image-conversion=8
Removing the File System¶
- You can remove an image-conversion file system dedicated to qcow2 image-conversion using the following command: - ~(keystone_admin)]$ system host-fs-delete <hostname-or-id> <fs-name> 
- When the image-conversion file system is removed from the system, the /opt/conversion partition is also removed. 
Note
You cannot delete an image-conversion file system when stx-openstack is in the applying,**applied**, or removing state.
You cannot add or remove any other file systems using these commands.
