diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-11-27 23:38:44 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-11-27 23:39:38 +0000 |
commit | 10f2c61aebecc9576d739b0f3e5fa71f1a02e3e8 (patch) | |
tree | cd65a78be7461ab6c1474b84c1ea18f14670b4fd | |
parent | 223636bd9d89919eb3019441b762b0138a8a77f0 (diff) | |
download | openembedded-core-contrib-10f2c61aebecc9576d739b0f3e5fa71f1a02e3e8.tar.gz |
oeqa/utils/commands: Add extra qemu failure logging
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/lib/oeqa/utils/commands.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/meta/lib/oeqa/utils/commands.py b/meta/lib/oeqa/utils/commands.py index 01add68689..e6a35d3d25 100644 --- a/meta/lib/oeqa/utils/commands.py +++ b/meta/lib/oeqa/utils/commands.py @@ -336,7 +336,11 @@ def runqemu(pn, ssh=True, runqemuparams='', image_fstype=None, launch_cmd=None, try: qemu.start(params=qemuparams, ssh=ssh, runqemuparams=runqemuparams, launch_cmd=launch_cmd, discard_writes=discard_writes) except bb.build.FuncFailed: - raise Exception('Failed to start QEMU - see the logs in %s' % logdir) + msg = 'Failed to start QEMU - see the logs in %s' % logdir + if os.path.exists(qemu.qemurunnerlog): + with open(qemu.qemurunnerlog, 'r') as f: + msg = msg + "Qemurunner log output from %s:\n%s" % (qemu.qemurunnerlog, f.read()) + raise Exception(msg) yield qemu |