Software Development Kit (SDK) and API Discussions

Creating a new quota entry

jivam

Getting the error when creating a new quota entry when using the NetApp sdk

 

below are the input parameters

<?xml version="1.0" encoding="UTF-8"?>
<netapp vfiler="vservername" xmlns="http://www.netapp.com/filer/admin" version="1.150">
<quota-add-entry>
<disk-limit>40000</disk-limit>
<qtree>""</qtree>
<quota-target>/vol/volname/qtre3name</quota-target>
<quota-type>tree</quota-type>
<volume>volname</volume>
</quota-add-entry>
</netapp>

 

Below is the error

 

<!-- Output of quota-add-entry [Execution Time: 327 ms] -->
<results reason='Qtree cannot be specified for a tree type rule. ' errno='13051' status='failed'/>

 

The API documentation states to use "" for the qtree when using type tree

 

Is this a bug in the API execution

 

or am I missing something?

 

Thanks

 

 

1 REPLY 1

donny_lang

Try using a null value for the "qtree" input. This API call worked in my lab environment to set the quota:

<?xml version="1.0" encoding="UTF-8"?>
<netapp vfiler="lab-svm-01" xmlns="http://www.netapp.com/filer/admin" version="1.150">
<quota-add-entry>
<disk-limit>40000</disk-limit>
<qtree></qtree>
<quota-target>/vol/qtreetest/test1</quota-target>
<quota-type>tree</quota-type>
<volume>qtreetest</volume>
</quota-add-entry>
</netapp>

 

lab-clst01::> volume quota policy rule show

Vserver: lab-svm-01        Policy: default           Volume: qtreetest

                                               Soft             Soft
                         User         Disk     Disk   Files    Files
Type   Target    Qtree   Mapping     Limit    Limit   Limit    Limit  Threshold
-----  --------  ------- -------  --------  -------  ------  -------  ---------
tree   test1     ""      -         39.06MB        -       -        -          -
Announcements
NetApp on Discord Image

We're on Discord, are you?

Live Chat, Watch Parties, and More!

Explore Banner

Meet Explore, NetApp’s digital sales platform

Engage digitally throughout the sales process, from product discovery to configuration, and handle all your post-purchase needs.

NetApp Insights to Action
I2A Banner
Public