[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [OSSTEST PATCH 4/6] ts-logs-capture: Run xenctx earlier
Break fetch_xenctx_guest out into its own function, and run it before serial_fetch_logs. This is relevant because serial_fetch_logs sends the Xen debug keys, which might dislodge a stuck guest - and, if it does, we would like to have captured the stuck state with xenctx, rather than the unstuck one. Signed-off-by: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx> Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx> --- ts-logs-capture | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/ts-logs-capture b/ts-logs-capture index 7127675..04cb2fd 100755 --- a/ts-logs-capture +++ b/ts-logs-capture @@ -203,14 +203,9 @@ sub fetch_logs_host () { } } -sub fetch_logs_guest ($) { +sub fetch_xenctx_guest ($) { my ($gho) = @_; - my $gn = $gho->{Name}; - logm("saving logs for $gn"); - - my $consolecmd= toolstack($ho)->consolecmd($gho); - try_cmd_output_save("sleep 1 | $consolecmd | cat", - "guest-$gho->{Name}-console"); + logm("collecting xenctx for $gho->{Name}"); if (defined $gho->{Vcpus}) { foreach (my $vcpu=0; $vcpu < $gho->{Vcpus}; $vcpu++) { @@ -224,6 +219,16 @@ sub fetch_logs_guest ($) { ); } } +} + +sub fetch_logs_guest ($) { + my ($gho) = @_; + my $gn = $gho->{Name}; + logm("saving logs for $gn"); + + my $consolecmd= toolstack($ho)->consolecmd($gho); + try_cmd_output_save("sleep 1 | $consolecmd | cat", + "guest-$gho->{Name}-console"); if (!eval { my $vnc= guest_vncsnapshot_begin($ho,$gho); @@ -235,6 +240,7 @@ sub fetch_logs_guest ($) { } find_guests(); +fetch_xenctx_guest($_) foreach @guests; serial_fetch_logs($ho); fetch_logs_host(); fetch_logs_guest($_) foreach @guests; -- 1.7.10.4 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |