Block Storage 服务 (cinder) 命令行客户端

cinder 客户端是 Block Storage 服务 (cinder) API 及其扩展的命令行界面 (CLI)。

要获取特定 cinder 命令的帮助,请输入

$ cinder help COMMAND

cinder usage

usage: cinder [--version] [-d] [--service-type <service-type>]
              [--service-name <service-name>]
              [--volume-service-name <volume-service-name>]
              [--os-endpoint-type <os-endpoint-type>]
              [--os-volume-api-version <volume-api-ver>]
              [--os-endpoint <os-endpoint>] [--retries <retries>] [--insecure]
              [--os-cacert <ca-certificate>] [--os-cert <certificate>]
              [--os-key <key>] [--timeout <seconds>] [--collect-timing]
              [--os-auth-type <name>] [--os-auth-url OS_AUTH_URL]
              [--os-system-scope OS_SYSTEM_SCOPE]
              [--os-domain-id OS_DOMAIN_ID] [--os-domain-name OS_DOMAIN_NAME]
              [--os-project-id OS_PROJECT_ID]
              [--os-project-name OS_PROJECT_NAME]
              [--os-project-domain-id OS_PROJECT_DOMAIN_ID]
              [--os-project-domain-name OS_PROJECT_DOMAIN_NAME]
              [--os-trust-id OS_TRUST_ID]
              [--os-default-domain-id OS_DEFAULT_DOMAIN_ID]
              [--os-default-domain-name OS_DEFAULT_DOMAIN_NAME]
              [--os-user-id OS_USER_ID] [--os-username OS_USERNAME]
              [--os-user-domain-id OS_USER_DOMAIN_ID]
              [--os-user-domain-name OS_USER_DOMAIN_NAME]
              [--os-password OS_PASSWORD] [--os-auth-strategy <auth-strategy>]
              [--os-url <url>]
                <subcommand> ...

可选参数

--collect-timing

收集每个 API 调用的计时信息。

--insecure

显式允许客户端执行“不安全”TLS (https) 请求。服务器的证书将不会针对任何证书颁发机构进行验证。应谨慎使用此选项。

--os-auth-strategy

身份验证策略 (Env: OS_AUTH_STRATEGY, 默认 keystone)。目前,任何其他值都将禁用身份验证。

--os-auth-type, --os-auth-plugin

要使用的身份验证类型

--os-auth-url

认证 URL

--os-cacert

指定用于验证 TLS (https) 服务器证书的 CA 捆绑包文件。默认值为 env[OS_CACERT]。

--os-cert

包含此客户端公钥的密钥库 (PEM 格式) 的位置。默认值为 env[OS_CERT]。

--os-default-domain-id

与 v3 和 v2 参数一起使用的可选域 ID。它将在 v3 中用于用户域和项目域,并在 v2 身份验证中忽略。

--os-default-domain-name

与 v3 API 和 v2 参数一起使用的可选域名称。它将在 v3 中用于用户域和项目域,并在 v2 身份验证中忽略。

--os-domain-id

作用域的域 ID

--os-domain-name

作用域的域名称

--os-endpoint

使用此 API 端点而不是服务目录。默认值为 env[CINDER_ENDPOINT]。

--os-endpoint-type

端点类型,为 publicURL 或 internalURL。默认值=env[OS_ENDPOINT_TYPE] 或 nova env[CINDER_ENDPOINT_TYPE] 或 publicURL。

--os-key

包含此客户端私钥的密钥库 (PEM 格式) 的位置。默认值为 env[OS_KEY]。

--os-password

用户的密码

--os-project-domain-id

包含项目的域 ID

--os-project-domain-name

包含项目的域名称

--os-project-id, --os-tenant-id

作用域的项目 ID

--os-project-name, --os-tenant-name

作用域的项目名称

--os-system-scope

系统操作的作用域

--os-trust-id

用作受托人的信任 ID

--os-url

默认值为 env[OS_URL]。

--os-user-domain-id

用户域 ID

--os-user-domain-name

用户的域名称

--os-user-id

用户 ID

--os-username, --os-user-name

用户名

--os-volume-api-version

Block Storage API 版本。接受 X、X.Y(其中 X 是主版本号,Y 是次版本号)。注意:此客户端仅接受主版本号为“3”。默认值为 env[OS_VOLUME_API_VERSION]。

--retries

重试次数。

--service-name

服务名称。默认值为 env[CINDER_SERVICE_NAME]。

--service-type

服务类型。对于大多数操作,默认值为 volume。

--timeout

设置请求超时时间(秒)。

--version

显示程序版本号并退出

--volume-service-name

Volume 服务名称。默认值为 env[CINDER_VOLUME_SERVICE_NAME]。

-d, --debug

显示调试输出。

命令

absolute-limits

列出用户的绝对限制。

api-version

显示服务器 API 版本信息。

attachment-complete

完成 cinder 卷的连接。

attachment-create

为 cinder 卷创建连接。

attachment-delete

删除 cinder 卷的连接。

attachment-list

列出所有连接。

attachment-show

显示连接的详细信息。

attachment-update

更新 cinder 卷的连接。

availability-zone-list

列出所有可用区。

backup-create

创建卷备份。

backup-delete

删除一个或多个备份。

backup-export

导出备份元数据记录。

backup-import

导入备份元数据记录。

backup-list

列出所有备份。

backup-reset-state

显式更新备份状态。

backup-restore

恢复备份。

backup-show

显示备份详细信息。

backup-update

更新备份。

cgsnapshot-create

创建 cgsnapshot。

cgsnapshot-delete

删除一个或多个 cgsnapshots。

cgsnapshot-list

列出所有 cgsnapshots。

cgsnapshot-show

显示 cgsnapshot 详细信息。

cluster-disable

禁用集群服务。

cluster-enable

启用集群服务。

cluster-list

列出集群服务,并可选择进行筛选。

cluster-show

显示集群服务的详细信息。

consisgroup-create

创建一致性组。

consisgroup-create-from-src

从 cgsnapshot 或源 CG 创建一致性组。

consisgroup-delete

删除一个或多个一致性组。

consisgroup-list

列出所有一致性组。

consisgroup-show

显示一致性组的详细信息。

consisgroup-update

更新一致性组。

创建

创建卷。

default-type-list

列出所有默认卷类型。

default-type-set

为项目设置默认卷类型。

default-type-unset

取消设置默认卷类型。

删除

删除一个或多个卷。

encryption-type-create

为卷类型创建加密类型。仅限管理员。

encryption-type-delete

删除卷类型的加密类型。仅限管理员。

encryption-type-list

显示卷类型的加密类型详细信息。仅限管理员。

encryption-type-show

显示卷类型的加密类型详细信息。仅限管理员。

encryption-type-update

更新卷类型的加密类型信息(仅限管理员)。

extend

尝试扩展现有卷的大小。

extra-specs-list

列出当前卷类型和附加规范。

failover-host

故障转移正在复制的 cinder-volume 主机。

force-delete

尝试强制删除卷,无论其状态如何。

freeze-host

冻结并禁用指定的 cinder-volume 主机。

get-capabilities

显示后端卷统计信息和属性。仅限管理员。

get-pools

显示后端的池信息。仅限管理员。

group-create

创建一个组。

group-create-from-src

从组快照或源组创建组。

group-delete

删除一个或多个组。

group-disable-replication

禁用组的复制。

group-enable-replication

启用组的复制。

group-failover-replication

故障转移组的复制。

group-list

列出所有组。

group-list-replication-targets

列出组的复制目标。

group-show

显示组的详细信息。

group-snapshot-create

创建组快照。

group-snapshot-delete

删除一个或多个组快照。

group-snapshot-list

列出所有组快照。

group-snapshot-show

显示组快照详细信息。

group-specs-list

列出当前组类型和规范。

group-type-create

创建组类型。

group-type-default

列出默认组类型。

group-type-delete

删除组类型或类型。

group-type-key

为组类型设置或取消设置 group_spec。

group-type-list

列出可用的“组类型”。(仅限管理员可以看到私有类型)

group-type-show

显示组类型详细信息。

group-type-update

更新组类型名称、描述和/或 is_public。

group-update

更新组。

image-metadata

设置或删除卷映像元数据。

image-metadata-show

显示卷映像元数据。

列表

列出所有卷。

list-filters

列出启用的过滤器。

manage

管理现有卷。

manageable-list

列出所有可管理的卷。

message-delete

删除一个或多个消息。

message-list

列出所有消息。

message-show

显示消息详细信息。

metadata

设置或删除卷元数据。

metadata-show

显示卷元数据。

metadata-update-all

更新卷元数据。

migrate

将卷迁移到新主机。

qos-associate

将 qos 规范与指定的卷类型关联。

qos-create

创建 qos 规范。

qos-delete

