We've been seeing transient errors with any test that uses a dm device for the entirety of the time that we've been running nightly xfstests runs. This turns out to be because sometimes we get EBUSY while trying to create our new dm device. Generally this is because the test comes right after another test that messes with the dm device, and thus we still have udev messing around with the device when DM tries to O_EXCL the block device. Add a UDEV_SETTLE_PROG before creating the device to make sure we can create our new dm device without getting this transient error. Signed-off-by: Josef Bacik <josef@xxxxxxxxxxxxxx> --- common/rc | 1 + 1 file changed, 1 insertion(+) diff --git a/common/rc b/common/rc index 8e351f17..35e861ec 100644 --- a/common/rc +++ b/common/rc @@ -4567,6 +4567,7 @@ _dmsetup_remove() _dmsetup_create() { + $UDEV_SETTLE_PROG >/dev/null 2>&1 $DMSETUP_PROG create "$@" >>$seqres.full 2>&1 || return 1 $DMSETUP_PROG mknodes >/dev/null 2>&1 $UDEV_SETTLE_PROG >/dev/null 2>&1 -- 2.26.3