block-export.json (b71fd73cc459ce1ef545a40ff8fbce5ff242b103) | block-export.json (a937b6aa739f65f2cae2ad9a7eb65a309ad2a359) |
---|---|
1# -*- Mode: Python -*- 2# vim: filetype=python 3 4## 5# == Block device exports 6## 7 8{ 'include': 'sockets.json' } 9{ 'include': 'block-core.json' } 10 11## 12# @NbdServerOptions: 13# | 1# -*- Mode: Python -*- 2# vim: filetype=python 3 4## 5# == Block device exports 6## 7 8{ 'include': 'sockets.json' } 9{ 'include': 'block-core.json' } 10 11## 12# @NbdServerOptions: 13# |
14# Keep this type consistent with the nbd-server-start arguments. The only 15# intended difference is using SocketAddress instead of SocketAddressLegacy. | 14# Keep this type consistent with the nbd-server-start arguments. The 15# only intended difference is using SocketAddress instead of 16# SocketAddressLegacy. |
16# 17# @addr: Address on which to listen. | 17# 18# @addr: Address on which to listen. |
19# |
|
18# @tls-creds: ID of the TLS credentials object (since 2.6). | 20# @tls-creds: ID of the TLS credentials object (since 2.6). |
21# |
|
19# @tls-authz: ID of the QAuthZ authorization object used to validate | 22# @tls-authz: ID of the QAuthZ authorization object used to validate |
20# the client's x509 distinguished name. This object is 21# is only resolved at time of use, so can be deleted and 22# recreated on the fly while the NBD server is active. 23# If missing, it will default to denying access (since 4.0). 24# @max-connections: The maximum number of connections to allow at the same 25# time, 0 for unlimited. Setting this to 1 also stops 26# the server from advertising multiple client support 27# (since 5.2; default: 0) | 23# the client's x509 distinguished name. This object is is only 24# resolved at time of use, so can be deleted and recreated on the 25# fly while the NBD server is active. If missing, it will default 26# to denying access (since 4.0). |
28# | 27# |
28# @max-connections: The maximum number of connections to allow at the 29# same time, 0 for unlimited. Setting this to 1 also stops the 30# server from advertising multiple client support (since 5.2; 31# default: 0) 32# |
|
29# Since: 4.2 30## 31{ 'struct': 'NbdServerOptions', 32 'data': { 'addr': 'SocketAddress', 33 '*tls-creds': 'str', 34 '*tls-authz': 'str', 35 '*max-connections': 'uint32' } } 36 37## 38# @nbd-server-start: 39# 40# Start an NBD server listening on the given host and port. Block | 33# Since: 4.2 34## 35{ 'struct': 'NbdServerOptions', 36 'data': { 'addr': 'SocketAddress', 37 '*tls-creds': 'str', 38 '*tls-authz': 'str', 39 '*max-connections': 'uint32' } } 40 41## 42# @nbd-server-start: 43# 44# Start an NBD server listening on the given host and port. Block |
41# devices can then be exported using @nbd-server-add. The NBD 42# server will present them as named exports; for example, another 43# QEMU instance could refer to them as "nbd:HOST:PORT:exportname=NAME". | 45# devices can then be exported using @nbd-server-add. The NBD server 46# will present them as named exports; for example, another QEMU 47# instance could refer to them as "nbd:HOST:PORT:exportname=NAME". |
44# | 48# |
45# Keep this type consistent with the NbdServerOptions type. The only intended 46# difference is using SocketAddressLegacy instead of SocketAddress. | 49# Keep this type consistent with the NbdServerOptions type. The only 50# intended difference is using SocketAddressLegacy instead of 51# SocketAddress. |
47# 48# @addr: Address on which to listen. | 52# 53# @addr: Address on which to listen. |
54# |
|
49# @tls-creds: ID of the TLS credentials object (since 2.6). | 55# @tls-creds: ID of the TLS credentials object (since 2.6). |
56# |
|
50# @tls-authz: ID of the QAuthZ authorization object used to validate | 57# @tls-authz: ID of the QAuthZ authorization object used to validate |
51# the client's x509 distinguished name. This object is 52# is only resolved at time of use, so can be deleted and 53# recreated on the fly while the NBD server is active. 54# If missing, it will default to denying access (since 4.0). 55# @max-connections: The maximum number of connections to allow at the same 56# time, 0 for unlimited. Setting this to 1 also stops 57# the server from advertising multiple client support 58# (since 5.2; default: 0). | 58# the client's x509 distinguished name. This object is is only 59# resolved at time of use, so can be deleted and recreated on the 60# fly while the NBD server is active. If missing, it will default 61# to denying access (since 4.0). |
59# | 62# |
63# @max-connections: The maximum number of connections to allow at the 64# same time, 0 for unlimited. Setting this to 1 also stops the 65# server from advertising multiple client support (since 5.2; 66# default: 0). 67# |
|
60# Returns: error if the server is already running. 61# 62# Since: 1.3 63## 64{ 'command': 'nbd-server-start', 65 'data': { 'addr': 'SocketAddressLegacy', 66 '*tls-creds': 'str', 67 '*tls-authz': 'str', 68 '*max-connections': 'uint32' }, 69 'allow-preconfig': true } 70 71## 72# @BlockExportOptionsNbdBase: 73# | 68# Returns: error if the server is already running. 69# 70# Since: 1.3 71## 72{ 'command': 'nbd-server-start', 73 'data': { 'addr': 'SocketAddressLegacy', 74 '*tls-creds': 'str', 75 '*tls-authz': 'str', 76 '*max-connections': 'uint32' }, 77 'allow-preconfig': true } 78 79## 80# @BlockExportOptionsNbdBase: 81# |
74# An NBD block export (common options shared between nbd-server-add and 75# the NBD branch of block-export-add). | 82# An NBD block export (common options shared between nbd-server-add 83# and the NBD branch of block-export-add). |
76# | 84# |
77# @name: Export name. If unspecified, the @device parameter is used as the 78# export name. (Since 2.12) | 85# @name: Export name. If unspecified, the @device parameter is used 86# as the export name. (Since 2.12) |
79# 80# @description: Free-form description of the export, up to 4096 bytes. | 87# 88# @description: Free-form description of the export, up to 4096 bytes. |
81# (Since 5.0) | 89# (Since 5.0) |
82# 83# Since: 5.0 84## 85{ 'struct': 'BlockExportOptionsNbdBase', 86 'data': { '*name': 'str', '*description': 'str' } } 87 88## 89# @BlockExportOptionsNbd: 90# 91# An NBD block export (distinct options used in the NBD branch of 92# block-export-add). 93# 94# @bitmaps: Also export each of the named dirty bitmaps reachable from | 90# 91# Since: 5.0 92## 93{ 'struct': 'BlockExportOptionsNbdBase', 94 'data': { '*name': 'str', '*description': 'str' } } 95 96## 97# @BlockExportOptionsNbd: 98# 99# An NBD block export (distinct options used in the NBD branch of 100# block-export-add). 101# 102# @bitmaps: Also export each of the named dirty bitmaps reachable from |
95# @device, so the NBD client can use NBD_OPT_SET_META_CONTEXT with 96# the metadata context name "qemu:dirty-bitmap:BITMAP" to inspect 97# each bitmap. 98# Since 7.1 bitmap may be specified by node/name pair. | 103# @device, so the NBD client can use NBD_OPT_SET_META_CONTEXT with 104# the metadata context name "qemu:dirty-bitmap:BITMAP" to inspect 105# each bitmap. Since 7.1 bitmap may be specified by node/name 106# pair. |
99# | 107# |
100# @allocation-depth: Also export the allocation depth map for @device, so 101# the NBD client can use NBD_OPT_SET_META_CONTEXT with 102# the metadata context name "qemu:allocation-depth" to 103# inspect allocation details. (since 5.2) | 108# @allocation-depth: Also export the allocation depth map for @device, 109# so the NBD client can use NBD_OPT_SET_META_CONTEXT with the 110# metadata context name "qemu:allocation-depth" to inspect 111# allocation details. (since 5.2) |
104# 105# Since: 5.2 106## 107{ 'struct': 'BlockExportOptionsNbd', 108 'base': 'BlockExportOptionsNbdBase', 109 'data': { '*bitmaps': ['BlockDirtyBitmapOrStr'], 110 '*allocation-depth': 'bool' } } 111 112## 113# @BlockExportOptionsVhostUserBlk: 114# 115# A vhost-user-blk block export. 116# | 112# 113# Since: 5.2 114## 115{ 'struct': 'BlockExportOptionsNbd', 116 'base': 'BlockExportOptionsNbdBase', 117 'data': { '*bitmaps': ['BlockDirtyBitmapOrStr'], 118 '*allocation-depth': 'bool' } } 119 120## 121# @BlockExportOptionsVhostUserBlk: 122# 123# A vhost-user-blk block export. 124# |
117# @addr: The vhost-user socket on which to listen. Both 'unix' and 'fd' 118# SocketAddress types are supported. Passed fds must be UNIX domain 119# sockets. 120# @logical-block-size: Logical block size in bytes. Defaults to 512 bytes. 121# @num-queues: Number of request virtqueues. Must be greater than 0. Defaults 122# to 1. | 125# @addr: The vhost-user socket on which to listen. Both 'unix' and 126# 'fd' SocketAddress types are supported. Passed fds must be UNIX 127# domain sockets. |
123# | 128# |
129# @logical-block-size: Logical block size in bytes. Defaults to 512 130# bytes. 131# 132# @num-queues: Number of request virtqueues. Must be greater than 0. 133# Defaults to 1. 134# |
|
124# Since: 5.2 125## 126{ 'struct': 'BlockExportOptionsVhostUserBlk', 127 'data': { 'addr': 'SocketAddress', 128 '*logical-block-size': 'size', 129 '*num-queues': 'uint16'} } 130 131## 132# @FuseExportAllowOther: 133# 134# Possible allow_other modes for FUSE exports. 135# 136# @off: Do not pass allow_other as a mount option. 137# 138# @on: Pass allow_other as a mount option. 139# 140# @auto: Try mounting with allow_other first, and if that fails, retry | 135# Since: 5.2 136## 137{ 'struct': 'BlockExportOptionsVhostUserBlk', 138 'data': { 'addr': 'SocketAddress', 139 '*logical-block-size': 'size', 140 '*num-queues': 'uint16'} } 141 142## 143# @FuseExportAllowOther: 144# 145# Possible allow_other modes for FUSE exports. 146# 147# @off: Do not pass allow_other as a mount option. 148# 149# @on: Pass allow_other as a mount option. 150# 151# @auto: Try mounting with allow_other first, and if that fails, retry |
141# without allow_other. | 152# without allow_other. |
142# 143# Since: 6.1 144## 145{ 'enum': 'FuseExportAllowOther', 146 'data': ['off', 'on', 'auto'] } 147 148## 149# @BlockExportOptionsFuse: 150# 151# Options for exporting a block graph node on some (file) mountpoint 152# as a raw image. 153# | 153# 154# Since: 6.1 155## 156{ 'enum': 'FuseExportAllowOther', 157 'data': ['off', 'on', 'auto'] } 158 159## 160# @BlockExportOptionsFuse: 161# 162# Options for exporting a block graph node on some (file) mountpoint 163# as a raw image. 164# |
154# @mountpoint: Path on which to export the block device via FUSE. 155# This must point to an existing regular file. | 165# @mountpoint: Path on which to export the block device via FUSE. This 166# must point to an existing regular file. |
156# 157# @growable: Whether writes beyond the EOF should grow the block node | 167# 168# @growable: Whether writes beyond the EOF should grow the block node |
158# accordingly. (default: false) | 169# accordingly. (default: false) |
159# 160# @allow-other: If this is off, only qemu's user is allowed access to | 170# 171# @allow-other: If this is off, only qemu's user is allowed access to |
161# this export. That cannot be changed even with chmod or 162# chown. 163# Enabling this option will allow other users access to 164# the export with the FUSE mount option "allow_other". 165# Note that using allow_other as a non-root user requires 166# user_allow_other to be enabled in the global fuse.conf 167# configuration file. 168# In auto mode (the default), the FUSE export driver will 169# first attempt to mount the export with allow_other, and 170# if that fails, try again without. 171# (since 6.1; default: auto) | 172# this export. That cannot be changed even with chmod or chown. 173# Enabling this option will allow other users access to the export 174# with the FUSE mount option "allow_other". Note that using 175# allow_other as a non-root user requires user_allow_other to be 176# enabled in the global fuse.conf configuration file. In auto 177# mode (the default), the FUSE export driver will first attempt to 178# mount the export with allow_other, and if that fails, try again 179# without. (since 6.1; default: auto) |
172# 173# Since: 6.0 174## 175{ 'struct': 'BlockExportOptionsFuse', 176 'data': { 'mountpoint': 'str', 177 '*growable': 'bool', 178 '*allow-other': 'FuseExportAllowOther' }, 179 'if': 'CONFIG_FUSE' } 180 181## 182# @BlockExportOptionsVduseBlk: 183# 184# A vduse-blk block export. 185# 186# @name: the name of VDUSE device (must be unique across the host). | 180# 181# Since: 6.0 182## 183{ 'struct': 'BlockExportOptionsFuse', 184 'data': { 'mountpoint': 'str', 185 '*growable': 'bool', 186 '*allow-other': 'FuseExportAllowOther' }, 187 'if': 'CONFIG_FUSE' } 188 189## 190# @BlockExportOptionsVduseBlk: 191# 192# A vduse-blk block export. 193# 194# @name: the name of VDUSE device (must be unique across the host). |
187# @num-queues: the number of virtqueues. Defaults to 1. 188# @queue-size: the size of virtqueue. Defaults to 256. 189# @logical-block-size: Logical block size in bytes. Range [512, PAGE_SIZE] 190# and must be power of 2. Defaults to 512 bytes. 191# @serial: the serial number of virtio block device. Defaults to empty string. | |
192# | 195# |
196# @num-queues: the number of virtqueues. Defaults to 1. 197# 198# @queue-size: the size of virtqueue. Defaults to 256. 199# 200# @logical-block-size: Logical block size in bytes. Range [512, 201# PAGE_SIZE] and must be power of 2. Defaults to 512 bytes. 202# 203# @serial: the serial number of virtio block device. Defaults to 204# empty string. 205# |
|
193# Since: 7.1 194## 195{ 'struct': 'BlockExportOptionsVduseBlk', 196 'data': { 'name': 'str', 197 '*num-queues': 'uint16', 198 '*queue-size': 'uint16', 199 '*logical-block-size': 'size', 200 '*serial': 'str' } } 201 202## 203# @NbdServerAddOptions: 204# 205# An NBD block export, per legacy nbd-server-add command. 206# 207# @device: The device name or node name of the node to be exported 208# | 206# Since: 7.1 207## 208{ 'struct': 'BlockExportOptionsVduseBlk', 209 'data': { 'name': 'str', 210 '*num-queues': 'uint16', 211 '*queue-size': 'uint16', 212 '*logical-block-size': 'size', 213 '*serial': 'str' } } 214 215## 216# @NbdServerAddOptions: 217# 218# An NBD block export, per legacy nbd-server-add command. 219# 220# @device: The device name or node name of the node to be exported 221# |
209# @writable: Whether clients should be able to write to the device via the 210# NBD connection (default false). | 222# @writable: Whether clients should be able to write to the device via 223# the NBD connection (default false). |
211# | 224# |
212# @bitmap: Also export a single dirty bitmap reachable from @device, so the 213# NBD client can use NBD_OPT_SET_META_CONTEXT with the metadata 214# context name "qemu:dirty-bitmap:BITMAP" to inspect the bitmap 215# (since 4.0). | 225# @bitmap: Also export a single dirty bitmap reachable from @device, 226# so the NBD client can use NBD_OPT_SET_META_CONTEXT with the 227# metadata context name "qemu:dirty-bitmap:BITMAP" to inspect the 228# bitmap (since 4.0). |
216# 217# Since: 5.0 218## 219{ 'struct': 'NbdServerAddOptions', 220 'base': 'BlockExportOptionsNbdBase', 221 'data': { 'device': 'str', 222 '*writable': 'bool', '*bitmap': 'str' } } 223 224## 225# @nbd-server-add: 226# 227# Export a block node to QEMU's embedded NBD server. 228# | 229# 230# Since: 5.0 231## 232{ 'struct': 'NbdServerAddOptions', 233 'base': 'BlockExportOptionsNbdBase', 234 'data': { 'device': 'str', 235 '*writable': 'bool', '*bitmap': 'str' } } 236 237## 238# @nbd-server-add: 239# 240# Export a block node to QEMU's embedded NBD server. 241# |
229# The export name will be used as the id for the resulting block export. | 242# The export name will be used as the id for the resulting block 243# export. |
230# 231# Features: | 244# 245# Features: |
232# @deprecated: This command is deprecated. Use @block-export-add instead. | |
233# | 246# |
234# Returns: error if the server is not running, or export with the same name 235# already exists. | 247# @deprecated: This command is deprecated. Use @block-export-add 248# instead. |
236# | 249# |
250# Returns: error if the server is not running, or export with the same 251# name already exists. 252# |
|
237# Since: 1.3 238## 239{ 'command': 'nbd-server-add', 240 'data': 'NbdServerAddOptions', 'boxed': true, 'features': ['deprecated'], 241 'allow-preconfig': true } 242 243## 244# @BlockExportRemoveMode: 245# 246# Mode for removing a block export. 247# | 253# Since: 1.3 254## 255{ 'command': 'nbd-server-add', 256 'data': 'NbdServerAddOptions', 'boxed': true, 'features': ['deprecated'], 257 'allow-preconfig': true } 258 259## 260# @BlockExportRemoveMode: 261# 262# Mode for removing a block export. 263# |
248# @safe: Remove export if there are no existing connections, fail otherwise. | 264# @safe: Remove export if there are no existing connections, fail 265# otherwise. |
249# 250# @hard: Drop all connections immediately and remove export. 251# 252# Potential additional modes to be added in the future: 253# | 266# 267# @hard: Drop all connections immediately and remove export. 268# 269# Potential additional modes to be added in the future: 270# |
254# hide: Just hide export from new clients, leave existing connections as is. 255# Remove export after all clients are disconnected. | 271# hide: Just hide export from new clients, leave existing connections 272# as is. Remove export after all clients are disconnected. |
256# | 273# |
257# soft: Hide export from new clients, answer with ESHUTDOWN for all further 258# requests from existing clients. | 274# soft: Hide export from new clients, answer with ESHUTDOWN for all 275# further requests from existing clients. |
259# 260# Since: 2.12 261## 262{'enum': 'BlockExportRemoveMode', 'data': ['safe', 'hard']} 263 264## 265# @nbd-server-remove: 266# 267# Remove NBD export by name. 268# 269# @name: Block export id. 270# | 276# 277# Since: 2.12 278## 279{'enum': 'BlockExportRemoveMode', 'data': ['safe', 'hard']} 280 281## 282# @nbd-server-remove: 283# 284# Remove NBD export by name. 285# 286# @name: Block export id. 287# |
271# @mode: Mode of command operation. See @BlockExportRemoveMode description. 272# Default is 'safe'. | 288# @mode: Mode of command operation. See @BlockExportRemoveMode 289# description. Default is 'safe'. |
273# 274# Features: | 290# 291# Features: |
275# @deprecated: This command is deprecated. Use @block-export-del instead. | |
276# | 292# |
293# @deprecated: This command is deprecated. Use @block-export-del 294# instead. 295# |
|
277# Returns: error if 278# | 296# Returns: error if 297# |
279# - the server is not running 280# - export is not found 281# - mode is 'safe' and there are existing connections | 298# - the server is not running 299# - export is not found 300# - mode is 'safe' and there are existing connections |
282# 283# Since: 2.12 284## 285{ 'command': 'nbd-server-remove', 286 'data': {'name': 'str', '*mode': 'BlockExportRemoveMode'}, 287 'features': ['deprecated'], 288 'allow-preconfig': true } 289 290## 291# @nbd-server-stop: 292# | 301# 302# Since: 2.12 303## 304{ 'command': 'nbd-server-remove', 305 'data': {'name': 'str', '*mode': 'BlockExportRemoveMode'}, 306 'features': ['deprecated'], 307 'allow-preconfig': true } 308 309## 310# @nbd-server-stop: 311# |
293# Stop QEMU's embedded NBD server, and unregister all devices previously 294# added via @nbd-server-add. | 312# Stop QEMU's embedded NBD server, and unregister all devices 313# previously added via @nbd-server-add. |
295# 296# Since: 1.3 297## 298{ 'command': 'nbd-server-stop', 299 'allow-preconfig': true } 300 301## 302# @BlockExportType: 303# 304# An enumeration of block export types 305# 306# @nbd: NBD export | 314# 315# Since: 1.3 316## 317{ 'command': 'nbd-server-stop', 318 'allow-preconfig': true } 319 320## 321# @BlockExportType: 322# 323# An enumeration of block export types 324# 325# @nbd: NBD export |
326# |
|
307# @vhost-user-blk: vhost-user-blk export (since 5.2) | 327# @vhost-user-blk: vhost-user-blk export (since 5.2) |
328# |
|
308# @fuse: FUSE export (since: 6.0) | 329# @fuse: FUSE export (since: 6.0) |
330# |
|
309# @vduse-blk: vduse-blk export (since 7.1) 310# 311# Since: 4.2 312## 313{ 'enum': 'BlockExportType', 314 'data': [ 'nbd', 315 { 'name': 'vhost-user-blk', 316 'if': 'CONFIG_VHOST_USER_BLK_SERVER' }, 317 { 'name': 'fuse', 'if': 'CONFIG_FUSE' }, 318 { 'name': 'vduse-blk', 'if': 'CONFIG_VDUSE_BLK_EXPORT' } ] } 319 320## 321# @BlockExportOptions: 322# | 331# @vduse-blk: vduse-blk export (since 7.1) 332# 333# Since: 4.2 334## 335{ 'enum': 'BlockExportType', 336 'data': [ 'nbd', 337 { 'name': 'vhost-user-blk', 338 'if': 'CONFIG_VHOST_USER_BLK_SERVER' }, 339 { 'name': 'fuse', 'if': 'CONFIG_FUSE' }, 340 { 'name': 'vduse-blk', 'if': 'CONFIG_VDUSE_BLK_EXPORT' } ] } 341 342## 343# @BlockExportOptions: 344# |
323# Describes a block export, i.e. how single node should be exported on an 324# external interface. | 345# Describes a block export, i.e. how single node should be exported on 346# an external interface. |
325# | 347# |
326# @id: A unique identifier for the block export (across all export types) | 348# @id: A unique identifier for the block export (across all export 349# types) |
327# | 350# |
328# @node-name: The node name of the block node to be exported (since: 5.2) | 351# @node-name: The node name of the block node to be exported 352# (since: 5.2) |
329# 330# @writable: True if clients should be able to write to the export | 353# 354# @writable: True if clients should be able to write to the export |
331# (default false) | 355# (default false) |
332# | 356# |
333# @writethrough: If true, caches are flushed after every write request to the 334# export before completion is signalled. (since: 5.2; 335# default: false) | 357# @writethrough: If true, caches are flushed after every write request 358# to the export before completion is signalled. (since: 5.2; 359# default: false) |
336# | 360# |
337# @iothread: The name of the iothread object where the export will run. The 338# default is to use the thread currently associated with the 339# block node. (since: 5.2) | 361# @iothread: The name of the iothread object where the export will 362# run. The default is to use the thread currently associated with 363# the block node. (since: 5.2) |
340# | 364# |
341# @fixed-iothread: True prevents the block node from being moved to another 342# thread while the export is active. If true and @iothread is 343# given, export creation fails if the block node cannot be 344# moved to the iothread. The default is false. (since: 5.2) | 365# @fixed-iothread: True prevents the block node from being moved to 366# another thread while the export is active. If true and 367# @iothread is given, export creation fails if the block node 368# cannot be moved to the iothread. The default is false. 369# (since: 5.2) |
345# 346# Since: 4.2 347## 348{ 'union': 'BlockExportOptions', 349 'base': { 'type': 'BlockExportType', 350 'id': 'str', 351 '*fixed-iothread': 'bool', 352 '*iothread': 'str', --- 20 unchanged lines hidden (view full) --- 373## 374{ 'command': 'block-export-add', 375 'data': 'BlockExportOptions', 'boxed': true, 376 'allow-preconfig': true } 377 378## 379# @block-export-del: 380# | 370# 371# Since: 4.2 372## 373{ 'union': 'BlockExportOptions', 374 'base': { 'type': 'BlockExportType', 375 'id': 'str', 376 '*fixed-iothread': 'bool', 377 '*iothread': 'str', --- 20 unchanged lines hidden (view full) --- 398## 399{ 'command': 'block-export-add', 400 'data': 'BlockExportOptions', 'boxed': true, 401 'allow-preconfig': true } 402 403## 404# @block-export-del: 405# |
381# Request to remove a block export. This drops the user's reference to the 382# export, but the export may still stay around after this command returns until 383# the shutdown of the export has completed. | 406# Request to remove a block export. This drops the user's reference 407# to the export, but the export may still stay around after this 408# command returns until the shutdown of the export has completed. |
384# 385# @id: Block export id. 386# | 409# 410# @id: Block export id. 411# |
387# @mode: Mode of command operation. See @BlockExportRemoveMode description. 388# Default is 'safe'. | 412# @mode: Mode of command operation. See @BlockExportRemoveMode 413# description. Default is 'safe'. |
389# | 414# |
390# Returns: Error if the export is not found or @mode is 'safe' and the export 391# is still in use (e.g. by existing client connections) | 415# Returns: Error if the export is not found or @mode is 'safe' and the 416# export is still in use (e.g. by existing client connections) |
392# 393# Since: 5.2 394## 395{ 'command': 'block-export-del', 396 'data': { 'id': 'str', '*mode': 'BlockExportRemoveMode' }, 397 'allow-preconfig': true } 398 399## --- 15 unchanged lines hidden (view full) --- 415# 416# @id: The unique identifier for the block export 417# 418# @type: The block export type 419# 420# @node-name: The node name of the block node that is exported 421# 422# @shutting-down: True if the export is shutting down (e.g. after a | 417# 418# Since: 5.2 419## 420{ 'command': 'block-export-del', 421 'data': { 'id': 'str', '*mode': 'BlockExportRemoveMode' }, 422 'allow-preconfig': true } 423 424## --- 15 unchanged lines hidden (view full) --- 440# 441# @id: The unique identifier for the block export 442# 443# @type: The block export type 444# 445# @node-name: The node name of the block node that is exported 446# 447# @shutting-down: True if the export is shutting down (e.g. after a |
423# block-export-del command, but before the shutdown has 424# completed) | 448# block-export-del command, but before the shutdown has completed) |
425# 426# Since: 5.2 427## 428{ 'struct': 'BlockExportInfo', 429 'data': { 'id': 'str', 430 'type': 'BlockExportType', 431 'node-name': 'str', 432 'shutting-down': 'bool' } } 433 434## 435# @query-block-exports: 436# 437# Returns: A list of BlockExportInfo describing all block exports 438# 439# Since: 5.2 440## 441{ 'command': 'query-block-exports', 'returns': ['BlockExportInfo'], 442 'allow-preconfig': true } | 449# 450# Since: 5.2 451## 452{ 'struct': 'BlockExportInfo', 453 'data': { 'id': 'str', 454 'type': 'BlockExportType', 455 'node-name': 'str', 456 'shutting-down': 'bool' } } 457 458## 459# @query-block-exports: 460# 461# Returns: A list of BlockExportInfo describing all block exports 462# 463# Since: 5.2 464## 465{ 'command': 'query-block-exports', 'returns': ['BlockExportInfo'], 466 'allow-preconfig': true } |