Skip to main content

datacenters

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

Overview​

Namedatacenters
TypeResource
Idovh.dedicated_cloud.datacenters

Fields​

The following fields are returned by SELECT queries:

successful operation

NameDatatypeDescription
namestring
datacenter_idintegerId of the Datacenter (wire: datacenterId)
commercial_namestringThe commercial name of this Datacenter (CDI, CDI-HDS, CDI-HIPAA, CDI-NSX, CDI-NSX-T, CDI-NSX-VROPS, CDI-PCIDSS, CDI-UNKNOWN, CDI-VROPS, DC, DC-ANCIENT, DC-ANCIENT-HDS, DC-ANCIENT-HIPAA, DC-ANCIENT-NSX, DC-ANCIENT-NSX-T, DC-ANCIENT-NSX-VROPS, DC-ANCIENT-PCIDSS, DC-ANCIENT-UNKNOWN, DC-ANCIENT-VROPS, DC-HDS, DC-HIPAA, DC-LEGACY, DC-LEGACY-HDS, DC-LEGACY-HIPAA, DC-LEGACY-NSX, DC-LEGACY-NSX-T, DC-LEGACY-NSX-VROPS, DC-LEGACY-PCIDSS, DC-LEGACY-UNKNOWN, DC-LEGACY-VROPS, DC-NSX, DC-NSX-T, DC-NSX-VROPS, DC-PCIDSS, DC-UNKNOWN, DC-VROPS, ESSENTIALS, ESSENTIALS-HDS, ESSENTIALS-HIPAA, ESSENTIALS-NSX, ESSENTIALS-NSX-T, ESSENTIALS-NSX-VROPS, ESSENTIALS-PCIDSS, ESSENTIALS-UNKNOWN, ESSENTIALS-VROPS, NSX-T, NSX-T-DEFAULT, NSX-T-HDS, NSX-T-NSX, NSX-T-NSX-VROPS, NSX-T-PCIDSS, NSX-T-VROPS, NSX-T-VROPS-WITHOUT-NSX, NSX-T-WITHOUT-NSX, PREMIER, PREMIER-DEFAULT, PREMIER-HDS, PREMIER-HIPAA, PREMIER-NSX, PREMIER-NSX-T, PREMIER-NSX-VROPS, PREMIER-PCIDSS, PREMIER-UNKNOWN, PREMIER-VROPS, SDDC, SDDC-DEFAULT, SDDC-HDS, SDDC-HIPAA, SDDC-LEGACY, SDDC-LEGACY-HDS, SDDC-LEGACY-HIPAA, SDDC-LEGACY-PCIDSS, SDDC-LEGACY-UNKNOWN, SDDC-LEGACY-VROPS, SDDC-LEGACY-VROPS-WITHOUT-NSX, SDDC-LEGACY-WITHOUT-NSX, SDDC-PCIDSS, SDDC-UNKNOWN, SDDC-VROPS, SDDC-VROPS-WITHOUT-NSX, SDDC-WITHOUT-NSX, UNKNOWN, UNKNOWN-HDS, UNKNOWN-HIPAA, UNKNOWN-NSX, UNKNOWN-NSX-T, UNKNOWN-NSX-VROPS, UNKNOWN-PCIDSS, UNKNOWN-UNKNOWN, UNKNOWN-VROPS, UNKNOWN-VSPHERE, VSPHERE, VSPHERE-DEFAULT, VSPHERE-HDS, VSPHERE-NSX, VSPHERE-NSX-VROPS, VSPHERE-PCIDSS, VSPHERE-VROPS, VSPHERE-VROPS-WITHOUT-NSX, VSPHERE-WITHOUT-NSX) (wire: commercialName)
commercial_range_namestringThe commercial range associated to this Datacenter (wire: commercialRangeName)
horizon_view_namestringName of the associated Horizon View service if the VDI option is enabled (wire: horizonViewName)
descriptionstring
has_mixed_host_profilesbooleanCheck if this datacenter has different host profiles (wire: hasMixedHostProfiles)
has_mixed_vsan_host_profilesbooleanCheck if this datacenter has different VSAN host profiles (wire: hasMixedVsanHostProfiles)
is_removablebooleanCheck if this datacenter is removable (Need to be Empty) (wire: isRemovable)
versionstringOs version installed on your VMware on OVHcloud

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectdatacenter_id, service_nameGet a datacenter. Returns the datacenter: name, commercial range, version and whether it can be removed.
listselectservice_namex_pagination_modeList datacenters
createinsertservice_name, commercial_range_nameCreate a datacenter. Creates a datacenter in a commercial range, optionally linked to a vRack. Returns a task to track progress.
updateupdatedatacenter_id, service_nameUpdate a datacenter. Updates the name and description of the datacenter. Returns a task to track progress.
deletedeletedatacenter_id, service_nameDelete a datacenter. Deletes the datacenter. The datacenter must be empty: check isRemovable first. Returns a task to track progress.
check_backup_jobsexecdatacenterId, serviceNameCheck backup jobs. Checks that the backup jobs of the datacenter are set correctly after virtual machines moved to another datacenter. Returns a task to track progress.
disaster_recovery_zerto_disableexecdatacenterId, serviceName, secondaryDatacenterId, secondaryServiceNameDisable Zerto disaster recovery between two VMware on OVHcloud infrastructures
disaster_recovery_zerto_end_migrationexecdatacenterId, serviceNameUnlink migration source virtual datacenter from Zerto disaster recovery
disaster_recovery_zerto_endpoint_public_ipexecdatacenterId, serviceName, newEndpointPublicIpChange the IP address used by Zerto disaster recovery endpoint for public network access
disaster_recovery_zerto_request_health_checkexecdatacenterId, serviceNameRun Zerto disaster recovery health check task
disaster_recovery_zerto_start_migrationexecdatacenterId, serviceNameLink migration target virtual datacenter to Zerto disaster recovery
disaster_recovery_zerto_single_disableexecdatacenterId, serviceNameDisable Zerto disaster recovery between VMware on OVHcloud infrastructure and onsite infrastructure
disaster_recovery_zerto_single_endpoint_public_ipexecdatacenterId, serviceName, newEndpointPublicIpChange the IP address used by Zerto disaster recovery endpoint for public network access
disaster_recovery_zerto_single_request_pairing_tokenexecdatacenterId, serviceNameRequest Zerto disaster recovery pairing token for onsite infrastructure
order_new_filer_hourlyexecdatacenterId, serviceName, nameOrder an hourly datastore. Orders a datastore billed by the hour with the given profile. Returns a task to track progress.
order_new_host_hourlyexecdatacenterId, serviceName, nameOrder an hourly host. Orders a host billed by the hour with the given host profile, optionally in a given cluster. Returns a task to track progress.
resize_nsxt_edge_clusterexecdatacenterId, serviceName, sizeResize the edge nodes. Changes the size of the edge nodes of the datacenter: MEDIUM, LARGE or XLARGE. Returns a task to track progress.

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"}})
datacenterIdintegerId of the Datacenter
datacenter_idintegerId of the Datacenter (wire: datacenterId)
serviceNamestringDomain of the service
service_namestringDomain of the service (wire: serviceName)
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 datacenter. Returns the datacenter: name, commercial range, version and whether it can be removed.