删除指定的 qos 规范。

qos-disassociate

将 qos 规范从指定的卷类型分离。

qos-disassociate-all

将 qos 规范从其所有关联中分离。

qos-get-association

列出与指定的 qos 规范的所有关联。

qos-key

为 qos 规范设置或取消设置规范。

qos-list

列出 qos 规范。

qos-show

显示 qos 规范详细信息。

quota-class-show

列出配额类的配额。

quota-class-update

更新配额类的配额。

quota-defaults

列出租户的默认配额。

quota-delete

删除租户的配额。

quota-show

列出租户的配额。

quota-update

更新租户的配额。

quota-usage

列出租户的配额使用情况。

rate-limits

列出用户的速率限制。

readonly-mode-update

更新卷的只读访问模式标志。

reimage

重建卷,用指定的映像覆盖所有内容

rename

重命名卷。

reset-state

显式更新 Cinder 数据库中的实体状态。

retype

更改卷的卷类型。

revert-to-snapshot

将卷恢复到指定的快照。

service-disable

禁用该服务。

service-enable

启用该服务。

service-get-log

获取服务日志级别。

service-list

列出所有服务。按主机和二进制服务进行筛选。

service-set-log

设置服务日志级别。

set-bootable

更新卷的可引导状态。

show

显示卷详细信息。

snapshot-create

创建快照。

snapshot-delete

删除一个或多个快照。

snapshot-list

列出所有快照。

snapshot-manage

管理现有的快照。

snapshot-manageable-list

列出所有可管理的快照。

snapshot-metadata

设置或删除快照元数据。

snapshot-metadata-show

显示快照元数据。

snapshot-metadata-update-all

更新快照元数据。

snapshot-rename

重命名快照。

snapshot-reset-state

显式更新快照状态。

snapshot-show

显示快照详细信息。

snapshot-unmanage

停止管理快照。

summary

获取卷摘要。

thaw-host

解冻并启用指定的 cinder-volume 主机。

transfer-accept

接受卷传输。

transfer-create

创建卷传输。

transfer-delete

撤销传输。

transfer-list

列出所有传输。

transfer-show

显示传输详细信息。

type-access-add

为给定的项目添加卷类型访问权限。

type-access-list

打印有关给定卷类型的访问信息。

type-access-remove

删除给定项目的卷类型访问权限。

type-create

创建一个卷类型。

type-default

列出默认卷类型。

type-delete

删除卷类型或类型。

type-key

为卷类型设置或取消设置 extra_spec。

type-list

列出可用的“卷类型”。(仅限管理员可以看到私有类型)

type-show

显示卷类型详细信息。

type-update

更新卷类型名称、描述和/或 is_public。

unmanage

停止管理卷。

upload-to-image

将卷上传到 Image Service 作为映像。

version-list

列出所有 API 版本。

work-cleanup

请求清理服务,可选择进行筛选。

help

显示有关此程序或其子命令的帮助信息。

命令详细信息

cinder absolute-limits

usage: cinder absolute-limits [<tenant_id>]

列出用户的绝对限制。

位置参数

<tenant_id>

显示单个租户的信息(仅限管理员)。

cinder api-version

usage: cinder api-version

显示服务器 API 版本信息。

cinder attachment-complete

usage: cinder attachment-complete <attachment> [<attachment> ...]

完成 cinder 卷的连接。

位置参数

<attachment>

要删除的连接的 ID。

cinder attachment-create

usage: cinder attachment-create [--connect <connect>]
                                [--initiator <initiator>] [--ip <ip>]
                                [--host <host>] [--platform <platform>]
                                [--ostype <ostype>] [--multipath <multipath>]
                                [--mountpoint <mountpoint>] [--mode <mode>]
                                <volume> [<server_id>]

为 cinder 卷创建连接。

位置参数

<volume>

要连接的卷的名称或 ID。

<server_id>

连接到的服务器的 ID。

可选参数

--connect <connect>

使用提供的连接器信息建立活动连接(True 或 False)。

--initiator <initiator>

连接的启动器 iqn。默认值为 None。

--ip <ip>

连接系统的 IP。默认值为 None。

--host <host>

连接的主机名称。默认值为 None。

--platform <platform>

平台类型。默认值为 x86_64。

--ostype <ostype>

操作系统类型。默认值为 linux2。

--multipath <multipath>

使用多路径。默认值为 False。

--mountpoint <mountpoint>

卷将连接到的挂载点。默认值为 None。

--mode <mode>

连接模式,rw、ro 和 null,其中 null 表示我们希望尊重任何现有的管理员元数据设置。默认值为 null。

cinder attachment-delete

usage: cinder attachment-delete <attachment> [<attachment> ...]

删除 cinder 卷的连接。

位置参数

<attachment>

要删除的连接的 ID。

cinder attachment-list

usage: cinder attachment-list [--all-tenants [<0|1>]]
                              [--volume-id <volume-id>] [--status <status>]
                              [--marker <marker>] [--limit <limit>]
                              [--sort <key>[:<direction>]]
                              [--tenant [<tenant>]]
                              [--filters [<key=value> ...]]

列出所有连接。

可选参数

--all-tenants <0|1>

显示所有租户的详细信息。仅限管理员。

--volume-id <volume-id>

按卷 ID 筛选结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的“--filters”选项。

--status <status>

按状态筛选结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的“--filters”选项。

--marker <marker>

从连接列表中返回晚于此 ID 的连接开始。默认值为 None。

--limit <limit>

返回的最大连接数。默认值为 None。

--sort <key>[:<direction>]

逗号分隔的排序键和方向列表,格式为 <key>[:<asc|desc>]。有效键:id、status、size、availability_zone、name、bootable、created_at、reference。默认值为 None。

--tenant <tenant>

显示单个租户的信息(仅限管理员)。

--filters <key=value>

筛选键值对。请使用“cinder list-filters”查看服务器上启用的筛选器。如果键支持,请使用“key~=value”进行不精确筛选。默认值为 None。

cinder attachment-show

usage: cinder attachment-show <attachment>

显示连接的详细信息。

位置参数

<attachment>

连接的 ID。

cinder attachment-update

usage: cinder attachment-update [--initiator <initiator>] [--ip <ip>]
                                [--host <host>] [--platform <platform>]
                                [--ostype <ostype>] [--multipath <multipath>]
                                [--mountpoint <mountpoint>]
                                <attachment>

更新 cinder 卷的连接。

位置参数

<attachment>

连接的 ID。

可选参数

--initiator <initiator>

连接的启动器 iqn。默认值为 None。

--ip <ip>

连接系统的 IP。默认值为 None。

--host <host>

连接的主机名称。默认值为 None。

--platform <platform>

平台类型。默认值为 x86_64。

--ostype <ostype>

操作系统类型。默认值为 linux2。

--multipath <multipath>

使用多路径。默认值为 False。

--mountpoint <mountpoint>

卷将连接到的挂载点。默认值为 None。

cinder availability-zone-list

usage: cinder availability-zone-list

列出所有可用区。

cinder backup-create

usage: cinder backup-create [--container <container>] [--name <name>]
                            [--description <description>] [--incremental]
                            [--force] [--snapshot-id <snapshot-id>]
                            [--metadata [<key=value> ...]]
                            [--availability-zone AVAILABILITY_ZONE]
                            <volume>

创建卷备份。

位置参数

<volume>

要备份的卷的名称或 ID。

可选参数

--container <container>

备份容器名称。默认值为 None。

--name <name>

备份名称。默认值为 None。

--description <description>

备份描述。默认值为 None。

--incremental None

增量备份。默认值为 False。

--force None

允许或禁止在卷附加到实例时备份卷。如果设置为 True,则无论卷的状态是“可用”还是“使用中”都备份该卷。备份“使用中”的卷意味着您的数据是一致的崩溃状态。默认值=False。

--snapshot-id <snapshot-id>

要备份的快照的 ID。默认值=None。

--metadata <key=value>

元数据键值对。默认值=None。

--availability-zone None

备份应存储的可用区,默认情况下与源相同。

cinder backup-delete

usage: cinder backup-delete [--force] <backup> [<backup> ...]

删除一个或多个备份。

位置参数

<backup>

要删除的备份的名称或 ID。

可选参数

--force None

允许删除状态不是“可用”或“错误”的卷的备份。默认值=False。

cinder backup-export

usage: cinder backup-export <backup>

导出备份元数据记录。

位置参数

<backup>

要导出的备份的 ID。

cinder backup-import

usage: cinder backup-import <backup_service> <backup_url>

导入备份元数据记录。

位置参数

<backup_service>

用于导入备份的备份服务。

<backup_url>

用于导入备份元数据的备份 URL。

cinder backup-list

