在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
原文链接 http://thornelabs.net/2014/08/03/use-openstack-swift-as-a-backend-store-for-glance.html
By default, OpenStack Glance saves images and OpenStack Instance snapshots on the local filesystem
in /var/lib/glance/images/.
However, if you have a Swift Cluster, you can just as easily use it to save images and snapshots instead of the
local filesystem where Glance is running.
Begin by logging into the node running the Glance services (probably your controller node also running Keystone)
as root and source your OpenStack credentials (this is typically a file named openrc).
Verify the user glance is part of tenant service with role admin.
One of the roles returned should be admin.
Open /etc/glance/glance-api.conf and comment out the following two lines:
With /etc/glance/glance-api.conf still open, append the following lines to the DEFAULT OPTIONS section (be
sure to set the values inside < > to match your environment):
With the configuration changes in place, restart the Glance services.
If you are running CentOS/RHEL:
If you are running Ubuntu:
Now you should be able to upload an image to Glance through the Horizon Dashboard or using the glance
command and instead of it being saved to /var/lib/glance/images, it will be saved in a Swift Container
called glance in the service account.
Verify nothing is saved in /var/lib/glance/images by simply running
delete any existing Glance Images, they will still be there).
Once the Horizon Dashboard or the
are in Swift by running the following command (be sure to set the values inside < > to match your environment):
|
请发表评论