Skip to main content

volume_groups

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

Overview

Namevolume_groups
TypeResource
Idazure.netapp.volume_groups

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.
groupMetaDataobjectVolume group details.
locationstringResource location.
provisioningStatestringAzure lifecycle management.
systemDataobjectAzure Resource Manager metadata containing createdBy and modifiedBy information.
typestringThe type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts".
volumesarrayList of volumes from group.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresource_group_name, account_name, volume_group_name, subscription_idGet details of the specified volume group.
list_by_net_app_accountselectresource_group_name, account_name, subscription_idList all volume groups for given account.
createinsertresource_group_name, account_name, volume_group_name, subscription_idCreate a volume group along with specified volumes.
deletedeleteresource_group_name, account_name, volume_group_name, subscription_idDelete the specified volume group only if there are no volumes under volume group.

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 NetApp account. Required.
resource_group_namestringThe name of the resource group. The name is case insensitive. Required.
subscription_idstring
volume_group_namestringThe name of the volumeGroup. Required.

SELECT examples

Get details of the specified volume group.

SELECT
id,
name,
groupMetaData,
location,
provisioningState,
systemData,
type,
volumes
FROM azure.netapp.volume_groups
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND account_name = '{{ account_name }}' -- required
AND volume_group_name = '{{ volume_group_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;

INSERT examples

Create a volume group along with specified volumes.

INSERT INTO azure.netapp.volume_groups (
properties,
location,
resource_group_name,
account_name,
volume_group_name,
subscription_id
)
SELECT
'{{ properties }}',
'{{ location }}',
'{{ resource_group_name }}',
'{{ account_name }}',
'{{ volume_group_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
location,
properties,
systemData,
type
;

DELETE examples

Delete the specified volume group only if there are no volumes under volume group.

DELETE FROM azure.netapp.volume_groups
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND account_name = '{{ account_name }}' --required
AND volume_group_name = '{{ volume_group_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;