Skip to main content

pools

Creates, updates, deletes, gets or lists a pools resource.

Overview​

Namepools
TypeResource
Idovh.dedicated_ceph.pools

Fields​

The following fields are returned by SELECT queries:

successful operation

NameDatatypeDescription
namestringName of the pool
service_namestringID of cluster (wire: serviceName)
backupbooleanDetermine if pool should be backuped
min_active_replicasintegerMinimum active replicas (wire: minActiveReplicas)
pool_typestringType of pool (ERASURE_CODED, REPLICATED) (wire: poolType)
replica_countintegerNumber of replica (wire: replicaCount)

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectpool_name, service_nameReturns a pool of the cluster.
listselectservice_nameReturns the pools of the cluster.
createinsertservice_name, pool_nameCreates a pool whose data is replicated three times. The name must contain at least three characters.
deletedeletepool_name, service_nameDeletes the pool from the cluster.
allow_deletionexecpoolName, serviceNameOpens a 5-minute window for deleting the pool. This window is not enforced yet: a pool can currently be deleted at any time.

Parameters​

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
api_hoststringThe OVHcloud API host. Selected by OVH_ENDPOINT (ovh-eu, ovh-ca or ovh-us; default ovh-eu). (default: api.eu.ovhcloud.com, x-stackQL-envVarSelector: {"envVar":"OVH_ENDPOINT","default":"ovh-eu","values":{"ovh-eu":"api.eu.ovhcloud.com","ovh-ca":"api.ca.ovhcloud.com","ovh-us":"api.us.ovhcloud.com"}})
poolNamestringPool name
pool_namestringPool name (wire: poolName)
serviceNamestringService name
service_namestringService name (wire: serviceName)

SELECT examples​

Returns a pool of the cluster.

SELECT
name,
service_name,
backup,
min_active_replicas,
pool_type,
replica_count
FROM ovh.dedicated_ceph.pools
WHERE pool_name = '{{ pool_name }}' -- required
AND service_name = '{{ service_name }}' -- required
;

INSERT examples​

Creates a pool whose data is replicated three times. The name must contain at least three characters.

INSERT INTO ovh.dedicated_ceph.pools (
pool_name,
service_name
)
SELECT
'{{ pool_name }}' /* required */,
'{{ service_name }}'
;

DELETE examples​

Deletes the pool from the cluster.

DELETE FROM ovh.dedicated_ceph.pools
WHERE pool_name = '{{ pool_name }}' --required
AND service_name = '{{ service_name }}' --required
;

Lifecycle Methods​

EXEC variables use wire (API) names.

Opens a 5-minute window for deleting the pool. This window is not enforced yet: a pool can currently be deleted at any time.

EXEC ovh.dedicated_ceph.pools.allow_deletion
@poolName='{{ poolName }}' --required,
@serviceName='{{ serviceName }}' --required
;