Storage pools endpoint overview
- PDF of this doc site
Collection of separate PDF docs
Creating your file...
Retrieving storage pool information
The Storage Pools GET API retrieves all shared storage pools in the cluster.
The collection GET returns the storage pool identifiers, UUID and name. The instance GET, by default, returns all of the properties defined in the storage_pool object.
Creating storage pools
Creating a shared storage pool is recommended when distributing flash capacity across the cache tiers of HDD aggregates across an HA pair. POST can be used with specific properties to create a storage pool as requested. At a minimum, the storage pool name, disk count, and the nodes where it should reside, are required to create a new instance.
When using POST with input properties, three properties are required. These are:
-
name - Name of the storage pool.
-
node.name or node.uuid - Node that can use capacity from the storage pool in their cache tiers.
-
capacity.disk_count - Number of disks to be used to create the storage pool.
Examples
Retrieving a list of storage pools from the cluster
The following example shows the response with a list of storage pools in the cluster:
{ "records": [ { "uuid": "8255fef7-4737-11ec-bd1b-005056bbb879", "nodes": [ { "uuid": "caf95bec-f801-11e8-8af9-005056bbe5c1", "name": "node-1", }, { "uuid": "cf9ab500-ff3e-4bce-bfd7-d679e6078f47", "name": "node-2", } ], "_links": { "self": { "href": "/api/storage/pools/8255fef7-4737-11ec-bd1b-005056bbb879" } } } ], "num_records": 1, "_links": { "self": { "href": "/api/storage/pools" } } }
# The API: /api/storage/pools # The call: curl -X GET "https://<mgmt-ip>/api/storage/pools?fields=*" -H "accept: application/json" # The response: { "records": [ { "uuid": "8255fef7-4737-11ec-bd1b-005056bbb879", "name": "new_sp", "nodes": [ { "uuid": "caf95bec-f801-11e8-8af9-005056bbe5c1", "name": "node-1", }, { "uuid": "cf9ab500-ff3e-4bce-bfd7-d679e6078f47", "name": "node-2", } ], "storage_type": "ssd", "capacity": { "remaining": 1846542336, "total": 7386169344, "spare_allocation_units": [ { "node": { "uuid": "caf95bec-f801-11e8-8af9-005056bbe5c1", "name": "node-1", }, "count": 1, "syncmirror_pool": "pool0", "size": 1846542336, "available_size": 1846542336 }, { "node": { "uuid": "cf9ab500-ff3e-4bce-bfd7-d679e6078f47", "name": "node-2", }, "count": 0, "syncmirror_pool": "pool0", "size": 1846542336, "available_size": 0 } ], "used_allocation_units": [ { "aggregate": { "uuid": "19425837-f2fa-4a9f-8f01-712f626c983c", "name": "test_a" }, "allocated_unit_count": 2, "node": { "uuid": "caf95bec-f801-11e8-8af9-005056bbe5c1", "name": "node-1", }, "capacity": 2769813504 }, { "aggregate": { "uuid": "f4cc30d5-b052-493a-a49f-19781425f987", "name": "test_b" }, "allocated_unit_count": 1, "node": { "uuid": "cf9ab500-ff3e-4bce-bfd7-d679e6078f47", "name": "node-2", }, "capacity": 1384906752 } ], "disk_count": 4, "disks": [ { "disk": { "name": "VMw-1.11" }, "usable_size": 1902379008, "total_size": 1908871168, }, { "disk": { "name": "VMw-1.12" }, "usable_size": 1902379008, "total_size": 1908871168, }, { "disk": { "name": "VMw-1.23" }, "usable_size": 1902379008, "total_size": 1908871168, }, { "disk": { "name": "VMw-1.24" }, "usable_size": 1902379008, "total_size": 1908871168, } ] }, "health": { "state": "normal", "is_healthy": true }, } ], "num_records": 1, }
Simulating the creation of a storage pool
The following example shows the response containing the simulated layout details of a new storage pool in the cluster.
Each storage pool UUID provided in this response is not guaranteed to be the same UUID for the storage pool if it is created. |
# The API: /api/storage/pools # The call: curl -X POST "https://<mgmt-ip>/api/storage/pools?simulate=true&fields=*" -d "{\"nodes\": [{\"name\": \"node1\"}, {\"name\": \"node2\"}], \"name\": \"storage_pool_1\", \"capacity\": {\"disk_count\": \"4\"}}" -H "accept: application/json" # The response: { "records": [ { "uuid": "cae60cfe-deae-42bd-babb-ef437d118314", "name": "new_sp", "nodes": [ { "uuid": "caf95bec-f801-11e8-8af9-005056bbe5c1", "name": "node-1", }, { "uuid": "cf9ab500-ff3e-4bce-bfd7-d679e6078f47", "name": "node-2", } ], "storage_type": "ssd", "capacity": { "total": 7386169344, "disk_count": 4, "disks": [ { "disk": { "name": "VMw-1.11" }, }, { "disk": { "name": "VMw-1.12" }, }, { "disk": { "name": "VMw-1.23" }, }, { "disk": { "name": "VMw-1.24" }, } ] } } ] }