Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(248)

Issue 5174009: Add support for saving VM state when a test fails. (Closed)

Created:
10 years, 1 month ago by thieule
Modified:
6 years, 8 months ago
Reviewers:
Chris Masone, rtc, sosa
CC:
chromium-os-reviews_chromium.org, Mandeep Singh Baines, anush, sosa
Visibility:
Public.

Description

Add support for saving VM state when a test fails. VM state information is stored in a copy-on-write QCOW2 file that is created based on the chromiumos_qemu_image.bin file. Only changes are written to this file. The guest VM triggers the save VM command by writing "savevm" to its /dev/ttyUSB0. This USB serial device is a virtual USB serial device created by QEMU and is redirected to the QEMU monitor. Since QEMU USB serial device emulates an FTDI UART, image_to_vm.sh modifies the kernel command-line parameter to force the usbserial_generic driver to claim the QEMU USB serial device. BUG=9577 TEST=Run cros_run_vm_test with various parameter combinations, force a test failure in the middle of smoke_Suite to ensure a snapshot is created and verify snapshot is correct by loading it, run cros_run_vm_test without new parameters to ensure existing functionalities Change-Id: I776968a61e25efffca2ab761aa5f8a24b80a7369

Patch Set 1 #

Total comments: 2

Patch Set 2 : Change monitor redirection to use unix socket instead of TCP socket #

Patch Set 3 : Fix nit #

Unified diffs Side-by-side diffs Delta from patch set Stats (+45 lines, -1 line) Patch
M bin/cros_run_vm_test View 1 2 3 chunks +23 lines, -0 lines 0 comments Download
M image_to_vm.sh View 1 chunk +6 lines, -0 lines 0 comments Download
M lib/cros_vm_constants.sh View 1 chunk +2 lines, -1 line 0 comments Download
M lib/cros_vm_lib.sh View 1 5 chunks +14 lines, -0 lines 0 comments Download

Messages

Total messages: 11 (0 generated)
thieule
Test infrastructure changes for saving a VM state after a test failure is in a ...
10 years, 1 month ago (2010-11-20 00:30:02 UTC) #1
Chris Masone
lgtm On 2010/11/20 00:30:02, thieule wrote: > Test infrastructure changes for saving a VM state ...
10 years, 1 month ago (2010-11-20 01:16:26 UTC) #2
sosa
LGTM w/ nit http://codereview.chromium.org/5174009/diff/1/bin/cros_run_vm_test File bin/cros_run_vm_test (right): http://codereview.chromium.org/5174009/diff/1/bin/cros_run_vm_test#newcode26 bin/cros_run_vm_test:26: DEFINE_boolean save_vm_state ${FLAGS_FALSE} \ Sort in ...
10 years, 1 month ago (2010-11-20 08:55:08 UTC) #3
thieule
Had to change from TCP socket to unix socket for the redirection to make this ...
10 years, 1 month ago (2010-11-23 22:25:15 UTC) #4
sosa
LGTM
10 years, 1 month ago (2010-11-24 00:44:04 UTC) #5
sosa
Actually don't forget about the nit :) On 2010/11/24 00:44:04, sosa wrote: > LGTM
10 years, 1 month ago (2010-11-24 00:44:30 UTC) #6
thieule
http://codereview.chromium.org/5174009/diff/1/bin/cros_run_vm_test File bin/cros_run_vm_test (right): http://codereview.chromium.org/5174009/diff/1/bin/cros_run_vm_test#newcode26 bin/cros_run_vm_test:26: DEFINE_boolean save_vm_state ${FLAGS_FALSE} \ On 2010/11/20 08:55:08, sosa wrote: ...
10 years, 1 month ago (2010-11-24 00:51:34 UTC) #7
sosa
Was this ever committed?
9 years, 11 months ago (2011-01-04 20:27:00 UTC) #8
thieule
It's been checked in but it hasn't been turned on. We need to start uploading ...
9 years, 11 months ago (2011-01-04 23:38:01 UTC) #9
sosa
Is there any status on the uploading of logs to google storage? I remember seeing ...
9 years, 11 months ago (2011-01-04 23:39:39 UTC) #10
thieule
9 years, 11 months ago (2011-01-04 23:57:05 UTC) #11
+scottz

The CL was committed.  Scottz is looking to integrate it into the buildbots.

On Tue, Jan 4, 2011 at 3:39 PM, Chris Sosa <sosa@chromium.org> wrote:

> Is there any status on the uploading of logs to google storage?  I
> remember seeing the CL for cbuildbot but it doesn't look like it got
> committed.
>
> On Tue, Jan 4, 2011 at 3:37 PM, Thieu Le <thieule@chromium.org> wrote:
> > It's been checked in but it hasn't been turned on.
> > We need to start uploading the logs from the VMs to google storage first
> > since this process also uploads the QEMU disk image.  Eventually, it
> should
> > also upload the state files.
> >
> > On Tue, Jan 4, 2011 at 12:27 PM, <sosa@chromium.org> wrote:
> >>
> >> Was this ever committed?
> >>
> >> http://codereview.chromium.org/5174009/
> >
> >
>

Powered by Google App Engine
This is Rietveld 408576698