On Fri, Sep 12, 2014 at 10:52:19AM +0200, Giuseppe Scrivano wrote: > Some OS entries in libosinfo miss the "recommended" resources block. > In this case use the "minimum" resources when available. > > Signed-off-by: Giuseppe Scrivano <gscrivan@xxxxxxxxxx> > --- > virtinst/osdict.py | 5 +++++ > 1 file changed, 5 insertions(+) > > diff --git a/virtinst/osdict.py b/virtinst/osdict.py > index 9e48270..88010ad 100644 > --- a/virtinst/osdict.py > +++ b/virtinst/osdict.py > @@ -446,6 +446,11 @@ class _OsVariant(_OsVariantType): > ret["storage"] = r.get_storage() > break > > + # libosinfo may miss the recommended resources block for some OS, > + # in this case read first the minimum resources (if present) > + # and use them. > + read_resource(self._os.get_minimum_resources(), "all") > + read_resource(self._os.get_minimum_resources(), arch) Maybe better to scale these minimum resources by X% to try to have something which is not too constrained? Christophe
Attachment:
pgpsZtOnmfy0H.pgp
Description: PGP signature
_______________________________________________ virt-tools-list mailing list virt-tools-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/virt-tools-list