Query Raid Controller

GET/zstack/v1/storage-devices/local-raid/controllers
GET/zstack/v1/storage-devices/local-raid/controllers/{uuid}

Headers

Authorization: OAuth the-session-uuid

Curl Example

curl -H "Content-Type: application/json;charset=UTF-8" \
-H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \
-X GET http://localhost:8080/zstack/v1/storage-devices/local-raid/controllers
curl -H "Content-Type: application/json;charset=UTF-8" \
-H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \
-X GET http://localhost:8080/zstack/v1/storage-devices/local-raid/controllers/9f234d08bfa13c6a83bd8df8e551820c

Queryable Fields

Run the CLI command-line tool, enter QueryLocalRaidController and press Tab to view all queryable fields and resource names that support cross-table queries.

API Response

Response Example

{
  "inventories": [
    {
      "uuid": "ba2fe0dcd360397a92748ea6efe9ffd6",
      "name": "raidPhysical",
      "raidLevel": "raid1",
      "raidControllerUuid": "1022305d664e34329a63f350a2fd1e02",
      "enclosureDeviceId": 252,
      "slotNumber": 1,
      "diskGroup": 0,
      "wwn": "50014ee059f2f491",
      "serialNumber": "V6GLEX2S",
      "deviceModel": "HGST HUS726T4TALA6L4",
      "size": 1000204886016,
      "driveState": "Online, Spun Up",
      "locateStatus": "Disabled",
      "driveType": "SATA",
      "mediaType": "HDD",
      "rotationRate": 7200,
      "createDate": "Nov 14, 2017 2:20:57 PM",
      "lastOpDate": "Nov 14, 2017 2:20:57 PM"
    },
    {}
  ]
}
NameTypeDescriptionStarting Version
successboolean 0.6
errorErrorCodeError code. If not null, the operation failed. If null, the operation succeeded. See error for details3.6
inventoriesListSee inventories for details3.6

error

NameTypeDescriptionStarting Version
codeStringError code number. Globally unique identifier of the error, for example SYS.1000, HOST.1001.0.6
descriptionStringBrief error description0.6
detailsStringDetailed error information0.6
elaborationStringReserved field, defaults to null0.6
opaqueLinkedHashMapReserved field, defaults to null0.6
causeErrorCodeRoot cause error. The error that caused the current error. If there is no original error, this field is null.0.6

inventories

NameTypeDescriptionStarting Version
uuidStringUUID of the resource. Uniquely identifies the resource.3.6
nameStringResource name3.6
raidLevelStringRaid level3.6
raidControllerUuidStringRaid Controller Uuid3.6
descriptionStringResource description3.6
enclosureDeviceIdIntegerEnclosure Id3.6
slotNumberIntegerSlot number3.6
deviceIdIntegerDevice Id3.6
diskGroupIntegerDisk Group Id3.6
wwnStringWWN3.6
serialNumberStringSerial number3.6
deviceModelStringDisk model3.6
sizeLongDisk size3.6
driveStateStringDisk status3.6
driveTypeStringInterface type3.6
mediaTypeStringMedia type3.6
rotationRateIntegerRotation speed3.6
createDateTimestampCreate time3.6
lastOpDateTimestampLast update time3.6
locateStatusLocateStatusSee locateStatus for details3.6

locateStatus

NameTypeDescriptionStarting Version
EnabledLocateStatusLocator LED blinking3.6
DisabledLocateStatusLocator LED off3.6

SDK Examples

Java SDK

QueryLocalRaidControllerAction action = new QueryLocalRaidControllerAction();
action.conditions = asList();
action.sessionId = "b86c9016b4f24953a9edefb53ca0678c";
QueryLocalRaidControllerAction.Result res = action.call();

Python SDK

QueryLocalRaidControllerAction action = QueryLocalRaidControllerAction()
action.conditions = []
action.sessionId = "b86c9016b4f24953a9edefb53ca0678c"
QueryLocalRaidControllerAction.Result res = action.call()