Skip to main content

elastic_volumes

Creates, updates, deletes, gets or lists an elastic_volumes resource.

Overview

Nameelastic_volumes
TypeResource
Idazure.netapp.elastic_volumes

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringFully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}.
namestringThe name of the resource.
availabilityStatusstringCurrent availability status of the resource. Known values are: "Online" and "Offline". (Online, Offline)
backupResourceIdstringResource identifier used to identify the Elastic Backup.
dataProtectionobjectData protection configuration option for the volume, including snapshot policies and backup.
eTagstringIf eTag is provided in the response body, it may also be provided as a header per the normal etag convention. Entity tags are used for comparing two or more entities from the same requested resource. HTTP/1.1 uses entity tags in the etag (section 14.19), If-Match (section 14.24), If-None-Match (section 14.26), and If-Range (section 14.27) header fields.
exportPolicyobjectSet of export policy rules.
filePathstringA unique file path for the volume. Used when creating mount targets. This needs to be unique within the elastic capacity pool. Required.
locationstringThe geo-location where the resource lives. Required.
mountTargetsarrayList of mount targets that can be used to mount this volume.
protocolTypesarraySet of support protocol types for the elastic volume. Required.
provisioningStatestringAzure lifecycle management. Known values are: "Accepted", "Creating", "Patching", "Updating", "Deleting", "Moving", "Failed", and "Succeeded". (Accepted, Creating, Patching, Updating, Deleting, Moving, Failed, Succeeded)
restorationStatestringThe current state of the restoration process. Known values are: "Restoring", "Restored", and "Failed". (Restoring, Restored, Failed)
sizeintegerMaximum size allowed for a volume in bytes. Valid values are in the range 1GiB to 16TiB. Values expressed in bytes as multiples of 1 GiB. Required.
smbPropertiesobjectSMB Properties.
snapshotDirectoryVisibilitystringControls the visibility of the volume's read-only snapshot directory, which provides access to each of the volume's snapshots. Known values are: "Hidden" and "Visible". (Hidden, Visible)
snapshotResourceIdstringResource identifier used to identify the Elastic Snapshot.
systemDataobjectAzure Resource Manager metadata containing createdBy and modifiedBy information.
tagsobjectResource tags.
typestringThe type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts".
zonesarrayThe availability zones.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresource_group_name, account_name, pool_name, volume_name, subscription_idGet the details of the specified volume.
list_by_elastic_poolselectresource_group_name, account_name, pool_name, subscription_idList all Elastic Volumes within the Elastic Capacity Pool.
create_or_updateinsertresource_group_name, account_name, pool_name, volume_name, subscription_id, locationCreate or update the specified volume within the capacity pool.
updateupdateresource_group_name, account_name, pool_name, volume_name, subscription_idPatch the specified elastic volume.
create_or_updatereplaceresource_group_name, account_name, pool_name, volume_name, subscription_id, locationCreate or update the specified volume within the capacity pool.
deletedeleteresource_group_name, account_name, pool_name, volume_name, subscription_idDelete the specified Elastic Volume.
revertexecresource_group_name, account_name, pool_name, volume_name, subscription_idRevert an Elastic Volume to the snapshot specified in the body.

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
account_namestringThe name of the ElasticAccount. Required.
pool_namestringThe name of the ElasticCapacityPool. Required.
resource_group_namestringThe name of the resource group. The name is case insensitive. Required.
subscription_idstring
volume_namestringThe name of the ElasticVolume. Required.

SELECT examples

Get the details of the specified volume.

SELECT
id,
name,
availabilityStatus,
backupResourceId,
dataProtection,
eTag,
exportPolicy,
filePath,
location,
mountTargets,
protocolTypes,
provisioningState,
restorationState,
size,
smbProperties,
snapshotDirectoryVisibility,
snapshotResourceId,
systemData,
tags,
type,
zones
FROM azure.netapp.elastic_volumes
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND account_name = '{{ account_name }}' -- required
AND pool_name = '{{ pool_name }}' -- required
AND volume_name = '{{ volume_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;

INSERT examples

Create or update the specified volume within the capacity pool.

INSERT INTO azure.netapp.elastic_volumes (
tags,
location,
properties,
zones,
resource_group_name,
account_name,
pool_name,
volume_name,
subscription_id
)
SELECT
'{{ tags }}',
'{{ location }}' /* required */,
'{{ properties }}',
'{{ zones }}',
'{{ resource_group_name }}',
'{{ account_name }}',
'{{ pool_name }}',
'{{ volume_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
eTag,
location,
properties,
systemData,
tags,
type,
zones
;

UPDATE examples

Patch the specified elastic volume.

UPDATE azure.netapp.elastic_volumes
SET
tags = '{{ tags }}',
properties = '{{ properties }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND account_name = '{{ account_name }}' --required
AND pool_name = '{{ pool_name }}' --required
AND volume_name = '{{ volume_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
eTag,
location,
properties,
systemData,
tags,
type,
zones;

REPLACE examples

Create or update the specified volume within the capacity pool.

REPLACE azure.netapp.elastic_volumes
SET
tags = '{{ tags }}',
location = '{{ location }}',
properties = '{{ properties }}',
zones = '{{ zones }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND account_name = '{{ account_name }}' --required
AND pool_name = '{{ pool_name }}' --required
AND volume_name = '{{ volume_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
AND location = '{{ location }}' --required
RETURNING
id,
name,
eTag,
location,
properties,
systemData,
tags,
type,
zones;

DELETE examples

Delete the specified Elastic Volume.

DELETE FROM azure.netapp.elastic_volumes
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND account_name = '{{ account_name }}' --required
AND pool_name = '{{ pool_name }}' --required
AND volume_name = '{{ volume_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;

Lifecycle Methods

Revert an Elastic Volume to the snapshot specified in the body.

EXEC azure.netapp.elastic_volumes.revert 
@resource_group_name='{{ resource_group_name }}' --required,
@account_name='{{ account_name }}' --required,
@pool_name='{{ pool_name }}' --required,
@volume_name='{{ volume_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"snapshotResourceId": "{{ snapshotResourceId }}"
}'
;