Microsoft Virtualization Discussions
Microsoft Virtualization Discussions
Hello,
Can we look into removing the "/vol" requirement for any and all cDOT powershell tools please? As "/vol" is no longer required and in fact requires extra steps to create and keep in mind for mounting volumes into that junction path, this requirement needs to be removed for those customers not using "/vol" in their cDOT environments.
Set-NcQuota -Volume cscott_quota_test -Policy default -VserverContext svm_test -Type tree -target /cscott_quota_test/qtree1
Set-NcQuota : Invalid target /cscott_quota_test/qtree1 specified for tree quota rule. Target for explicit tree quota rule for volume cscott_quota_test must be in "/vol/cscott_quota_test/<qtree-name>" format.
At line:1 char:1
+ Set-NcQuota -Volume cscott_quota_test -Policy default -VserverContext svm_test ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (cdtusalph81:NcController) [Set-NcQuota], EQUOTAINVALID
+ FullyQualifiedErrorId : ApiException,DataONTAP.C.PowerShell.SDK.Cmdlets.Quota.SetNcQuota
Set-NcQuota -Volume cscott_quota_test -Policy default -VserverContext svm_test -Type tree -target /vol/cscott_quota_test/qtree1
Set-NcQuota : Object reference not set to an instance of an object.
At line:1 char:1
+ Set-NcQuota -Volume cscott_quota_test -Policy default -VserverContext svm_test ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (cdtusalph81:NcController) [Set-NcQuota], NullReferenceException
+ FullyQualifiedErrorId : QuotaGetEntryFailed,DataONTAP.C.PowerShell.SDK.Cmdlets.Quota.SetNcQuota
Solved! See The Solution
Hello @cscott,
One potential workaround would be to use the pipeline...
Get-NcVol $volumeName | Get-NcQuota -Type user | Set-NcQuota -DiskLimit 10gb
Hope that helps.
Andrew
Hello @cscott,
One potential workaround would be to use the pipeline...
Get-NcVol $volumeName | Get-NcQuota -Type user | Set-NcQuota -DiskLimit 10gb
Hope that helps.
Andrew
My apologies for the late reply, other priorities pushed this out. I have tested it successfully, thank you from myself and my customer!
- Scott