Created attachment 1262974 [details] logs: engine, imageio-proxy, imageio-daemon, vdsm, sanlock +++ This bug was initially created as a clone of Bug #1432079 +++ Description of problem: Trying to download an image when it's storage domain is in maintenance - result in an NPE in engine's log. Version-Release number of selected component (if applicable): rhevm-4.1.1.4-0.1.el7.noarch vdsm-4.19.7-1.el7ev.x86_64 ovirt-imageio-common-1.0.0-0.el7ev.noarch ovirt-imageio-proxy-1.0.0-0.el7ev.noarch ovirt-imageio-daemon-1.0.0-0.el7ev.noarch How reproducible: 100% Steps to Reproduce: 1. Put storage domain to maintenance 2. When storage domain is in maintenance, try to download an image (using python sdk). Actual results: 2017-03-14 14:24:16,124+02 INFO [org.ovirt.engine.core.vdsbroker.vdsbroker.PrepareImageVDSCommand] (default task-13) [338d345d-25c5-4eab-94c7-b5fc7600d46d] START, PrepareImageVDSCommand(HostName = host_mixed_1, PrepareImageVDSCommandParameters:{runAsync='true', hostId='9e8a3147-850c-45fd-84fd-c1bd549881e7'}), log id: 4bd9257e 2017-03-14 14:24:17,368+02 ERROR [org.ovirt.engine.core.vdsbroker.vdsbroker.PrepareImageVDSCommand] (default task-13) [338d345d-25c5-4eab-94c7-b5fc7600d46d] Failed in 'PrepareImageVDS' method, for vds: 'host_mixed_1'; host: 'storage-ge9-vdsm1.qa.lab.tlv.redhat.com': null 2017-03-14 14:24:17,368+02 ERROR [org.ovirt.engine.core.vdsbroker.vdsbroker.PrepareImageVDSCommand] (default task-13) [338d345d-25c5-4eab-94c7-b5fc7600d46d] Command 'PrepareImageVDSCommand(HostName = host_mixed_1, PrepareImageVDSCommandParameters:{runAsync='true', hostId='9e8a3147-850c-45fd-84fd-c1bd549881e7'})' execution failed: null 2017-03-14 14:24:17,368+02 INFO [org.ovirt.engine.core.vdsbroker.vdsbroker.PrepareImageVDSCommand] (default task-13) [338d345d-25c5-4eab-94c7-b5fc7600d46d] FINISH, PrepareImageVDSCommand, log id: 4bd9257e 2017-03-14 14:24:17,369+02 ERROR [org.ovirt.engine.core.bll.storage.disk.image.TransferDiskImageCommand] (default task-13) [338d345d-25c5-4eab-94c7-b5fc7600d46d] Failed to prepare image for transfer session: {}: org.ovirt.engine.core.common.errors.EngineException: EngineException: java.lang.NullPointerException (Failed with error ENGINE and code 5001) Expected results: For the download to just fail gracefully - with no NPE.
Verified using builds: rhevm-4.1.2.2-0.1.el7.noarch vdsm-4.19.14-1.el7ev.x86_64 ovirt-imageio-common-1.0.0-0.el7ev.noarch ovirt-imageio-proxy-1.0.0-0.el7ev.noarch ovirt-imageio-daemon-1.0.0-0.el7ev.noarch