usage: cinder backup-list [--all-tenants [<all_tenants>]] [--name <name>]
                          [--status <status>] [--volume-id <volume-id>]
                          [--marker <marker>] [--limit <limit>]
                          [--sort <key>[:<direction>]]
                          [--filters [<key=value> ...]]
                          [--with-count [<True|False>]]

列出所有备份。

可选参数

--all-tenants <all_tenants>

显示所有租户的详细信息。仅限管理员。

--name <name>

按名称过滤结果。默认值=None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的‘–filters’选项。

--status <status>

按状态筛选结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的“--filters”选项。

--volume-id <volume-id>

按卷 ID 筛选结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的“--filters”选项。

--marker <marker>

从比此 ID 表示的备份列表后出现的备份开始返回。默认值=None。

--limit <limit>

要返回的最大备份数。默认值=None。

--sort <key>[:<direction>]

逗号分隔的排序键和方向列表,格式为 <key>[:<asc|desc>]。有效键:id、status、size、availability_zone、name、bootable、created_at、reference。默认值为 None。

--filters <key=value>

筛选键值对。请使用“cinder list-filters”查看服务器上启用的筛选器。如果键支持,请使用“key~=value”进行不精确筛选。默认值为 None。

--with-count <True|False>

显示备份实体的总数。当请求中应用分页时,此选项很有用。

cinder backup-reset-state

usage: cinder backup-reset-state [--state <state>] <backup> [<backup> ...]

显式更新备份状态。

位置参数

<backup>

要修改的备份的名称或 ID。

可选参数

--state <state>

要分配给备份的状态。有效值为“可用”、“错误”。默认值=available。

cinder backup-restore

usage: cinder backup-restore [--volume <volume>] [--name <name>]
                             [--volume-type <volume-type>]
                             [--availability-zone <AZ>]
                             <backup>

恢复备份。

位置参数

<backup>

要恢复的备份的名称或 ID。

可选参数

--volume <volume>

要恢复到的现有卷的名称或 ID。此选项与 –name 互斥,并具有优先权。默认值=None。

--name <name>

用于创建新卷以进行恢复的名称。此选项与 –volume 互斥,并且 –volume 具有优先权。默认值=None。

--volume-type <volume-type>

用于创建新卷以进行恢复的卷类型。当与“volume”选项一起使用时,此选项无效。默认值=None。

--availability-zone <AZ>

用于创建新卷以进行恢复的 AZ。默认情况下,它将与备份 AZ 相同。当与“volume”选项一起使用时,此选项无效。默认值=None。

cinder backup-show

usage: cinder backup-show <backup>

显示备份详细信息。

位置参数

<backup>

备份的名称或 ID。

cinder backup-update

usage: cinder backup-update [--name [<name>]] [--description <description>]
                            [--metadata [<key=value> ...]]
                            <backup>

更新备份。

位置参数

<backup>

要重命名的备份的名称或 ID。

可选参数

--name <name>

备份的新名称。

--description <description>

备份描述。默认值为 None。

--metadata <key=value>

元数据键值对。默认值=None。

cinder cgsnapshot-create

usage: cinder cgsnapshot-create [--name <name>] [--description <description>]
                                <consistencygroup>

创建 cgsnapshot。

位置参数

<consistencygroup>

一致性组的名称或 ID。

可选参数

--name <name>

Cgsnapshot 名称。默认值=None。

--description <description>

Cgsnapshot 描述。默认值=None。

cinder cgsnapshot-delete

usage: cinder cgsnapshot-delete <cgsnapshot> [<cgsnapshot> ...]

删除一个或多个 cgsnapshots。

位置参数

<cgsnapshot>

要删除的一个或多个 cgsnapshot 的名称或 ID。

cinder cgsnapshot-list

usage: cinder cgsnapshot-list [--all-tenants [<0|1>]] [--status <status>]
                              [--consistencygroup-id <consistencygroup_id>]

列出所有 cgsnapshots。

可选参数

--all-tenants <0|1>

显示所有租户的详细信息。仅限管理员。

--status <status>

按状态过滤结果。默认值=None。

--consistencygroup-id <consistencygroup_id>

按一致性组 ID 过滤结果。默认值=None。

cinder cgsnapshot-show

usage: cinder cgsnapshot-show <cgsnapshot>

显示 cgsnapshot 详细信息。

位置参数

<cgsnapshot>

cgsnapshot 的名称或 ID。

cinder cluster-disable

usage: cinder cluster-disable [--reason <reason>] [<binary>] <cluster-name>

禁用集群服务。

位置参数

<binary>

要过滤的二进制文件。默认值:cinder-volume。

<cluster-name>

要更新的集群服务的名称。

可选参数

--reason <reason>

禁用集群服务的理由。

cinder cluster-enable

usage: cinder cluster-enable [<binary>] <cluster-name>

启用集群服务。

位置参数

<binary>

要过滤的二进制文件。默认值:cinder-volume。

<cluster-name>

要更新的集群服务的名称。

cinder cluster-list

usage: cinder cluster-list [--name <name>] [--binary <binary>]
                           [--is-up <True|true|False|false>]
                           [--disabled <True|true|False|false>]
                           [--num-hosts <num-hosts>]
                           [--num-down-hosts <num-down-hosts>] [--detailed]

列出集群服务,并可选择进行筛选。

可选参数

--name <name>

按集群名称过滤,不带后端将列出同一集群的所有集群服务。默认值=None。

--binary <binary>

集群二进制文件。默认值=None。

--is-up <True|true|False|false>

按启动/停止状态过滤。默认值=None。

--disabled <True|true|False|false>

按禁用状态过滤。默认值=None。

--num-hosts <num-hosts>

按集群中的主机数过滤。

--num-down-hosts <num-down-hosts>

按停止的主机数过滤。

--detailed None

获取详细的集群服务信息(默认值=False)。

cinder cluster-show

usage: cinder cluster-show [<binary>] <cluster-name>

显示集群服务的详细信息。

位置参数

<binary>

要过滤的二进制文件。默认值:cinder-volume。

<cluster-name>

要显示的集群服务的名称。

cinder consisgroup-create

usage: cinder consisgroup-create [--name <name>] [--description <description>]
                                 [--availability-zone <availability-zone>]
                                 <volume-types>

创建一致性组。

位置参数

<volume-types>

卷类型。

可选参数

--name <name>

一致性组的名称。

--description <description>

一致性组的描述。默认值=None。

--availability-zone <availability-zone>

卷的可用区。默认值=None。

cinder consisgroup-create-from-src

usage: cinder consisgroup-create-from-src [--cgsnapshot <cgsnapshot>]
                                          [--source-cg <source-cg>]
                                          [--name <name>]
                                          [--description <description>]

从 cgsnapshot 或源 CG 创建一致性组。

可选参数

--cgsnapshot <cgsnapshot>

cgsnapshot 的名称或 ID。默认值=None。

--source-cg <source-cg>

源 CG 的名称或 ID。默认值=None。

--name <name>

一致性组的名称。默认值=None。

--description <description>

一致性组的描述。默认值=None。

cinder consisgroup-delete

usage: cinder consisgroup-delete [--force]
                                 <consistencygroup> [<consistencygroup> ...]

删除一个或多个一致性组。

位置参数

<consistencygroup>

要删除的一个或多个一致性组的名称或 ID。

可选参数

--force None

允许或禁止删除一致性组。如果一致性组为空,则无需 force 标志即可删除。如果一致性组不为空,则需要 force 标志才能将其删除。

cinder consisgroup-list

usage: cinder consisgroup-list [--all-tenants [<0|1>]]

列出所有一致性组。

可选参数

--all-tenants <0|1>

显示所有租户的详细信息。仅限管理员。

cinder consisgroup-show

usage: cinder consisgroup-show <consistencygroup>

显示一致性组的详细信息。

位置参数

<consistencygroup>

一致性组的名称或 ID。

cinder consisgroup-update

usage: cinder consisgroup-update [--name <name>] [--description <description>]
                                 [--add-volumes <uuid1,uuid2,......>]
                                 [--remove-volumes <uuid3,uuid4,......>]
                                 <consistencygroup>

更新一致性组。

位置参数

<consistencygroup>

一致性组的名称或 ID。

可选参数

--name <name>

一致性组的新名称。默认值=None。

--description <description>

一致性组的新描述。默认值=None。

--add-volumes <uuid1,uuid2,......>

要添加到一致性组的一个或多个卷的 UUID,用逗号分隔。默认值=None。

--remove-volumes <uuid3,uuid4,......>

要从一致性组中删除的一个或多个卷的 UUID,用逗号分隔。默认值=None。

cinder create

