-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to use LocalCifsGroupMembers #47
Comments
Thank you for reporting an issue! If you haven't already joined our Discord community, |
Hi @albinpopote, It looks like the example in the official netapp_ontap documentation page is incorrect. You need to pass the SVM uuid as well as the local_cifs_group sid. The code would then look something like this: print(list(LocalCifsGroupMembers.get_collection("<svm_uuid>", "<local_cifs_group.sid>"))) You can also refer to the official REST API documentation where the same example exists correctly using Can you please try that out and let us know if it works. Thanks! Best, |
Hello @noorbuchi, Yes It works if you pass directly the arguments (*args) to the get_collection.
Thks for your help ^^ |
Glad to hear that it works! For get_collection, netapp_ontap expects that all parent keys/path keys to be provided as *args. On the other hand, values passed as **kwargs are sent as query parameters in the REST request. I hope this clears it up. |
Hello,
I try to use the LocalCifsGroupMembers class to associate local user(s) from an SVM to a local group (cifs workgroup).
Based on the documentation: https://library.netapp.com/ecmdocs/ECMLP2885777/html/resources/local_cifs_group_members.html#overview, I try to simply get information of members on my local group "cifs_group":
When I try to request the LocalCifsGroupMembers with group SID:
print(list(LocalCifsGroupMembers.get_collection("S-1-5-21-1704451965-2597020852-3779635676-1001")))
I got the following NetAppRestError:
Could not compute the location of the LocalCifsGroupMembers collection. Values for ['svm.uuid', 'local_cifs_group.sid'] are required. Caused by AttributeError("'LocalCifsGroupMembers' object has no attribute 'svm'")
I've tried to pass the SID from user in place of the group SID, the complete local group response object, svm.uuid and local_cifs_group.sid as parameters but I got always the same error....
Environment:
netapp-ontap 9.14.1.0
NetApp Release 9.11.1P12: Fri Sep 22 11:58:50 UTC 2023
Regards ^^
The text was updated successfully, but these errors were encountered: