When using module netapp.ontap.na_ontap_quotas with the intent to for example modify the disk limit for a specific qtree, the default limit gets overwritten with that parameter too. use_rest: never provides the correct result.
Our env is a bare metal Ansible Tower on RHEL 8.5/8.6.
It quota_target is supplied, the playbook should not change the default target for that qtree. Via Zapi, it shows the correct behavior, via REST it doesnt.
Thanks.
Actual Results
Report before the playbook:
n98509001::> quota policy rule show -vserver *2
Vserver: nv985080002 Policy: default Volume: f12345
Soft Soft
User Disk Disk Files Files
Type Target Qtree Mapping Limit Limit Limit Limit Threshold
----- -------- ------- ------- -------- ------- ------ ------- ---------
tree "" "" - - - - - -
tree t123456 "" - 30GB - - - -
tree t654321 "" - 0B - - - -
3 entries were displayed.
After the playbook ran:
n98509001::> quota policy rule show -vserver *2
Vserver: nv985080002 Policy: default Volume: f12345
Soft Soft
User Disk Disk Files Files
Type Target Qtree Mapping Limit Limit Limit Limit Threshold
----- -------- ------- ------- -------- ------- ------ ------- ---------
tree "" "" - 30GB - - - -
tree t123456 "" - 30GB - - - -
tree t654321 "" - 30GB - - - -
3 entries were displayed.
Summary
When using module netapp.ontap.na_ontap_quotas with the intent to for example modify the disk limit for a specific qtree, the default limit gets overwritten with that parameter too. use_rest: never provides the correct result.
Our env is a bare metal Ansible Tower on RHEL 8.5/8.6.
Component Name
netapp.ontap.na_ontap_quotas
Ansible Version
ONTAP Collection Version
Python Env:
ONTAP Version
Playbook
Steps to Reproduce
create random svm, here: nv985080002 vol create -vserver nv985080002 -volume f12345 -size 50G qtree create -vserver nv985080002 -volume f12345 -qtree t654321 -security-style unix -unix-permissions 2775
Depending on use_rest: auto|never, the default rule will be modified too.
Change parameters for netapp.ontap.na_ontap_quotas: { "changed": true, "invocation": { "module_args": { "hostname": "172.30.224.130", "username": "admin", "password": "VALUE_SPECIFIED_IN_NO_LOG_PARAMETER", "https": true, "validate_certs": false, "state": "present", "activate_quota_on_change": "resize", "disk_limit": "23068672KB", "qtree": "", "quota_target": "/vol/f12345/t654321", "type": "tree", "volume": "f12345", "vserver": "nv985080002", "set_quota_status": true, "use_rest": "auto", "feature_flags": {}, "http_port": null, "ontapi": null, "cert_filepath": null, "key_filepath": null, "force_ontap_version": null, "policy": null, "perform_user_mapping": null, "file_limit": null, "soft_file_limit": null, "soft_disk_limit": null, "threshold": null } }, "_ansible_no_log": false }
Expected Results
It quota_target is supplied, the playbook should not change the default target for that qtree. Via Zapi, it shows the correct behavior, via REST it doesnt.
Thanks.
Actual Results