usage: cinder create [--consisgroup-id <consistencygroup-id>]
                     [--group-id <group-id>] [--snapshot-id <snapshot-id>]
                     [--source-volid <source-volid>] [--image-id <image-id>]
                     [--image <image>] [--backup-id <backup-id>]
                     [--name <name>] [--description <description>]
                     [--volume-type <volume-type>]
                     [--availability-zone <availability-zone>]
                     [--metadata [<key=value> ...]] [--hint <key=value>]
                     [--poll]
                     [<size>]

创建卷。

位置参数

<size>

卷的大小,以 GiB 为单位。(除非指定 snapshot-id/source-volid/backup-id,否则必需)。

可选参数

--consisgroup-id <consistencygroup-id>

新卷所属的一致性组的 ID。默认值=None。

--group-id <group-id>

新卷所属的组的 ID。默认值=None。

--snapshot-id <snapshot-id>

从快照 ID 创建卷。默认值=None。

--source-volid <source-volid>

从卷 ID 创建卷。默认值=None。

--image-id <image-id>

从镜像 ID 创建卷。默认值=None。

--image <image>

从镜像(ID 或名称)创建卷。默认值=None。

--backup-id <backup-id>

从备份 ID 创建卷。默认值=None。

--name <name>

卷名称。默认值=None。

--description <description>

卷描述。默认值=None。

--volume-type <volume-type>

卷类型。默认值=None,即使用为块存储 API 配置的默认卷类型。您可以使用‘cinder type-default’命令查看这是什么类型。

--availability-zone <availability-zone>

卷的可用区。默认值=None。

--metadata <key=value>

元数据键值对。默认值=None。

--hint <key=value>

调度器提示,类似于 nova。重复选项以设置多个提示。具有相同键的值将存储为列表。

--poll None

等待卷创建完成。

cinder default-type-list

usage: cinder default-type-list [--project-id <project_id>]

列出所有默认卷类型。

可选参数

--project-id <project_id>

显示默认类型项目的 ID。

cinder default-type-set

usage: cinder default-type-set <volume_type> <project_id>

为项目设置默认卷类型。

位置参数

<volume_type>

卷类型名称或 ID。

<project_id>

设置默认类型的项目的 ID。

cinder default-type-unset

usage: cinder default-type-unset <project_id> [<project_id> ...]

取消设置默认卷类型。

位置参数

<project_id>

取消设置默认类型的项目的 ID。

cinder delete

usage: cinder delete [--cascade] <volume> [<volume> ...]

删除一个或多个卷。

位置参数

<volume>

要删除的卷的名称或 ID。

可选参数

--cascade None

删除任何快照以及卷。默认值=False。

cinder encryption-type-create

usage: cinder encryption-type-create [--cipher <cipher>]
                                     [--key-size <key_size>]
                                     [--control-location <control_location>]
                                     <volume_type> <provider>

为卷类型创建加密类型。仅限管理员。

位置参数

<volume_type>

卷类型的名称或 ID。

<provider>

加密提供程序格式。例如,“luks”或“plain”。

可选参数

--cipher <cipher>

加密算法或模式。例如,aes-xts-plain64。默认值=None。

--key-size <key_size>

加密密钥的大小,以位为单位。例如,128 或 256。默认值=None。

--control-location <control_location>

执行加密的虚拟服务。有效值为“前端”或“后端”。例如,前端=Nova。默认值为“前端”。

cinder encryption-type-delete

usage: cinder encryption-type-delete <volume_type>

删除卷类型的加密类型。仅限管理员。

位置参数

<volume_type>

卷类型的名称或 ID。

cinder encryption-type-list

usage: cinder encryption-type-list

显示卷类型的加密类型详细信息。仅限管理员。

cinder encryption-type-show

usage: cinder encryption-type-show <volume_type>

显示卷类型的加密类型详细信息。仅限管理员。

位置参数

<volume_type>

卷类型的名称或 ID。

cinder encryption-type-update

usage: cinder encryption-type-update [--provider <provider>]
                                     [--cipher [<cipher>]]
                                     [--key-size [<key-size>]]
                                     [--control-location <control-location>]
                                     <volume-type>

更新卷类型的加密类型信息(仅限管理员)。

位置参数

<volume-type>

卷类型的名称或 ID

可选参数

--provider <provider>

加密提供程序格式(例如‘luks’或‘plain’)。

--cipher <cipher>

要使用的加密算法/模式(例如,aes-xts-plain64)。提供不带值的参数以设置为提供程序默认值。

--key-size <key-size>

加密密钥的大小,以位为单位(例如,128、256)。提供不带值的参数以设置为提供程序默认值。

--control-location <control-location>

执行加密的虚拟服务(例如,前端=Nova)。值:‘前端’、‘后端’

cinder extend

usage: cinder extend <volume> <new_size>

尝试扩展现有卷的大小。

位置参数

<volume>

要扩展的卷的名称或 ID。

<new_size>

卷的新大小,以 GiB 为单位。

cinder extra-specs-list

usage: cinder extra-specs-list

列出当前卷类型和附加规范。

cinder failover-host

usage: cinder failover-host [--backend_id <backend-id>] <hostname>

故障转移正在复制的 cinder-volume 主机。

位置参数

<hostname>

主机名。

可选参数

--backend_id <backend-id>

要故障转移到的后端的 ID(默认值=None)

cinder force-delete

usage: cinder force-delete <volume> [<volume> ...]

尝试强制删除卷,无论其状态如何。

位置参数

<volume>

要删除的卷的名称或 ID。

cinder freeze-host

usage: cinder freeze-host <hostname>

冻结并禁用指定的 cinder-volume 主机。

位置参数

<hostname>

主机名。

cinder get-capabilities

usage: cinder get-capabilities <host>

显示后端卷统计信息和属性。仅限管理员。

位置参数

<host>

要显示后端卷统计信息和属性的 Cinder 主机,格式为:host@backend-name

cinder get-pools

usage: cinder get-pools [--detail] [--filters [<key=value> ...]]

显示后端的池信息。仅限管理员。

可选参数

--detail None

显示池的详细信息。

--filters <key=value>

键值对过滤器。请使用‘cinder list-filters’检查服务器上启用的过滤器,默认值=None。

cinder group-create

usage: cinder group-create [--name <name>] [--description <description>]
                           [--availability-zone <availability-zone>]
                           <group-type> <volume-types>

创建一个组。

位置参数

<group-type>

组类型。

<volume-types>

以逗号分隔的卷类型列表。

可选参数

--name <name>

组的名称。

--description <description>

组的描述。默认值=None。

--availability-zone <availability-zone>

组的可用区。默认值=None。

cinder group-create-from-src

usage: cinder group-create-from-src [--group-snapshot <group-snapshot>]
                                    [--source-group <source-group>]
                                    [--name <name>]
                                    [--description <description>]

从组快照或源组创建组。

可选参数

--group-snapshot <group-snapshot>

组快照的名称或 ID。默认值为 None。

--source-group <source-group>

源组的名称或 ID。默认值为 None。

--name <name>

组的名称。默认值为 None。

--description <description>

组的描述。默认值=None。

cinder group-delete

usage: cinder group-delete [--delete-volumes] <group> [<group> ...]

删除一个或多个组。

位置参数

<group>

要删除的一个或多个组的名称或 ID。

可选参数

--delete-volumes None

允许或禁止删除非空组。如果组为空,则无需使用 delete-volumes 标志即可删除。如果组非空,则需要 delete-volumes 标志才能将其删除。如果为 True,则组中的所有卷也将被删除。

cinder group-disable-replication

usage: cinder group-disable-replication <group>

禁用组的复制。

位置参数

<group>

组的名称或 ID。

cinder group-enable-replication

usage: cinder group-enable-replication <group>

启用组的复制。

位置参数

<group>

组的名称或 ID。

cinder group-failover-replication

usage: cinder group-failover-replication [--allow-attached-volume]
                                         [--secondary-backend-id <secondary_backend_id>]
                                         <group>

故障转移组的复制。

位置参数

<group>

组的名称或 ID。

可选参数

--allow-attached-volume None

允许或禁止带有已挂载卷的组进行故障转移。

--secondary-backend-id <secondary_backend_id>

辅助后端 ID。默认值为 None。

cinder group-list

usage: cinder group-list [--all-tenants [<0|1>]] [--filters [<key=value> ...]]

列出所有组。

可选参数

--all-tenants <0|1>

显示所有租户的详细信息。仅限管理员。

--filters <key=value>

筛选键值对。请使用“cinder list-filters”查看服务器上启用的筛选器。如果键支持,请使用“key~=value”进行不精确筛选。默认值为 None。

cinder group-list-replication-targets

usage: cinder group-list-replication-targets <group>

列出组的复制目标。

位置参数

<group>

组的名称或 ID。

cinder group-show

usage: cinder group-show [--list-volume [<False|True>]] <group>

显示组的详细信息。

位置参数

<group>

组的名称或 ID。

