From e31e4b49b013b2c1e2e32b985d66eb5853595981 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Han?= Date: Wed, 26 Jan 2022 15:16:22 +0100 Subject: [PATCH] core: print the stdout on errors MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit If we fail fetching the ceph version let's also print the stdout since ceph tends to put the error here too. Signed-off-by: Sébastien Han --- pkg/daemon/ceph/client/upgrade.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/daemon/ceph/client/upgrade.go b/pkg/daemon/ceph/client/upgrade.go index 17f8c5d57d7d..5d7534386f2b 100644 --- a/pkg/daemon/ceph/client/upgrade.go +++ b/pkg/daemon/ceph/client/upgrade.go @@ -46,7 +46,7 @@ func getCephMonVersionString(context *clusterd.Context, clusterInfo *ClusterInfo args := []string{"version"} buf, err := NewCephCommand(context, clusterInfo, args).Run() if err != nil { - return "", errors.Wrap(err, "failed to run 'ceph version'") + return "", errors.Wrapf(err, "failed to run 'ceph version'. %s", string(buf)) } output := string(buf) logger.Debug(output)