<div dir="ltr"><br><br><div class="gmail_quote"><div dir="ltr">On Tue, Apr 24, 2018 at 9:36 AM David David <<a href="mailto:dd432690@gmail.com">dd432690@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi all.<br>
oVirt 4.2<br>
trying to upload disk snapshot<br>
thereis VM named vm-test, with disk id =<br>
078398f5-0679-4eec-97e2-d227c097f453, storage = data00 and cluster =<br>
testcluster.<br>
i do snapshot of this VM.<br>
and subsequently launched these scripts<br>
<br>
download_vm_ovf.py<br>
==================<br>
if __name__ == "__main__":<br>
<br>
# Set VM name<br>
vm_name = 'vm-test'<br>
====================<br>
<br>
the ovf file is saved as 1d45f654-2ade-46c9-a747-2cd01ce14df2.ovf<br>
<br>
download_disk_snapshots.py<br>
==========================<br>
if __name__ == "__main__":<br>
<br>
# Set relevant disk and stroage domain IDs<br>
disk_id = '078398f5-0679-4eec-97e2-d227c097f453'<br>
sd_name = 'data00'<br>
==========================<br>
<br>
the snapshot is saved as a8278905-57c9-4321-ab08-633436c5a63c<br>
<br>
upload_disk_snapshots.py:<br>
=========================<br>
if __name__ == "__main__":<br>
<br>
# Set storage domain name<br>
sd_name = 'data00'<br>
<br>
# Set OVF file path<br>
ovf_file_path = '1d45f654-2ade-46c9-a747-2cd01ce14df2.ovf'<br>
<br>
# Disk to upload<br>
disk_path = 'a8278905-57c9-4321-ab08-633436c5a63c'<br>
==================================<br>
<br>
when trying run script upload_disk_snapshots.py, i got error with these message:<br>
<br>
Traceback (most recent call last):<br>
File "snapshot_upload.py", line 279, in <module><br>
images_chain = get_images_chain(disk_path)<br>
File "snapshot_upload.py", line 244, in get_images_chain<br>
base_volume = [v for v in volumes_info.values() if<br>
'full-backing-filename' not in v ][0]<br>
IndexError: list index out of range<br>
<br>
Anyone can help with this?<br></blockquote><div><br></div><div>Hi David,</div><div><br></div><div>Please make sure that the snapshots are located inside the disk folder.</div><div>I.e. </div><div>- <disk-Id></div><div>-- <snapshot-1-id></div><div>-- <snapshot-2-id></div><div>-- ...</div><div>Also, can you please attach the output of "qemu-img info" on each snapshot.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@ovirt.org" target="_blank">Users@ovirt.org</a><br>
<a href="http://lists.ovirt.org/mailman/listinfo/users" rel="noreferrer" target="_blank">http://lists.ovirt.org/mailman/listinfo/users</a><br>
</blockquote></div></div>