可选参数

--list-volume <False|True>

显示组中包含的卷。

cinder group-snapshot-create

usage: cinder group-snapshot-create [--name <name>]
                                    [--description <description>]
                                    <group>

创建组快照。

位置参数

<group>

组的名称或 ID。

可选参数

--name <name>

组快照名称。默认值为 None。

--description <description>

组快照描述。默认值为 None。

cinder group-snapshot-delete

usage: cinder group-snapshot-delete <group_snapshot> [<group_snapshot> ...]

删除一个或多个组快照。

位置参数

<group_snapshot>

要删除的一个或多个组快照的名称或 ID。

cinder group-snapshot-list

usage: cinder group-snapshot-list [--all-tenants [<0|1>]] [--status <status>]
                                  [--group-id <group_id>]
                                  [--filters [<key=value> ...]]

列出所有组快照。

可选参数

--all-tenants <0|1>

显示所有租户的详细信息。仅限管理员。

--status <status>

按状态筛选结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的“--filters”选项。

--group-id <group_id>

按组 ID 过滤结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的 ‘–filters’ 选项。

--filters <key=value>

筛选键值对。请使用“cinder list-filters”查看服务器上启用的筛选器。如果键支持,请使用“key~=value”进行不精确筛选。默认值为 None。

cinder group-snapshot-show

usage: cinder group-snapshot-show <group_snapshot>

显示组快照详细信息。

位置参数

<group_snapshot>

组快照的名称或 ID。

cinder group-specs-list

usage: cinder group-specs-list

列出当前组类型和规范。

cinder group-type-create

usage: cinder group-type-create [--description <description>]
                                [--is-public <is-public>]
                                <name>

创建组类型。

位置参数

<name>

新组类型的名称。

可选参数

--description <description>

新组类型的描述。

--is-public <is-public>

使类型可供公众访问(默认值为 true)。

cinder group-type-default

usage: cinder group-type-default

列出默认组类型。

cinder group-type-delete

usage: cinder group-type-delete <group_type> [<group_type> ...]

删除组类型或类型。

位置参数

<group_type>

要删除的组类型或类型的名称或 ID。

cinder group-type-key

usage: cinder group-type-key <gtype> <action> <key=value> [<key=value> ...]

为组类型设置或取消设置 group_spec。

位置参数

<gtype>

组类型的名称或 ID。

<action>

操作。有效值为“set”或“unset”。

<key=value>

要设置或取消设置的组规格键值对。对于取消设置,仅指定键。

cinder group-type-list

usage: cinder group-type-list [--filters [<key=value> ...]]

列出可用的“组类型”。(仅限管理员可以看到私有类型)

可选参数

--filters <key=value>

过滤键值对。仅限管理员。

cinder group-type-show

usage: cinder group-type-show <group_type>

显示组类型详细信息。

位置参数

<group_type>

组类型的名称或 ID。

cinder group-type-update

usage: cinder group-type-update [--name <name>] [--description <description>]
                                [--is-public <is-public>]
                                <id>

更新组类型名称、描述和/或 is_public。

位置参数

<id>

组类型的 ID。

可选参数

--name <name>

组类型的名称。

--description <description>

组类型的描述。

--is-public <is-public>

使类型可供公众访问或不可访问。

cinder group-update

usage: cinder group-update [--name <name>] [--description <description>]
                           [--add-volumes <uuid1,uuid2,......>]
                           [--remove-volumes <uuid3,uuid4,......>]
                           <group>

更新组。

位置参数

<group>

组的名称或 ID。

可选参数

--name <name>

组的新名称。默认值为 None。

--description <description>

组的新描述。默认值为 None。

--add-volumes <uuid1,uuid2,......>

要添加到组的一个或多个卷的 UUID,用逗号分隔。默认值为 None。

--remove-volumes <uuid3,uuid4,......>

要从组中删除的一个或多个卷的 UUID,用逗号分隔。默认值为 None。

cinder image-metadata

usage: cinder image-metadata <volume> <action> <key=value> [<key=value> ...]

设置或删除卷映像元数据。

位置参数

<volume>

要更新元数据的卷的名称或 ID。

<action>

操作。有效值为“set”或“unset”。

<key=value>

要设置或取消设置的元数据键值对。对于取消设置,仅指定键。

cinder image-metadata-show

usage: cinder image-metadata-show <volume>

显示卷映像元数据。

位置参数

<volume>

卷的 ID。

cinder list

usage: cinder list [--group_id <group_id>] [--all-tenants [<0|1>]]
                   [--name <name>] [--status <status>]
                   [--bootable [<True|true|False|false>]]
                   [--migration_status <migration_status>]
                   [--metadata [<key=value> ...]]
                   [--image_metadata [<key=value> ...]] [--marker <marker>]
                   [--limit <limit>] [--fields <fields>]
                   [--sort <key>[:<direction>]] [--tenant [<tenant>]]
                   [--filters [<key=value> ...]] [--with-count [<True|False>]]

列出所有卷。

可选参数

--group_id <group_id>

按 group_id 过滤结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的 ‘–filters’ 选项。

--all-tenants <0|1>

显示所有租户的详细信息。仅限管理员。

--name <name>

按名称过滤结果。默认值=None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的‘–filters’选项。

--status <status>

按状态筛选结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的“--filters”选项。

--bootable <True|true|False|false>

按可启动状态过滤结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的 ‘–filters’ 选项。

--migration_status <migration_status>

按迁移状态过滤结果。默认值为 None。仅限管理员。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的 ‘–filters’ 选项。

--metadata <key=value>

按元数据键值对过滤结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的 ‘–filters’ 选项。

--image_metadata <key=value>

按映像元数据键值对过滤结果。需要卷 API 版本 >=3.4。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的 ‘–filters’ 选项。

--marker <marker>

从卷列表中较晚出现的位置开始返回卷,该位置由此卷 ID 表示。默认值为 None。

--limit <limit>

要返回的最大卷数。默认值为 None。

--fields <fields>

用逗号分隔的要显示的字段列表。使用 show 命令查看可用哪些字段。不可用/不存在的字段将被忽略。默认值为 None。

--sort <key>[:<direction>]

逗号分隔的排序键和方向列表,格式为 <key>[:<asc|desc>]。有效键:id、status、size、availability_zone、name、bootable、created_at、reference。默认值为 None。

--tenant <tenant>

显示单个租户的信息(仅限管理员)。

--filters <key=value>

筛选键值对。请使用“cinder list-filters”查看服务器上启用的筛选器。如果键支持,请使用“key~=value”进行不精确筛选。默认值为 None。

--with-count <True|False>

显示卷实体的总数。当请求中应用分页时,此功能很有用。

cinder list-filters

usage: cinder list-filters [--resource <resource>]

列出启用的过滤器。

可选参数

--resource <resource>

显示指定资源的启用过滤器。默认值为 None。

cinder manage

usage: cinder manage [--cluster CLUSTER] [--id-type <id-type>] [--name <name>]
                     [--description <description>]
                     [--volume-type <volume-type>]
                     [--availability-zone <availability-zone>]
                     [--metadata [<key=value> ...]] [--bootable]
                     <host> <identifier>

管理现有卷。

位置参数

<host>

现有卷所在的 Cinder 主机;格式为:host@backend-name#pool

<identifier>

现有卷的名称或其他标识符

可选参数

--cluster None

现有卷所在的 Cinder 集群;格式为:cluster@backend-name#pool

--id-type <id-type>

提供的后端设备标识符的类型,通常为 source-name 或 source-id(默认值为 source-name)

--name <name>

卷名称(默认值为 None)

--description <description>

卷描述(默认值为 None)

--volume-type <volume-type>

卷类型(默认值为 None)

--availability-zone <availability-zone>

卷的可用区(默认值为 None)

--metadata <key=value>

元数据键值对(默认值为 None)

--bootable None

指定新创建的卷应标记为可启动

cinder manageable-list

usage: cinder manageable-list [--detailed <detailed>] [--marker <marker>]
                              [--limit <limit>] [--offset <offset>]
                              [--sort <key>[:<direction>]] [--cluster CLUSTER]
                              [<host>]

列出所有可管理的卷。

位置参数

<host>

要列出可管理卷的 Cinder 主机;格式为:host@backend-name#pool

可选参数

--detailed <detailed>

返回详细信息(默认值为 true)。

--marker <marker>

从卷列表中较晚出现的位置开始返回卷,该位置由此引用表示。此引用应为 json 格式。默认值为 None。

--limit <limit>

要返回的最大卷数。默认值为 None。

--offset <offset>

在标记之后要跳过的卷数。默认值为 None。

--sort <key>[:<direction>]

以 <key>[:<asc|desc>] 形式分隔的排序键和方向的逗号分隔列表。有效键:size、reference。默认值为 None。