SELECT
name,
datacenter_id,
commercial_name,
commercial_range_name,
horizon_view_name,
description,
has_mixed_host_profiles,
has_mixed_vsan_host_profiles,
is_removable,
version
FROM ovh.dedicated_cloud.datacenters
WHERE datacenter_id = '{{ datacenter_id }}' -- required
AND service_name = '{{ service_name }}' -- required
;

INSERT examples​

Create a datacenter. Creates a datacenter in a commercial range, optionally linked to a vRack. Returns a task to track progress.

INSERT INTO ovh.dedicated_cloud.datacenters (
commercial_range_name,
vrack_name,
service_name
)
SELECT
'{{ commercial_range_name }}' /* required */,
'{{ vrack_name }}',
'{{ service_name }}'
RETURNING
name,
datacenter_id,
filer_id,
host_id,
network_access_id,
order_id,
parent_task_id,
task_id,
user_id,
vlan_id,
created_by,
created_from,
description,
end_date,
execution_date,
last_modification_date,
maintenance_date_from,
maintenance_date_to,
network,
progress,
state,
type
;

UPDATE examples​

Update a datacenter. Updates the name and description of the datacenter. Returns a task to track progress.

UPDATE ovh.dedicated_cloud.datacenters
SET
description = '{{ description }}',
name = '{{ name }}'
WHERE
datacenter_id = '{{ datacenter_id }}' --required
AND service_name = '{{ service_name }}' --required
RETURNING
name,
datacenter_id,
filer_id,
host_id,
network_access_id,
order_id,
parent_task_id,
task_id,
user_id,
vlan_id,
created_by,
created_from,
description,
end_date,
execution_date,
last_modification_date,
maintenance_date_from,
maintenance_date_to,
network,
progress,
state,
type;

DELETE examples​

Delete a datacenter. Deletes the datacenter. The datacenter must be empty: check isRemovable first. Returns a task to track progress.

DELETE FROM ovh.dedicated_cloud.datacenters
WHERE datacenter_id = '{{ datacenter_id }}' --required
AND service_name = '{{ service_name }}' --required
;

Lifecycle Methods​

EXEC variables use wire (API) names.

Check backup jobs. Checks that the backup jobs of the datacenter are set correctly after virtual machines moved to another datacenter. Returns a task to track progress.

EXEC ovh.dedicated_cloud.datacenters.check_backup_jobs
@datacenterId='{{ datacenterId }}' --required,
@serviceName='{{ serviceName }}' --required
;