Using quotas for FlexGroup volumes

In ONTAP 9.4 and earlier, you can apply quotas rules to FlexGroup volumes only for reporting purposes, but not for enforcing quota limits. Starting with ONTAP 9.5, you can enforce limits on quota rules that are applied to FlexGroup volumes.

About this task

Procedure

  1. Create quota rules for targets : volume quota policy rule create -vserver vs0 -policy-name quota_policy_of_the_rule -volume flexgroup_vol -type {tree|user|group} -target target_for_rule -qtree qtree_name [-disk-limit hard_disk_limit_size] [-file-limit hard_limit_number_of_files] [-threshold threshold_disk_limit_size] [-soft-disk-limit soft_disk_limit_size] [-soft-file-limit soft_limit_number_of_files]
    • In ONTAP 9.2 and ONTAP 9.1, the quota target type can be only user or group for FlexGroup volumes.

      Tree quota type is not supported for FlexGroup volumes in ONTAP 9.2 and ONTAP 9.1.

    • In ONTAP 9.3 and later, the quota target type can be user, group, or tree for FlexGroup volumes.
    • A path is not supported as the target when creating quota rules for FlexGroup volumes.
    • Starting with ONTAP 9.5, you can specify hard disk limit, hard file limit, soft disk limit, soft file limit, and threshold limit quotas for FlexGroup volumes.

      In ONTAP 9.4 and earlier, you cannot specify the disk limit, file limit, threshold for disk limit, soft disk limit, or soft file limit when you create quota rules for FlexGroup volumes.

    The following example shows a default quota rule being created for the user target type:

    cluster1::> volume quota policy rule create -vserver vs0 -policy-name quota_policy_vs0_1 -volume fg1 -type user -target "" -qtree ""

    The following example shows a tree quota rule being created for the qtree named qtree1:

    cluster1::> volume quota policy rule create -policy-name default -vserver vs0 -volume fg1 -type tree -target "qtree1"
  2. Activate the quotas for the specified FlexGroup volume: volume quota on -vserver svm_name -volume flexgroup_vol -foreground true
    cluster1::> volume quota on -vserver vs0 -volume fg1 -foreground true
  3. Monitor the state of quota initialization: volume quota show -vserver svm_name
    FlexGroup volumes might show the mixed state, which indicates that all of the constituent volumes are not in the same state yet.
    cluster1::> volume quota show -vserver vs0
                                              Scan
    Vserver    Volume        State            Status
    ---------  ------------  ---------------  ------
    vs0        fg1           initializing         95%
    vs0        vol1          off                   -
    2 entries were displayed.
  4. View the quota report for the FlexGroup volume with active quotas: volume quota report -vserver svm_name -volume flexgroup_vol
    You cannot specify a path with the volume quota report command for FlexGroup volumes.

    The following example shows the user quota for the FlexGroup volume fg1:

    cluster1::> volume quota report -vserver vs0 -volume fg1
      Vserver: vs0
                                          ----Disk----  ----Files-----   Quota
      Volume   Tree      Type    ID        Used  Limit    Used   Limit   Specifier
      -------  --------  ------  -------  -----  -----  ------  ------   ---------
      fg1                user    *           0B      -       0       -   *
      fg1                user    root       1GB      -       1       -   *
      2 entries were displayed.

    The following example shows the tree quota for the FlexGroup volume fg1:

    cluster1::> volume quota report -vserver vs0 -volume fg1
    Vserver: vs0
    
                                        ----Disk----  ----Files-----   Quota
    Volume   Tree      Type    ID        Used  Limit    Used   Limit   Specifier
    -------  --------  ------  -------  -----  -----  ------  ------   ---------
    fg1      qtree1  tree      1         68KB      -      18       -   qtree1
    fg1              tree      *           0B      -       0       -   *
    2 entries were displayed.

Result

The quota rules and limits are applied on the FlexGroups volume.

The usage might reach up to 5 percent higher than a configured hard limit before ONTAP enforces the quota by rejecting further traffic.