summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2015-07-27 13:24:22 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-07-27 23:29:15 +0100
commite3aa7a30b3ecf6d82c049cbfa92834155235883d (patch)
treef57de972fbf6453f03544a7f4c7a229f014358ec /meta
parentedc7780ab749534176780a247ab36d4a1575bc30 (diff)
downloadpoky-e3aa7a30b3ecf6d82c049cbfa92834155235883d.tar.gz
targetcontrol: Improve logs by outputting qemu boot log in case of failure
We've had a few cases on the autobuilder where we've lost logs of the boot and been unable to debug it further. Show this information onto the console to be more useful. (From OE-Core rev: 5302b7b8fa1349ae99040fe8fdcc4e42c722cc10) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/lib/oeqa/targetcontrol.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/meta/lib/oeqa/targetcontrol.py b/meta/lib/oeqa/targetcontrol.py
index 138e61786b..c76887bae1 100644
--- a/meta/lib/oeqa/targetcontrol.py
+++ b/meta/lib/oeqa/targetcontrol.py
@@ -175,6 +175,9 @@ class QemuTarget(BaseTarget):
175 self.connection = SSHControl(ip=self.ip, logfile=self.sshlog) 175 self.connection = SSHControl(ip=self.ip, logfile=self.sshlog)
176 else: 176 else:
177 self.stop() 177 self.stop()
178 if os.path.exists(self.qemulog):
179 with open(self.qemulog, 'r') as f:
180 bb.error("Qemu log output from %s:\n%s" % (self.qemulog, f.read()))
178 raise bb.build.FuncFailed("%s - FAILED to start qemu - check the task log and the boot log" % self.pn) 181 raise bb.build.FuncFailed("%s - FAILED to start qemu - check the task log and the boot log" % self.pn)
179 182
180 def stop(self): 183 def stop(self):