#na_ontap_quotas REST vs ZAPI

1 messages · Page 1 of 1 (latest)

teal basalt
#

On the documentation, it says:

activate_quota_on_change 
string

added in netapp.ontap 20.12.0

Method to use to activate quota on a change.

Default value is ‘resize’ in ZAPI.

With REST, Changes to quota rule limits file_limit, disk_limit, soft_file_limit, and soft_disk_limit are applied automatically without requiring a quota resize operation.

Choices:

"resize"

"reinitialize"

"none"

My question is: how do I know if it's run with REST? The REST examples in doc looks same as ZAPI. Do I need to add use_rest: always. I noticed the REST example has set_quota_status: true vs zapi examples don't have it. So with REST, we don't need activate_quota_on_change, just need set_quota_status: true, right?

- name: Modify quota reset file limit and modify disk limit.
  netapp.ontap.na_ontap_quotas:
    state: present
    vserver: ansible
    volume: ansible
    quota_target: "user1,user2"
    qtree: qtree
    type: user
    file_limit: "-"
    disk_limit: 100
    set_quota_status: true
    hostname: "{{ netapp_hostname }}"
    username: "{{ netapp_username }}"
    password: "{{ netapp_password }}"
teal basalt
#

tested with use_rest: always, however, it seems that it fails occasionally. example below:

[WARNING]: Quota policy rule create opertation succeeded. However quota resize failed due to
an internal error. To make quotas active, reinitialize(disable and enable again) the quota for
volume voltest01 in SVM test_vs02.

I am not sure if a new rule is added (user quota rule for example), does activate_quota_on_change: reinitialize is required?