8.3. 从 Web 服务器导入镜像
如果镜像托管在 web 服务器上,您可以使用 GlanceImageImportPlugins 参数将镜像上传到多个存储中。
此流程假设默认 Image Conversion 插件已在镜像服务(glance)中启用。此功能自动将 QCOW2 文件格式转换为 RAW 镜像,它们是 Ceph RBD 的最佳选择。您可以通过运行 glance image-show ID | grep disk_format 来确认 glance 镜像采用 RAW 格式。
流程
使用
glance命令的image-create-via-import参数从 Web 服务器导入镜像。使用--stores参数。Copy to Clipboard Copied! Toggle word wrap Toggle overflow 在本例中,qcow2 cirros 镜像从官方 Cirros 站点下载,由 glance 转换为 RAW,并导入到中央站点和边缘站点 1 (由-
stores参数指定)。注意或者,您可以将
---,将镜像上传到所有存储。stores替换为--all-stores True