On Mon, Sep 16, 2019 at 07:13:51PM +0200, Pino Toscano wrote: > Make sure to cancel the trasfer in RHV in case of failure during the > copying of a disk: this way, the disk can be actually removed by RHV > itself. > --- > v2v/rhv-upload-plugin.py | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/v2v/rhv-upload-plugin.py b/v2v/rhv-upload-plugin.py > index 4d61a089b..57e90484f 100644 > --- a/v2v/rhv-upload-plugin.py > +++ b/v2v/rhv-upload-plugin.py > @@ -485,6 +485,8 @@ def flush(h): > r.read() > > def delete_disk_on_failure(h): > + transfer_service = h['transfer_service'] > + transfer_service.cancel() > disk_service = h['disk_service'] > disk_service.remove()
ACK Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com libguestfs lets you edit virtual machines. Supports shell scripting, bindings from many languages. http://libguestfs.org _______________________________________________ Libguestfs mailing list [email protected] https://www.redhat.com/mailman/listinfo/libguestfs