--cluster CLUSTER

要列出可管理卷的 Cinder 集群;格式为:cluster@backend-name#pool

cinder message-delete

usage: cinder message-delete <message> [<message> ...]

删除一个或多个消息。

位置参数

<message>

要删除的一个或多个消息的 ID。

cinder message-list

usage: cinder message-list [--marker <marker>] [--limit <limit>]
                           [--sort <key>[:<direction>]]
                           [--resource_uuid <resource_uuid>]
                           [--resource_type <type>] [--event_id <id>]
                           [--request_id <request_id>] [--level <level>]
                           [--filters [<key=value> ...]]

列出所有消息。

可选参数

--marker <marker>

从消息列表中较晚出现的位置开始返回消息,该位置由此 ID 表示。默认值为 None。

--limit <limit>

要返回的最大消息数。默认值为 None。

--sort <key>[:<direction>]

逗号分隔的排序键和方向列表,格式为 <key>[:<asc|desc>]。有效键:id、status、size、availability_zone、name、bootable、created_at、reference。默认值为 None。

--resource_uuid <resource_uuid>

按资源 UUID 过滤结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的 ‘–filters’ 选项。

--resource_type <type>

按资源类型过滤结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的 ‘–filters’ 选项。

--event_id <id>

按事件 ID 过滤结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的 ‘–filters’ 选项。

--request_id <request_id>

按请求 ID 过滤结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的 ‘–filters’ 选项。

--level <level>

按消息级别过滤结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的 ‘–filters’ 选项。

--filters <key=value>

筛选键值对。请使用“cinder list-filters”查看服务器上启用的筛选器。如果键支持,请使用“key~=value”进行不精确筛选。默认值为 None。

cinder message-show

usage: cinder message-show <message>

显示消息详细信息。

位置参数

<message>

消息的 ID。

cinder metadata

usage: cinder metadata <volume> <action> <key=value> [<key=value> ...]

设置或删除卷元数据。

位置参数

<volume>

要更新元数据的卷的名称或 ID。

<action>

操作。有效值为“set”或“unset”。

<key=value>

要设置或取消设置的元数据键值对。对于取消设置,仅指定键:<key key>

cinder metadata-show

usage: cinder metadata-show <volume>

显示卷元数据。

位置参数

<volume>

卷的 ID。

cinder metadata-update-all

usage: cinder metadata-update-all <volume> <key=value> [<key=value> ...]

更新卷元数据。

位置参数

<volume>

要更新元数据的卷的 ID。

<key=value>

要更新的元数据键值对或对。

cinder migrate

usage: cinder migrate [--force-host-copy [<True|False>]]
                      [--lock-volume [<True|False>]] [--cluster CLUSTER]
                      <volume> [<host>]

将卷迁移到新主机。

位置参数

<volume>

要迁移的卷的 ID。

<host>

目标主机。格式为:host@backend-name#pool

可选参数

--force-host-copy <True|False>

启用或禁用基于主机的强制迁移,从而绕过驱动程序优化。默认值为 False。

--lock-volume <True|False>

启用或禁用由其他命令引起的卷迁移终止。此选项适用于可用卷。True 表示锁定卷状态,不允许中止迁移。卷状态在迁移期间为维护状态。False 表示允许中止卷迁移。卷状态仍为原始状态。默认值为 False。

--cluster None

目标集群。格式为:cluster@backend-name#pool

cinder qos-associate

usage: cinder qos-associate <qos_specs> <volume_type_id>

将 qos 规范与指定的卷类型关联。

位置参数

<qos_specs>

QoS 规范的 ID。

<volume_type_id>

要关联 QoS 规范的卷类型的 ID。

cinder qos-create

usage: cinder qos-create <name> <key=value> [<key=value> ...]

创建 qos 规范。

位置参数

<name>

新 QoS 规范的名称。

<key=value>

QoS 规范。

cinder qos-delete

usage: cinder qos-delete [--force [<True|False>]] <qos_specs>

删除指定的 qos 规范。

位置参数

<qos_specs>

要删除的 QoS 规范的 ID。

可选参数

--force <True|False>

启用或禁用正在使用的 QoS 规范的删除。默认值为 False。

cinder qos-disassociate

usage: cinder qos-disassociate <qos_specs> <volume_type_id>

将 qos 规范从指定的卷类型分离。

位置参数

<qos_specs>

QoS 规范的 ID。

<volume_type_id>

要关联 QoS 规范的卷类型的 ID。

cinder qos-disassociate-all

usage: cinder qos-disassociate-all <qos_specs>

将 qos 规范从其所有关联中分离。

位置参数

<qos_specs>

要操作的 QoS 规范的 ID。

cinder qos-get-association

usage: cinder qos-get-association <qos_specs>

列出与指定的 qos 规范的所有关联。

位置参数

<qos_specs>

QoS 规范的 ID。

cinder qos-key

usage: cinder qos-key <qos_specs> <action> key=value [key=value ...]

为 qos 规范设置或取消设置规范。

位置参数

<qos_specs>

QoS 规范的 ID。

<action>

操作。有效值为“set”或“unset”。

key=value

要设置或取消设置的元数据键值对。对于取消设置,仅指定键。

cinder qos-list

usage: cinder qos-list

列出 qos 规范。

cinder qos-show

usage: cinder qos-show <qos_specs>

显示 qos 规范详细信息。

位置参数

<qos_specs>

要显示的 QoS 规范的 ID。

cinder quota-class-show

usage: cinder quota-class-show <class>

列出配额类的配额。

位置参数

<class>

要列出配额的配额类的名称。

cinder quota-class-update

usage: cinder quota-class-update [--volumes <volumes>]
                                 [--snapshots <snapshots>]
                                 [--gigabytes <gigabytes>]
                                 [--backups <backups>]
                                 [--backup-gigabytes <backup_gigabytes>]
                                 [--volume-type <volume_type_name>]
                                 [--per-volume-gigabytes <per_volume_gigabytes>]
                                 <class_name>

更新配额类的配额。

位置参数

<class_name>

要设置配额的配额类的名称。

可选参数

--volumes <volumes>

新的“volumes”配额值。默认值为 None。

--snapshots <snapshots>

新的“snapshots”配额值。默认值为 None。

--gigabytes <gigabytes>

新的“gigabytes”配额值。默认值为 None。

--backups <backups>

新的“backups”配额值。默认值为 None。

--backup-gigabytes <backup_gigabytes>

新的“backup_gigabytes”配额值。默认值为 None。

--volume-type <volume_type_name>

卷类型。默认值为 None。

--per-volume-gigabytes <per_volume_gigabytes>

设置最大卷大小限制。默认值为 None。

cinder quota-defaults

usage: cinder quota-defaults <tenant_id>

列出租户的默认配额。

位置参数

<tenant_id>

要列出配额默认值的租户的 ID。

cinder quota-delete

usage: cinder quota-delete <tenant_id>

删除租户的配额。

位置参数

<tenant_id>

要删除配额的租户的 UUID。

cinder quota-show

usage: cinder quota-show <tenant_id>

列出租户的配额。

位置参数

<tenant_id>

要列出配额的租户的 ID。

cinder quota-update

usage: cinder quota-update [--volumes <volumes>] [--snapshots <snapshots>]
                           [--gigabytes <gigabytes>] [--backups <backups>]
                           [--backup-gigabytes <backup_gigabytes>]
                           [--groups <groups>]
                           [--volume-type <volume_type_name>]
                           [--per-volume-gigabytes <per_volume_gigabytes>]
                           [--skip-validation <skip_validation>]
                           <tenant_id>

更新租户的配额。

位置参数

<tenant_id>

要设置配额的租户的 ID。

可选参数

--volumes <volumes>

新的“volumes”配额值。默认值为 None。

--snapshots <snapshots>

新的“snapshots”配额值。默认值为 None。

--gigabytes <gigabytes>

新的“gigabytes”配额值。默认值为 None。

--backups <backups>

新的“backups”配额值。默认值为 None。

--backup-gigabytes <backup_gigabytes>

新的“backup_gigabytes”配额值。默认值为 None。

--groups <groups>

新的“groups”配额值。默认值为 None。

--volume-type <volume_type_name>

卷类型。默认值为 None。

--per-volume-gigabytes <per_volume_gigabytes>

设置最大卷大小限制。默认值为 None。

--skip-validation <skip_validation>

跳过验证现有的资源配额。默认值为 False。

cinder quota-usage

usage: cinder quota-usage <tenant_id>

列出租户的配额使用情况。

位置参数

<tenant_id>

要列出配额使用情况的租户 ID。

cinder rate-limits

usage: cinder rate-limits [<tenant_id>]

列出用户的速率限制。

位置参数

<tenant_id>

显示单个租户的信息(仅限管理员)。

