So that there is a better chance to debug issues like in [0]. For
suspending, which uses the same QMP calls, this is already done.
[0]: https://forum.proxmox.com/threads/114203/
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
my ($b, $t) = $render_state->($stat);
print "completed saving the VM state in $t, saved $b\n";
last;
+ } elsif ($stat->{status} eq 'failed') {
+ my $err = $stat->{error} || 'unknown error';
+ die "unable to save VM state and RAM - $err\n";
} else {
die "query-savevm returned unexpected status '$stat->{status}'\n";
}