Skip to main content

partition_scheme_partitions

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

Overview​

Namepartition_scheme_partitions
TypeResource
Idovh.dedicated_installation_template.partition_scheme_partitions

Fields​

The following fields are returned by SELECT queries:

successful operation

NameDatatypeDescription
volume_namestringLogical volume name (required if type is lv) or optional zpool name if filesystem is ZFS (wire: volumeName)
filesystemstringPartition filesytem (btrfs, ext3, ext4, fat16, none, ntfs, reiserfs, swap, ufs, vmfs5, vmfs6, vmfsl, xfs, zfs)
mountpointstringPartition mount point
orderintegerspecifies the creation order of the partition on the disk
raidstringPartition raid (0, 1, 10, 5, 6, 7)
sizeobjectPartition size (unit: MB GB TB, MB by default), 0 => rest of the space
typestringPartition type (logical, lv, primary)

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectmountpoint, scheme_name, template_nameGet a partition. Returns the filesystem, type, size, RAID level and creation order of a partition of the partitioning scheme. A size of 0 means the rest of the disk space.
listselectscheme_name, template_namex_pagination_modeList partitions. Returns the mount points of the partitions defined in the partitioning scheme. Each partition has a filesystem, a type, a size and a creation order on the disk.

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"}})
mountpointstringPartition mount point
scheme_namestringThis partitioning scheme name (wire: schemeName)
template_namestringThis template name (wire: templateName)
x_pagination_modestringSent as CachedObjectList-Pages by default so the list returns the full objects rather than their identifiers. (wire: X-Pagination-Mode)

SELECT examples​

Get a partition. Returns the filesystem, type, size, RAID level and creation order of a partition of the partitioning scheme. A size of 0 means the rest of the disk space.

SELECT
volume_name,
filesystem,
mountpoint,
order,
raid,
size,
type
FROM ovh.dedicated_installation_template.partition_scheme_partitions
WHERE mountpoint = '{{ mountpoint }}' -- required
AND scheme_name = '{{ scheme_name }}' -- required
AND template_name = '{{ template_name }}' -- required
;