VMware: write error lost while transferring volume
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Low
|
Unassigned | ||
oslo.vmware |
Confirmed
|
Low
|
Unassigned |
Bug Description
I'm running the following command:
cinder create --image-id a24f216f-
The write side of the data transfer (a VMwareHTTPWriteFile object) returns an error in write() which I haven't debugged, yet. However, this error is never reported to the user, although it does show up in the logs. The effect is that the transfer sits in the 'downloading' state until the 7200 second timeout, when it reports the timeout.
The reason is that the code which waits on transfer completion (in start_transfer) does:
try:
# Wait on the read and write events to signal their end
except (timeout.Timeout, Exception) as exc:
...
That is, it waits for the read thread to signal completion via read_event before checking write_event. However, because write_thread has died, read_thread is blocking and will never signal completion. You can demonstrate this by swapping the order. If you want for write first it will die immediately, which is what you want. However, that's not right either because now you're missing read errors.
Ideally this code needs to be able to notice an error at either end and stop immediately.
tags: | added: vmware |
Changed in cinder: | |
status: | New → Confirmed |
importance: | Undecided → Low |
assignee: | nobody → Vipin Balachandran (vbala) |
Changed in oslo.vmware: | |
status: | New → Confirmed |
assignee: | nobody → Vipin Balachandran (vbala) |
importance: | Undecided → Low |
Changed in nova: | |
status: | New → Confirmed |
importance: | Undecided → Low |
no longer affects: | cinder |
Changed in oslo.vmware: | |
assignee: | Vipin Balachandran (vbala) → nobody |
The same problem exists in Nova as we use the same approach for image transfer:
https:/ /github. com/openstack/ nova/blob/ master/ nova/virt/ vmwareapi/ images. py#L181