From: Loic Dachary Date: Wed, 1 Jan 2014 21:13:15 +0000 (+0100) Subject: ceph-disk: display the command output on OSD creation failure X-Git-Tag: v0.67.6~1^2~13 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=6ae96d3ce757b05daeb7c1437778149b07248d47;p=ceph.git ceph-disk: display the command output on OSD creation failure The string form of a CalledProcessError instance does not include the output datamember. Add it to the Error exception for debug purposes. Signed-off-by: Loic Dachary (cherry picked from commit d09af0fa50f322c9e59765f3badd497f5ca184d4) --- diff --git a/src/ceph-disk b/src/ceph-disk index 6df02ab01e4..88caf24322f 100755 --- a/src/ceph-disk +++ b/src/ceph-disk @@ -547,7 +547,7 @@ def allocate_osd_id( ], ) except subprocess.CalledProcessError as e: - raise Error('ceph osd create failed', e) + raise Error('ceph osd create failed', e, e.output) osd_id = must_be_one_line(osd_id) check_osd_id(osd_id) return osd_id