Filesystems/{filesystemName}/disks/{diskName}: GET

Gets details of a specific disk that is part of a file system.

Availability

Available on all IBM Spectrum Scale™ editions.

Description

The GET filesystems/{filesystemName}/disks/{diskName} request gets details of a specific disk. For more information about the fields in the data structures that are returned, see the topics mmlsdisk command, mmlsnsd commandand mmlsfs command.

Request URL

https://<IP address or host name of API server>:<port>/scalemgmt/v2/filesystems/fileSystemName/disks/diskName
where
filesystems/filesystemName
The file system to which the disks belong. Required.
disks/diskName
The disk about which you want to get information. Required.

Request headers

Accept: application/json

Parameters

The following parameters can be used in the request URL to customize the request:
Table 1. List of parameters
Parameter name Description and applicable keywords Required/optional
filesystemName The file system name. You can also use keywords such as :all:, :all_local:, or :all_remote: Required.
fields Comma separated list of fields to be included in response. ':all:' selects all available fields. Optional.
diskName The name of the disk. Required.

Request data

No request data.

Response data

{
    "status": {
      "code":ReturnCode",
      "message":"ReturnMessage"
   },
 "paging": 
  {
    "next": "URL"
  },
   disks: [
      {
         "name":"DiskName",
         "filesystem":"FileSystemName",       
         "failureGroup":"FailureGroupID",
         "type":"{dataOnly | metadataOnly | dataAndMetadata | descOnly | localCache}",
         "storagePool":"StoragePool",
         "status":"Status",
         "availability":"Availability",
         "quorumdisk":"QuorumDisk",
         "remarks":"Remarks",
         "size":"Size",
         "availableBlocks":"AvailableBlocks",
         "availableFragments":"AvailableFragments"
         "nsdServers":"NSDServers",
         "nsdVolumeId":"NSDVolumeID", 
       }
   ],
   
}
For more information about the fields in the following data structures, see the links at the end of this topic.
"status":
Return status.
"message": "ReturnMessage",
The return message.
"code": ReturnCode
The return code.
"paging"
The URL to retrieve the next page. Paging is enabled when more than 1000 objects are returned by the query.
"disks":
An array of elements that describe one disk.
"name":"DiskName"
Name of the disk.
"filesystem":"FileSystemName"
The file system to which the disk belongs.
"failureGroup":"FailureGroupID"
Failure group of the disk.
"type":"{dataOnly | metadataOnly | dataAndMetadata | descOnly | localCache}"
Specifies the type of data to be stored on the disk:
dataOnly
Indicates that the disk contains data and does not contain metadata. This is the default for disks in storage pools other than the system pool.
metadataOnly
Indicates that the disk contains metadata and does not contain data.
dataAndMetadata
Indicates that the disk contains both data and metadata. This is the default for disks in the system pool.
descOnly
Indicates that the disk contains no data and no file metadata. Such a disk is used solely to keep a copy of the file system descriptor, and can be used as a third failure group in certain disaster recovery configurations. For more information, see the help topic Synchronous mirroring utilizing GPFS replication in IBM Spectrum Scale: Administration Guide.
localCache
Indicates that the disk is to be used as a local read-only cache device.
"storagePool":"StoragePool"
Storage pool to which the disk belongs.
"status":"Status"
The status of the disk.
"availability":"Availability"
The availability of the disk.
"quorumdisk":"Quorum disk"
The quorum status of the disk.
"remarks":"Remarks"
User-defined remarks about the disk.
"size":"Size"
The size of the disk.
"availableBlocks":"Available blocks"
The available blocks of the disk.
"availableFragments":"Available fragments"
The available fragments of the disk.
"nsdServers":"NSD servers"
The name of the NSD servers.
"nsdVolumeID":"NSD volume ID"
The volume ID of the NSD.

Examples

The following example gets information about the disk disk8 in the file system gpfs0.

Request data:
curl -k -u admin:admin001 -X GET --header 'accept:application/json' 
'https://198.51.100.1:443/scalemgmt/v2/filesystems/gpfs0/disks/disk8'
Response data:
Note: In the JSON data that is returned, the return code indicates whether the command is successful. The response code 200 indicates that the command successfully retrieved the information. Error code 400 represents an invalid request and 500 represents internal server error.
{
  "status": {
    "code": "200",
    "message": "..."
  },
  "paging": {
    "next": "https://198.51.100.1:443/scalemgmt/v2/filesystems/gpfs0/disks/disk8?lastId=1001"
  },
  "disks": [
    {
        "name": "disk8",
        "fileSystem": "gpfs0",
        "failureGroup": "1",
        "type": "dataOnly",
        "storagePool": "data",
        "status": "ready",
        "availability": "up",
        "quorumDisk": "no",
        "remarks": "This is a comment",
        "size": "10.00 GB",
        "availableBlocks": "730.50 MB",
        "availableFragments": "1.50 MB",
        "nsdServers": "gpfsgui-21.localnet.com",
        "nsdVolumeId": "0A0064155874F5AA"
    }
  ]
}