第 6 章 使用 Dell EqualLogic Back Ends 地址卷大小 Discrepancies
报告卷大小时,Dell EqualLogic (EQL)后端也考虑用于内部卷元数据的额外存储。这个大小会比块存储服务报告的卷大小稍大。但是,由 EQL 后端报告的卷大小与镜像服务所使用的卷大小相同。
因此,当在 EQL 后端上创建镜像支持的卷时,首先检查镜像的大小。如果镜像最初是卷支持的,那么 EQL (以及扩展名,镜像服务)将报告一个卷大小比块存储服务报告的内容稍大。
如果 EQL 报告的镜像大小稍大,那么在创建由此镜像支持的卷时,您需要考虑大小差异。
6.1. Example 复制链接链接已复制到粘贴板!
为了说明这一点,当您创建一个 1GB 卷时:
[ cinder create --display-name vol1 1
块存储服务将报告大小为 1GB 的卷大小,但在 EQL 阵列中,大小(VolReserve)将稍大:
eql> volume select volume-6bdace69-bd41-42fc-a63a-f834fb65a2e4
eql (volume-6bdace69-bd41-42fc-a63a-f834fb65a2e4)> show
_______________________________ Volume Information ______... Name: volume-6bdace69-bd41-42fc-a63a-f834fb65a2e4 Size: 1GB VolReserve: 1.01GB ...
_______________________________ Volume Information ______...
Name: volume-6bdace69-bd41-42fc-a63a-f834fb65a2e4
Size: 1GB
VolReserve: 1.01GB
...
从这个卷创建新镜像时,cinder 将报告正确的卷大小为 1GB:
# Cinder upload-to-image --disk-format raw --container-format bare vol1 image_vol1
但是,镜像服务会报告稍大的大小:
# Glance image-list
...+------------+-------------+------------------+------------+--------+ ...| Name | Disk Format | Container Format | Size | Status | ...+------------+-------------+------------------+------------+--------+ ...| image_vol1 | raw | bare | 1085276160 | active | ...+------------+-------------+------------------+------------+--------+
...+------------+-------------+------------------+------------+--------+
...| Name | Disk Format | Container Format | Size | Status |
...+------------+-------------+------------------+------------+--------+
...| image_vol1 | raw | bare | 1085276160 | active |
...+------------+-------------+------------------+------------+--------+
glance 工具报告镜像大小大约为 1.01GB。因此,创建由此镜像支持的 1GB 卷将失败:
# cinder create --display-name vol2 --image-id c65f7eae-e2c1-44ba-8af1-e33695897559 1
ERROR: Invalid input received: Size of specified image 2 is larger than volume size 1
ERROR: Invalid input received: Size of specified image 2 is larger than volume size 1