From 6d54548e64e494f3c0fcf76aa7f85adf4848529a Mon Sep 17 00:00:00 2001 From: Guido Trotter <ultrotter@google.com> Date: Wed, 23 Apr 2008 14:51:47 +0000 Subject: [PATCH] burnin: improve instance create message When the allocator or a non-mirrored template are used the message shown by burnin at instance creation time was wrong. Fixing it. Reviewed-by: iustinp --- tools/burnin | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tools/burnin b/tools/burnin index 63ffb2e84..2793f3cf0 100755 --- a/tools/burnin +++ b/tools/burnin @@ -207,6 +207,14 @@ class Burner(object): for pnode, snode, instance in mytor: if self.opts.iallocator: pnode = snode = None + Log("- Add instance %s (iallocator: %s)" % + (instance, self.opts.iallocator)) + elif self.opts.disk_template not in constants.DTS_NET_MIRROR: + snode = None + Log("- Add instance %s on node %s" % (instance, pnode)) + else: + Log("- Add instance %s on nodes %s/%s" % (instance, pnode, snode)) + op = opcodes.OpCreateInstance(instance_name=instance, mem_size=128, disk_size=self.opts.os_size, @@ -227,7 +235,6 @@ class Burner(object): file_driver="loop", file_storage_dir=None, iallocator=self.opts.iallocator) - Log("- Add instance %s on nodes %s/%s" % (instance, pnode, snode)) self.ExecOp(op) self.to_rem.append(instance) -- GitLab