【问题标题】:Get the openstack cinder volume size through python bindings通过 python 绑定获取 openstack cinder 卷大小
【发布时间】:2014-06-04 12:02:05
【问题描述】:

谁能帮我通过python绑定获得openstack cinder卷大小。

我有通过调用 cinder_client_instance.volumes.list() 方法提取的煤渣卷列表。

现在我想知道卷的大小。如何获取卷大小?

【问题讨论】:

    标签: python-2.7 openstack


    【解决方案1】:

    在体积对象上使用 size 参数。

    例如:

    for vol in cinder_instance.volume.list():print vol.id # 给出 cinder 卷 ID print vol.size # 给出 cinder 卷大小

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2021-10-26
      • 2019-04-22
      • 1970-01-01
      • 2018-03-04
      • 1970-01-01
      • 1970-01-01
      • 2014-06-01
      相关资源
      最近更新 更多