cinder readonly-mode-update

usage: cinder readonly-mode-update <volume> <True|true|False|false>

更新卷的只读访问模式标志。

位置参数

<volume>

要更新的卷的 ID。

<True|true|False|false>

启用或禁用将卷更新为只读访问模式。

cinder reimage

usage: cinder reimage [--reimage-reserved <True|False>] <volume> <image-id>

重建卷,用指定的映像覆盖所有内容

位置参数

<volume>

要重新镜像的卷的名称或 ID

<image-id>

用于重新镜像卷的镜像的 ID。

可选参数

--reimage-reserved <True|False>

启用或禁用对处于保留状态的卷进行重新镜像,否则只有处于“可用”或“错误”状态的卷才能被重新镜像。默认值为 False。

cinder rename

usage: cinder rename [--description <description>] <volume> [<name>]

重命名卷。

位置参数

<volume>

要重命名的卷的名称或 ID。

<name>

卷的新名称。

可选参数

--description <description>

卷描述。默认值=None。

cinder reset-state

usage: cinder reset-state [--type <type>] [--state <state>]
                          [--attach-status <attach-status>]
                          [--reset-migration-status]
                          <entity> [<entity> ...]

显式更新 Cinder 数据库中的实体状态。

位置参数

<entity>

要更新的实体的名称或 ID。

可选参数

--type <type>

要更新的实体类型。可用的资源包括:‘volume’(卷)、‘snapshot’(快照)、‘backup’(备份)、‘group’(组)(自 3.20 起)和 ‘group-snapshot’(组快照)(自 3.19 起),默认值为 volume。

--state <state>

要分配给实体的状态。注意:此命令只是更改数据库中实体的状态,不考虑实际状态,使用时请谨慎。默认值为 None,表示状态未更改。

--attach-status <attach-status>

仅用于卷实体。要分配给卷的附加状态,不考虑实际状态。有效值为“attached”(已附加)和“detached”(已分离)。默认值为 None,表示状态未更改。

--reset-migration-status None

仅用于卷实体。清除数据库中卷的迁移状态,该状态指示卷是卷迁移的源还是目标,不考虑实际状态。

cinder retype

usage: cinder retype [--migration-policy <never|on-demand>]
                     <volume> <volume-type>

更改卷的卷类型。

位置参数

<volume>

要修改类型的卷的名称或 ID。

<volume-type>

新的卷类型。

可选参数

--migration-policy <never|on-demand>

卷重新类型化期间的迁移策略。

cinder revert-to-snapshot

usage: cinder revert-to-snapshot <snapshot>

将卷恢复到指定的快照。

位置参数

<snapshot>

要恢复的快照的名称或 ID。快照必须是 cinder 识别到的最新快照。

cinder service-disable

usage: cinder service-disable [--reason <reason>] <hostname> <binary>

禁用该服务。

位置参数

<hostname>

主机名。

<binary>

服务二进制文件。

可选参数

--reason <reason>

禁用服务的原因。

cinder service-enable

usage: cinder service-enable <hostname> <binary>

启用该服务。

位置参数

<hostname>

主机名。

<binary>

服务二进制文件。

cinder service-get-log

usage: cinder service-get-log
                              [--binary {,*,cinder-api,cinder-volume,cinder-scheduler,cinder-backup}]
                              [--server SERVER] [--prefix PREFIX]

获取服务日志级别。

可选参数

--binary None

要查询的二进制文件。

--server None

服务的宿主机或集群值。

--prefix None

日志的前缀。例如:“sqlalchemy.”。

cinder service-list

usage: cinder service-list [--host <hostname>] [--binary <binary>]
                           [--withreplication [<True|False>]]

列出所有服务。按主机和二进制服务进行筛选。

可选参数

--host <hostname>

主机名。默认值为 None。

--binary <binary>

服务二进制文件。默认值为 None。

--withreplication <True|False>

启用或禁用显示 c-vol 服务的复制信息。默认值为 False。

cinder service-set-log

usage: cinder service-set-log
                              [--binary {,*,cinder-api,cinder-volume,cinder-scheduler,cinder-backup}]
                              [--server SERVER] [--prefix PREFIX]
                              <log-level>

设置服务日志级别。

位置参数

<log-level>

所需的日志级别。

可选参数

--binary None

要更改的二进制文件。

--server None

服务的宿主机或集群值。

--prefix None

日志的前缀。例如:“cinder.volume.drivers.”。

cinder set-bootable

usage: cinder set-bootable <volume> <True|true|False|false>

更新卷的可引导状态。

位置参数

<volume>

要更新的卷的 ID。

<True|true|False|false>

标志,指示卷是否可引导。

cinder show

usage: cinder show <volume>

显示卷详细信息。

位置参数

<volume>

卷的名称或 ID。

cinder snapshot-create

usage: cinder snapshot-create [--name <name>] [--description <description>]
                              [--metadata [<key=value> ...]]
                              <volume>

创建快照。

位置参数

<volume>

要创建快照的卷的名称或 ID。

可选参数

--name <name>

快照名称。默认值为 None。

--description <description>

快照描述。默认值为 None。

--metadata <key=value>

快照元数据键值对。默认值为 None。

cinder snapshot-delete

usage: cinder snapshot-delete [--force] <snapshot> [<snapshot> ...]

删除一个或多个快照。

位置参数

<snapshot>

要删除的快照的名称或 ID。

可选参数

--force None

允许删除状态不是“可用”或“错误”的卷的快照。默认值为 False。

cinder snapshot-list

usage: cinder snapshot-list [--all-tenants [<0|1>]] [--name <name>]
                            [--status <status>] [--volume-id <volume-id>]
                            [--marker <marker>] [--limit <limit>]
                            [--sort <key>[:<direction>]] [--tenant [<tenant>]]
                            [--metadata [<key=value> ...]]
                            [--filters [<key=value> ...]]
                            [--with-count [<True|False>]]

列出所有快照。

可选参数

--all-tenants <0|1>

显示所有租户的详细信息。仅限管理员。

--name <name>

按名称过滤结果。默认值=None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的‘–filters’选项。

--status <status>

按状态筛选结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的“--filters”选项。

--volume-id <volume-id>

按卷 ID 筛选结果。默认值为 None。此选项已被弃用,将在较新版本中删除。请使用自 3.33 起引入的“--filters”选项。

--marker <marker>

从该 ID 开始返回快照列表中的后续快照。默认值为 None。

--limit <limit>

要返回的最大快照数。默认值为 None。

--sort <key>[:<direction>]

逗号分隔的排序键和方向列表,格式为 <key>[:<asc|desc>]。有效键:id、status、size、availability_zone、name、bootable、created_at、reference。默认值为 None。

--tenant <tenant>

显示单个租户的信息(仅限管理员)。

--metadata <key=value>

按元数据键值对过滤结果。需要卷 API 版本 >=3.22。默认值为 None。此选项已弃用,将在较新版本中删除。请使用自 3.33 起引入的‘–filters’选项。

--filters <key=value>

筛选键值对。请使用“cinder list-filters”查看服务器上启用的筛选器。如果键支持,请使用“key~=value”进行不精确筛选。默认值为 None。

--with-count <True|False>

显示快照实体的总数。当请求中应用分页时,此选项很有用。

cinder snapshot-manage

usage: cinder snapshot-manage [--id-type <id-type>] [--name <name>]
                              [--description <description>]
                              [--metadata [<key=value> ...]]
                              <volume> <identifier>

管理现有的快照。

位置参数

<volume>

已经在卷后端存在的 Cinder 卷。

<identifier>

现有快照的名称或其他标识符。此项特定于后端。

可选参数

--id-type <id-type>

提供的后端设备标识符的类型,通常为 source-name 或 source-id(默认值为 source-name)。

--name <name>

快照名称(默认值为 None)。

--description <description>

快照描述(默认值为 None)。

--metadata <key=value>

元数据键=值对(默认值为 None)。

cinder snapshot-manageable-list

usage: cinder snapshot-manageable-list [--detailed <detailed>]
                                       [--marker <marker>] [--limit <limit>]
                                       [--offset <offset>]
                                       [--sort <key>[:<direction>]]
                                       [--cluster CLUSTER]
                                       [<host>]

列出所有可管理的快照。

位置参数

<host>

要在其上列出可管理快照的 Cinder 主机;格式为:host@backend-name#pool

可选参数

--detailed <detailed>

返回详细信息(默认值为 true)。

--marker <marker>

从卷列表中较晚出现的位置开始返回卷,该位置由此引用表示。此引用应为 json 格式。默认值为 None。

--limit <limit>

要返回的最大卷数。默认值为 None。

--offset <offset>

在标记之后要跳过的卷数。默认值为 None。

--sort <key>[:<direction>]

