From: "Alex Bennée" <alex.bennee@linaro.org>
To: peter.maydell@linaro.org
Cc: "Fam Zheng" <fam@euphon.net>,
"Philippe Mathieu-Daudé" <philmd@redhat.com>,
"Alex Bennée" <alex.bennee@linaro.org>,
qemu-devel@nongnu.org, "Gerd Hoffmann" <kraxel@redhat.com>
Subject: [PULL v2 02/12] tests/vm: write raw console log
Date: Fri, 27 Mar 2020 18:13:10 +0000 [thread overview]
Message-ID: <20200327181320.23329-3-alex.bennee@linaro.org> (raw)
In-Reply-To: <20200327181320.23329-1-alex.bennee@linaro.org>
From: Gerd Hoffmann <kraxel@redhat.com>
Run "tail -f /var/tmp/*/qemu*console.raw" in another terminal
to watch the install console.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20200310083218.26355-2-kraxel@redhat.com>
Message-Id: <20200323161514.23952-2-alex.bennee@linaro.org>
diff --git a/tests/vm/basevm.py b/tests/vm/basevm.py
index 8400b0e07f6..c53fd354d95 100644
--- a/tests/vm/basevm.py
+++ b/tests/vm/basevm.py
@@ -213,6 +213,9 @@ class BaseVM(object):
def console_init(self, timeout = 120):
vm = self._guest
vm.console_socket.settimeout(timeout)
+ self.console_raw_path = os.path.join(vm._temp_dir,
+ vm._name + "-console.raw")
+ self.console_raw_file = open(self.console_raw_path, 'wb')
def console_log(self, text):
for line in re.split("[\r\n]", text):
@@ -234,6 +237,9 @@ class BaseVM(object):
while True:
try:
chars = vm.console_socket.recv(1)
+ if self.console_raw_file:
+ self.console_raw_file.write(chars)
+ self.console_raw_file.flush()
except socket.timeout:
sys.stderr.write("console: *** read timeout ***\n")
sys.stderr.write("console: waiting for: '%s'\n" % expect)
--
2.20.1
next prev parent reply other threads:[~2020-03-27 18:17 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-27 18:13 [PULL v2 for 5.0 00/12] testing updates (+ one mttcg change) Alex Bennée
2020-03-27 18:13 ` [PULL v2 01/12] qemu/atomic.h: add #ifdef guards for stdatomic.h Alex Bennée
2020-03-27 18:13 ` Alex Bennée [this message]
2020-03-27 18:13 ` [PULL v2 03/12] tests/vm: move vga setup Alex Bennée
2020-03-27 18:13 ` [PULL v2 04/12] tests/vm: update FreeBSD to 12.1 Alex Bennée
2020-03-27 18:13 ` [PULL v2 05/12] tests/vm: update NetBSD to 9.0 Alex Bennée
2020-03-27 18:13 ` [PULL v2 06/12] tests/vm: fix basevm config Alex Bennée
2020-03-27 18:13 ` [PULL v2 07/12] configure: disable MTTCG for MIPS guests Alex Bennée
2020-03-27 18:13 ` [PULL v2 08/12] tests/docker: Keep package list sorted Alex Bennée
2020-03-27 18:13 ` [PULL v2 09/12] tests/docker: Install gcrypt devel package in Debian image Alex Bennée
2020-03-27 18:13 ` [PULL v2 10/12] tests/docker: Use Python3 PyYAML in the Fedora image Alex Bennée
2020-03-27 18:13 ` [PULL v2 11/12] tests/docker: Add libepoxy and libudev packages to " Alex Bennée
2020-03-27 18:13 ` [PULL v2 12/12] .travis.yml: Add a KVM-only s390x job Alex Bennée
2020-03-27 19:18 ` [PULL v2 for 5.0 00/12] testing updates (+ one mttcg change) Peter Maydell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200327181320.23329-3-alex.bennee@linaro.org \
--to=alex.bennee@linaro.org \
--cc=fam@euphon.net \
--cc=kraxel@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=philmd@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).