Configuring Glance image caching
The glance-api
service can be configured to cache images to local machine's disk. Once configured, the local cache automatically stores copies of images that are successfully retrieved and served. In this configuration, glance-api
can run on multiple hosts without retrieving the same image from remote storage multiple times, leading the OpenStack environment to handle better scalability. Using Glance image caching is transparent to the user and doesn't change any of Glance's operations. The user does not know of the images are served from the backend storage or from glance-api
caching mechanism.
Getting Ready
Before enabling and configuring Glance image caching, make sure that glance is configured and can successfully serve images.
How to do it…
We can configure Glance image caching by following these steps:
Using the command
openstack-config
, editglance-api
configuration file, and setflavor
to includecachemanagement
using thepaste_deploy
section:[root@controller...