以 <key>[:<asc|desc>] 形式分隔的排序键和方向的逗号分隔列表。有效键:size、reference。默认值为 None。

--cluster None

要在其上列出可管理快照的 Cinder 集群;格式为:cluster@backend-name#pool

cinder snapshot-metadata

usage: cinder snapshot-metadata <snapshot> <action> <key=value>
                                [<key=value> ...]

设置或删除快照元数据。

位置参数

<snapshot>

要更新元数据的快照的 ID。

<action>

操作。有效值为“set”或“unset”。

<key=value>

要设置或取消设置的元数据键值对。对于取消设置,仅指定键。

cinder snapshot-metadata-show

usage: cinder snapshot-metadata-show <snapshot>

显示快照元数据。

位置参数

<snapshot>

快照的 ID。

cinder snapshot-metadata-update-all

usage: cinder snapshot-metadata-update-all <snapshot> <key=value>
                                           [<key=value> ...]

更新快照元数据。

位置参数

<snapshot>

要更新元数据的快照的 ID。

<key=value>

要更新的元数据键值对。

cinder snapshot-rename

usage: cinder snapshot-rename [--description <description>]
                              <snapshot> [<name>]

重命名快照。

位置参数

<snapshot>

快照的名称或 ID。

<name>

快照的新名称。

可选参数

--description <description>

快照描述。默认值为 None。

cinder snapshot-reset-state

usage: cinder snapshot-reset-state [--state <state>]
                                   <snapshot> [<snapshot> ...]

显式更新快照状态。

位置参数

<snapshot>

要修改的快照的名称或 ID。

可选参数

--state <state>

要分配给快照的状态。有效值为“available”(可用)、“error”(错误)、“creating”(创建中)、“deleting”(删除中)和“error_deleting”(删除错误)。注意:此命令只是更改数据库中快照的状态,不考虑实际状态,使用时请谨慎。默认值为 available。

cinder snapshot-show

usage: cinder snapshot-show <snapshot>

显示快照详细信息。

位置参数

<snapshot>

快照的名称或 ID。

cinder snapshot-unmanage

usage: cinder snapshot-unmanage <snapshot>

停止管理快照。

位置参数

<snapshot>

要取消管理的快照的名称或 ID。

cinder summary

usage: cinder summary [--all-tenants [<0|1>]]

获取卷摘要。

可选参数

--all-tenants <0|1>

显示所有租户的详细信息。仅限管理员。

cinder thaw-host

usage: cinder thaw-host <hostname>

解冻并启用指定的 cinder-volume 主机。

位置参数

<hostname>

主机名。

cinder transfer-accept

usage: cinder transfer-accept <transfer> <auth_key>

接受卷传输。

位置参数

<transfer>

要接受的传输的 ID。

<auth_key>

要接受的传输的身份验证密钥。

cinder transfer-create

usage: cinder transfer-create [--name <name>] [--no-snapshots] <volume>

创建卷传输。

位置参数

<volume>

要传输的卷的名称或 ID。

可选参数

--name <name>

传输名称。默认值为 None。

--no-snapshots None

允许或禁止传输不带快照的卷。默认值为 False。

cinder transfer-delete

usage: cinder transfer-delete <transfer> [<transfer> ...]

撤销传输。

位置参数

<transfer>

要删除的传输的名称或 ID。

cinder transfer-list

usage: cinder transfer-list [--all-tenants [<0|1>]]
                            [--sort <key>[:<direction>]]
                            [--filters [<key=value> ...]]

列出所有传输。

可选参数

--all-tenants <0|1>

显示所有租户的详细信息。仅限管理员。

--sort <key>[:<direction>]

排序键和方向,格式为 <key>[:<asc|desc>]。

--filters <key=value>

过滤键值对。

cinder transfer-show

usage: cinder transfer-show <transfer>

显示传输详细信息。

位置参数

<transfer>

要接受的传输的名称或 ID。

cinder type-access-add

usage: cinder type-access-add --volume-type <volume_type> --project-id
                              <project_id>

为给定的项目添加卷类型访问权限。

可选参数

--volume-type <volume_type>

要为给定项目添加访问权限的卷类型名称或 ID。

--project-id <project_id>

要添加卷类型访问权限的项目 ID。

cinder type-access-list

usage: cinder type-access-list --volume-type <volume_type>

打印有关给定卷类型的访问信息。

可选参数

--volume-type <volume_type>

按卷类型名称或 ID 过滤结果。

cinder type-access-remove

usage: cinder type-access-remove --volume-type <volume_type> --project-id
                                 <project_id>

删除给定项目的卷类型访问权限。

可选参数

--volume-type <volume_type>

要为给定项目删除访问权限的卷类型名称或 ID。

--project-id <project_id>

要删除卷类型访问权限的项目 ID。

cinder type-create

usage: cinder type-create [--description <description>]
                          [--is-public <is-public>]
                          <name>

创建一个卷类型。

位置参数

<name>

新卷类型的名称。

可选参数

--description <description>

新卷类型的描述。

--is-public <is-public>

使类型可供公众访问(默认值为 true)。

cinder type-default

usage: cinder type-default

列出默认卷类型。

cinder type-delete

usage: cinder type-delete <vol_type> [<vol_type> ...]

删除卷类型或类型。

位置参数

<vol_type>

要删除的卷类型或类型的名称或 ID。

cinder type-key

usage: cinder type-key <vtype> <action> <key=value> [<key=value> ...]

为卷类型设置或取消设置 extra_spec。

位置参数

<vtype>

卷类型的名称或 ID。

<action>

操作。有效值为“set”或“unset”。

<key=value>

要设置或取消的额外规格键值对。要取消,仅指定键。

cinder type-list

usage: cinder type-list [--filters [<key=value> ...]]

列出可用的“卷类型”。(仅限管理员可以看到私有类型)

可选参数

--filters <key=value>

过滤键值对。仅限管理员。

cinder type-show

usage: cinder type-show <volume_type>

显示卷类型详细信息。

位置参数

<volume_type>

卷类型名称或 ID。

cinder type-update

usage: cinder type-update [--name <name>] [--description <description>]
                          [--is-public <is-public>]
                          <id>

更新卷类型名称、描述和/或 is_public。

位置参数

<id>

卷类型的 ID。

可选参数

--name <name>

卷类型的名称。

--description <description>

卷类型的描述。

--is-public <is-public>

使类型可供公众访问或不可访问。

cinder unmanage

usage: cinder unmanage <volume>

停止管理卷。

位置参数

<volume>

要取消管理的卷的名称或 ID。

cinder upload-to-image

usage: cinder upload-to-image [--force [<True|False>]]
                              [--container-format <container-format>]
                              [--disk-format <disk-format>]
                              [--visibility <public|private|community|shared>]
                              [--protected <True|False>]
                              <volume> <image-name>

将卷上传到 Image Service 作为映像。

位置参数

<volume>

要创建快照的卷的名称或 ID。

<image-name>

新的镜像名称。

可选参数

--force <True|False>

启用或禁用上传附加到实例的卷。默认值为 False。此选项可能不受您的云的支持。

--container-format <container-format>

容器格式类型。默认值为 bare。

--disk-format <disk-format>

磁盘格式类型。默认值为 raw。

--visibility <public|private|community|shared>

将镜像可见性设置为 public(公共)、private(私有)、community(社区)或 shared(共享)。默认值为 private。

--protected <True|False>

防止删除镜像。默认值为 False。

cinder version-list

usage: cinder version-list

列出所有 API 版本。

cinder work-cleanup

usage: cinder work-cleanup [--cluster <cluster-name>] [--host <hostname>]
                           [--binary <binary>]
                           [--is-up <True|true|False|false>]
                           [--disabled <True|true|False|false>]
                           [--resource-id <resource-id>]
                           [--resource-type <Volume|Snapshot>]
                           [--service-id <service-id>]

请求清理服务,可选择进行筛选。

可选参数

--cluster <cluster-name>

集群名称。默认值为 None。

--host <hostname>

服务主机名。默认值为 None。

--binary <binary>

服务二进制文件。默认值为 None。

--is-up <True|true|False|false>

如果设置为 true,则过滤处于 up 状态的服务,如果设置为 false,则过滤处于 down 状态的服务。默认值为 None,表示忽略 up/down 状态。

--disabled <True|true|False|false>

按禁用状态过滤。默认值=None。

--resource-id <resource-id>

要清理的资源的 UUID。默认值为 None。

--resource-type <Volume|Snapshot>

要清理的资源类型。

--service-id <service-id>

数据库中的服务 ID 字段,而不是服务的 UUID。默认值为 None。

cinder help

usage: cinder help [<subcommand>]

显示有关此程序或其子命令的帮助信息。

位置参数

<subcommand>

显示 <subcommand> 的帮助信息。