From: Tim Evers <it@niemail.de>
To: xen-devel@lists.xensource.com
Subject: Bug in xm config parsing code
Date: Tue, 14 Sep 2010 13:38:21 +0200 [thread overview]
Message-ID: <4C8F5EAD.90100@niemail.de> (raw)
Hi,
I think I've found a bug in xm/create.py:
http://lists.xensource.com/archives/html/xen-changelog/2009-11/msg00132.html
introduces the "maxvcpus" parameter. It states that
"this is patch to add maxvcpus support to xen xm command. It's using
vcpu_avail bitmask and sets the number of vcpus to maxvcpus if
present. If it's not present, old behavior is preserved."
The last part is untrue as far as I understand. If maxvcpus is unset,
vcpu_avail is not read at all. The patch removes it from the parameter
list given to add_conf without adding it in another place. As a result
vcpu_avail remains unset and is filled with the default value of 255 (?)
later.
This patch to fixes the issue for me:
--- create.py 2010-09-08 15:52:18.000000000 +0200
+++ create.py.af 2010-09-13 16:59:48.000000000 +0200
@@ -1120,8 +1120,10 @@
# For case we don't have maxvcpus set but we have vcpus we preserve
# old behaviour
+ # te@artfiles.de: need to read vcpu_avail here since it isn't done later.
if not maxvcpus and vcpus:
config.append(['vcpus', vcpus])
+ config.append(['vcpu_avail', getattr(vals, 'vcpu_avail'])
def add_conf(n):
if hasattr(vals, n):
I would have filed a bug report for this but I have not found Xen4 on
Xen Bugzilla. Any hints on this?
Regards
Tim Evers
Artfiles GmbH
next reply other threads:[~2010-09-14 11:38 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-09-14 11:38 Tim Evers [this message]
2010-09-16 16:26 ` Bug in xm config parsing code Ian Jackson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4C8F5EAD.90100@niemail.de \
--to=it@niemail.de \
--cc=xen-devel@lists.xensource.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.