From: pschwan Date: Mon, 23 Dec 2002 23:47:25 +0000 (+0000) Subject: lconf now aborts with a helpful message if the dd fails, instead of X-Git-Tag: v1_7_100~1^248~135 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=b6061f411141485c742ccefdedecf243a9ac0782;p=fs%2Flustre-release.git lconf now aborts with a helpful message if the dd fails, instead of waiting until it can't create the filesystem --- diff --git a/lustre/utils/lconf.in b/lustre/utils/lconf.in index c4cb3c8..4647c9d 100755 --- a/lustre/utils/lconf.in +++ b/lustre/utils/lconf.in @@ -588,7 +588,11 @@ def init_loop(file, size, fstype): if config.reformat() or not os.access(file, os.R_OK | os.W_OK): if size < 8000: error(file, "size must be larger than 8MB") - run("dd if=/dev/zero bs=1k count=0 seek=%d of=%s" %(size, file)) + (ret, out) = run("dd if=/dev/zero bs=1k count=0 seek=%d of=%s" %(size, + file)) + if ret: + panic("Unable to create backing store:", file) + loop = loop_base() # find next free loop for n in xrange(0, MAX_LOOP_DEVICES):