On Tue, Sep 20, 2016 at 2:00 PM, Staniforth, Paul <P.Staniforth@leedsbeckett.ac.uk> wrote:
Thanks Andrej,
                                it gives me another reason to learn python. I will try but things are a little hectic at the moment as it's induction week at our University.

Paul. you can also use Java or Ruby instead of Python.
 

Regards,
         Paul S.
________________________________________
From: Andrej Krejcir <akrejcir@redhat.com>
Sent: 20 September 2016 10:44
To: Staniforth, Paul
Cc: users@ovirt.org
Subject: Re: [ovirt-users] quota creation from ovirt-shell

Hi,

there is a bug in the ovirt-cli, which makes creating quotaclusterlimit and quotastoragelimit impossible.

The correct syntax would be:
add quotastoragelimit --parent-datacenter-name Default --parent-quota-name testcli ...

You could use a python script with the SDK instead.
For example:


from ovirtsdk.api import API
from ovirtsdk.xml.params import Quota
from ovirtsdk.xml.params import QuotaStorageLimit

api = API('IP:PORT/ovirt-engine/api', 'admin@internal', 'pass')
dc = api.datacenters.list()[0]
quota = dc.quotas.add(Quota(name="quota1"))
quota.quotastoragelimits.add(QuotaStorageLimit(limit=100))



Regards,
Andrej

----- Original Message -----
From: "Paul Staniforth" <P.Staniforth@leedsbeckett.ac.uk>
To: users@ovirt.org
Sent: Monday, September 12, 2016 6:00:50 PM
Subject: [ovirt-users] quota creation from ovirt-shell



Hello,

I am trying to create user quotas from the command line via the shell.




I am using ovirt 3.6.7 and the command




add quota --parent-datacenter-name Default --name testcli




creates a quota but without quotaclusterlimit or quotastoragelimit




I can't find the correct syntax to create these.




Also how would I add a consumer and change the values when created?




Any examples or pointers to documentation would be appreciated.




Thanks,

Paul S.
To view the terms under which this email is distributed, please go to:-
http://disclaimer.leedsbeckett.ac.uk/disclaimer/disclaimer.html



_______________________________________________
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users
To view the terms under which this email is distributed, please go to:-
http://disclaimer.leedsbeckett.ac.uk/disclaimer/disclaimer.html
_______________________________________________
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users