From 59d298712d35cac88b12c5938b523936cdc9bbbf Mon Sep 17 00:00:00 2001 From: Peter Jones Date: Wed, 4 May 2011 10:40:05 -0400 Subject: [PATCH] Use process-specific name for dm devices. If you're doing e.g. an i386 build an an x86_64 build at the same time, you wind up deadlocking the dmsetup processes in sys_semtimedop() because they have the same name between the two codepaths. This is probbaly a dmsetup bug, but even if it weren't, you'd still have two composes trying to use the same dm devices, and that's bad. Instead, stick the pid in the names. --- src/pylorax/__init__.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/pylorax/__init__.py b/src/pylorax/__init__.py index 6e0f3c4c..5eded803 100644 --- a/src/pylorax/__init__.py +++ b/src/pylorax/__init__.py @@ -689,7 +689,8 @@ class Lorax(BaseLoraxClass): return None # create dm device - dmdev = create_dm_dev("efiboot", disksize / 512, loopdev) + tablename = "efiboot%s" % (os.getpid(),) + dmdev = create_dm_dev(tablename, disksize / 512, loopdev) if not dmdev: remove_loop_dev(loopdev)