Description of problem:
Currently director only deploys glance with local file, Ceph, or swift backends.
We need to have NFS support as well for glance
* We essentially lock out the larger storage vendors who support NFS but are not already integrated.
* We hurt POC cases where setting up a random NFS server is easy, but Ceph deployment is more complicated/resource intensive/time consuming
* We essentially require swift or ceph for HA use case.
On review upstream: https://review.openstack.org/#/c/199152/
How i tested:
Create a NFS export reachable from the overcloud. I'm using virtual
setup, so i'm exporting from the bare metal host.
yum -y install nfs-utils
systemctl start rpcbind
systemctl start nfs-server
setsebool -P nfs_export_all_rw 1
mkdir -p /export/glance
chown -R nfsnobody:nfsnobody /export
echo "/export/glance *(rw,sync,no_root_squash)" > /etc/exports
Set these parameters on the overcloud heat stack (i used an extra
environment file, but the workflow with Tuskar might be different):
You can verify that everything works as expected by uploading a glance
image and launching an instance in the overcloud.
And verify that on the bare metal the volume appeared in the exported
You can see the mount on the controllers:
mount | grep glance
And any image files present on the NFS host:
Typo in the testing steps above -- use all_squash instead of no_root_squash when exporting the directory on NFS host:
echo "/export/glance *(rw,sync,all_squash)" > /etc/exports
Wasn't able to create an image with glance command.
In order to overcome, had to:
1. Apply this patch: https://gist.github.com/jistr/08d3d6ae82f1e99773d1 prior to the overcloud deployment.
2. Re-mount the NFS share with these args: "mount -t nfs -o context=system_u:object_r:glance_var_lib_t:s0"
* This can be achieved with placing the following lines in the parameters section of the yaml file:
This is resolved with the fix for bug 1247585
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.