From 20875652d1754513b91ddaab850174e96b49d2b3 Mon Sep 17 00:00:00 2001
From: Michael Hanselmann <hansmi@google.com>
Date: Tue, 10 Jan 2012 13:38:03 +0100
Subject: [PATCH] LUInstanceCreate: Release node resource lock
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

… after running iallocator. Otherwise an assertion later in the code
would fail (for a good reason).

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
---
 lib/cmdlib.py | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/lib/cmdlib.py b/lib/cmdlib.py
index ea7dc481e..7175e187c 100644
--- a/lib/cmdlib.py
+++ b/lib/cmdlib.py
@@ -9601,6 +9601,9 @@ class LUInstanceCreate(LogicalUnit):
     _ReleaseLocks(self, locking.LEVEL_NODE,
                   keep=filter(None, [self.op.pnode, self.op.snode,
                                      self.op.src_node]))
+    _ReleaseLocks(self, locking.LEVEL_NODE_RES,
+                  keep=filter(None, [self.op.pnode, self.op.snode,
+                                     self.op.src_node]))
 
     #### node related checks
 
-- 
GitLab