Skip to content

Latest commit

 

History

History
148 lines (105 loc) · 5.29 KB

disk_v1.md

File metadata and controls

148 lines (105 loc) · 5.29 KB

CSI Proxy Disk v1 API

Table of Contents

v1 Disk RPCs

Method Name Request Type Response Type Description
ListDiskLocations ListDiskLocationsRequest ListDiskLocationsResponse ListDiskLocations returns locations <Adapter, Bus, Target, LUN ID> of all disk devices enumerated by the host.
PartitionDisk PartitionDiskRequest PartitionDiskResponse PartitionDisk initializes and partitions a disk device with the GPT partition style (if the disk has not been partitioned already) and returns the resulting volume device ID.
Rescan RescanRequest RescanResponse Rescan refreshes the host's storage cache.
ListDiskIDs ListDiskIDsRequest ListDiskIDsResponse ListDiskIDs returns a map of DiskID objects where the key is the disk number.
GetDiskStats GetDiskStatsRequest GetDiskStatsResponse GetDiskStats returns the stats of a disk (currently it returns the disk size).
SetDiskState SetDiskStateRequest SetDiskStateResponse SetDiskState sets the offline/online state of a disk.
GetDiskState GetDiskStateRequest GetDiskStateResponse GetDiskState gets the offline/online state of a disk.

Top

v1 Disk Messages

DiskIDs

Field Type Label Description
page83 string The disk page83 id.
serial_number string The disk serial number.

DiskLocation

Field Type Label Description
Adapter string
Bus string
Target string
LUNID string

GetDiskStateRequest

Field Type Label Description
disk_number uint32 Disk device number of the disk.

GetDiskStateResponse

Field Type Label Description
is_online bool Online state of the disk. true for online, false for offline.

GetDiskStatsRequest

Field Type Label Description
disk_number uint32 Disk device number of the disk to get the stats from.

GetDiskStatsResponse

Field Type Label Description
total_bytes int64 Total size of the volume.

ListDiskIDsRequest

Intentionally empty.

ListDiskIDsResponse

Field Type Label Description
diskIDs ListDiskIDsResponse.DiskIDsEntry repeated Map of disk numbers and disk identifiers associated with each disk device.

the case is intentional for protoc to generate the field as DiskIDs |

ListDiskIDsResponse.DiskIDsEntry

Field Type Label Description
key uint32
value DiskIDs

ListDiskLocationsRequest

Intentionally empty.

ListDiskLocationsResponse

Field Type Label Description
disk_locations ListDiskLocationsResponse.DiskLocationsEntry repeated Map of disk number and <adapter, bus, target, lun ID> associated with each disk device.

ListDiskLocationsResponse.DiskLocationsEntry

Field Type Label Description
key uint32
value DiskLocation

PartitionDiskRequest

Field Type Label Description
disk_number uint32 Disk device number of the disk to partition.

PartitionDiskResponse

Intentionally empty.

RescanRequest

Intentionally empty.

RescanResponse

Intentionally empty.

SetDiskStateRequest

Field Type Label Description
disk_number uint32 Disk device number of the disk.
is_online bool Online state to set for the disk. true for online, false for offline.

SetDiskStateResponse

Intentionally empty.