Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1115556

Summary: volUUID in "vdsClient -s 0 prepareImage" should not be optional
Product: [Retired] oVirt Reporter: Kevin Alon Goldblatt <kgoldbla>
Component: vdsmAssignee: Allon Mureinik <amureini>
Status: CLOSED CURRENTRELEASE QA Contact: Kevin Alon Goldblatt <kgoldbla>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 3.5CC: acanan, alitke, amureini, bazulay, bugs, ebenahar, gklein, mgoldboi, rbalakri, tnisan, yeylon
Target Milestone: m1Flags: amureini: ovirt_requires_release_note-
Target Release: 3.6.0   
Hardware: x86_64   
OS: Linux   
Whiteboard: storage
Fixed In Version: vdsm-4.17.0-1198.git6ede99a Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-11-04 12:57:42 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Storage RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
engine vdsm logs and screenshot none

Description Kevin Alon Goldblatt 2014-07-02 15:27:56 UTC
Created attachment 914229 [details]
engine vdsm logs and screenshot

Description of problem: Ran vdsClient -s 0 spUUID sdUUID imgUUID (AND NOT THE volUUID)


Version-Release number of selected component (if applicable):
ovirt-engine-3.5.0-0.0.master.20140629172257.git0b16ed7.el6.noarch
vdsm-4.16.0-3.git601f786.el6.x86_64

How reproducible:


Steps to Reproduce:
1. Create VM with block disk
2. VM is in down state
3. Ran vdsClient -s 0 spUUID sdUUID imgUUID (AND NOT THE volUUID) >>> operation fails 

Actual results:
'NoneType' object has no attribute 'startswith'

Expected results:
Should work without OPTIONAL volUUID

Additional info: vdsm.log output>>>>>

Thread-666::ERROR::2014-07-02 17:49:31,281::task::866::Storage.TaskManager.Task::(_setError) Task=`3587a661-c287-4a8c-a951-88eafcfe7f5e`::Unexpected error
Traceback (most recent call last):
  File "/usr/share/vdsm/storage/task.py", line 873, in _run
    return fn(*args, **kargs)
  File "/usr/share/vdsm/logUtils.py", line 45, in wrapper
    res = f(*args, **kwargs)
  File "/usr/share/vdsm/storage/hsm.py", line 3214, in prepareImage
    leafPath = os.path.join(runImgPath, leafUUID)
  File "/usr/lib64/python2.6/posixpath.py", line 65, in join
    if b.startswith('/'):
AttributeError: 'NoneType' object has no attribute 'startswith'
Thread-666::DEBUG::2014-07-02 17:49:31,295::task::885::Storage.TaskManager.Task::(_run) Task=`3587a661-c287-4a8c-a951-88eafcfe7f5e`::Task._run: 3587a661-c287-4a8c-a951-88eafcfe7f5e ('a4fc14aa-ca84-433d-a207-b8a14bb0cab6', 'a5c0668
5-789f-4737-8027-012a290de30a', '52aaf548-4fb3-440e-92a5-4902d92ab431', None) {} failed - stopping task
Thread-666::DEBUG::2014-07-02 17:49:31,299::task::1217::Storage.TaskManager.Task::(stop) Task=`3587a661-c287-4a8c-a951-88eafcfe7f5e`::stopping in state preparing (force False)
Thread-666::DEBUG::2014-07-02 17:49:31,303::task::993::Storage.TaskManager.Task::(_decref) Task=`3587a661-c287-4a8c-a951-88eafcfe7f5e`::ref 1 aborting True
Thread-666::INFO::2014-07-02 17:49:31,306::task::1171::Storage.TaskManager.Task::(prepare) Task=`3587a661-c287-4a8c-a951-88eafcfe7f5e`::aborting: Task is aborted: u"'NoneType' object has no attribute 'startswith'" - code 100
Thread-666::DEBUG::2014-07-02 17:49:31,309::task::1176::Storage.TaskManager.Task::(prepare) Task=`3587a661-c287-4a8c-a951-88eafcfe7f5e`::Prepare: aborted: 'NoneType' object has no attribute 'startswith'
Thread-666::DEBUG::2014-07-02 17:49:31,312::task::993::Storage.TaskManager.Task::(_decref) Task=`3587a661-c287-4a8c-a951-88eafcfe7f5e`::ref 0 aborting True
Thread-666::DEBUG::2014-07-02 17:49:31,315::task::928::Storage.TaskManager.Task::(_doAbort) Task=`3587a661-c287-4a8c-a951-88eafcfe7f5e`::Task._doAbort: force False
Thread-666::DEBUG::2014-07-02 17:49:31,318::resourceManager::977::Storage.ResourceManager.Owner::(cancelAll) Owner.cancelAll requests {}
Thread-666::DEBUG::2014-07-02 17:49:31,322::task::595::Storage.TaskManager.Task::(_updateState) Task=`3587a661-c287-4a8c-a951-88eafcfe7f5e`::moving from state preparing -> state aborting
Thread-666::DEBUG::2014-07-02 17:49:31,325::task::550::Storage.TaskManager.Task::(__state_aborting) Task=`3587a661-c287-4a8c-a951-88eafcfe7f5e`::_aborting: recover policy none
Thread-666::DEBUG::2014-07-02 17:49:31,329::task::595::Storage.TaskManager.Task::(_updateState) Task=`3587a661-c287-4a8c-a951-88eafcfe7f5e`::moving from state aborting -> state failed
Thread-666::DEBUG::2014-07-02 17:49:31,332::resourceManager::940::Storage.ResourceManager.Owner::(releaseAll) Owner.releaseAll requests {} resources {'Storage.a4fc14aa-ca84-433d-a207-b8a14bb0cab6': < ResourceRef 'Storage.a4fc14aa-
ca84-433d-a207-b8a14bb0cab6', isValid: 'True' obj: 'None'>}
Thread-666::DEBUG::2014-07-02 17:49:31,335::resourceManager::977::Storage.ResourceManager.Owner::(cancelAll) Owner.cancelAll requests {}
Thread-666::DEBUG::2014-07-02 17:49:31,340::resourceManager::616::Storage.ResourceManager::(releaseResource) Trying to release resource 'Storage.a4fc14aa-ca84-433d-a207-b8a14bb0cab6'
Thread-666::DEBUG::2014-07-02 17:49:31,344::resourceManager::635::Storage.ResourceManager::(releaseResource) Released resource 'Storage.a4fc14aa-ca84-433d-a207-b8a14bb0cab6' (0 active users)
Thread-666::DEBUG::2014-07-02 17:49:31,346::resourceManager::641::Storage.ResourceManager::(releaseResource) Resource 'Storage.a4fc14aa-ca84-433d-a207-b8a14bb0cab6' is free, finding out if anyone is waiting for it.
Thread-666::DEBUG::2014-07-02 17:49:31,348::resourceManager::649::Storage.ResourceManager::(releaseResource) No one is waiting for resource 'Storage.a4fc14aa-ca84-433d-a207-b8a14bb0cab6', Clearing records.
Thread-666::ERROR::2014-07-02 17:49:31,351::dispatcher::79::Storage.Dispatcher::(wrapper) 'NoneType' object has no attribute 'startswith'
Traceback (most recent call last):
  File "/usr/share/vdsm/storage/dispatcher.py", line 71, in wrapper
    result = ctask.prepare(func, *args, **kwargs)
  File "/usr/share/vdsm/storage/task.py", line 103, in wrapper
    return m(self, *a, **kw)
  File "/usr/share/vdsm/storage/task.py", line 1179, in prepare
    raise self.error

Comment 1 Allon Mureinik 2014-08-27 16:32:12 UTC
vdsClient is not a critical flow, pushing out to oVirt 3.5.1

Comment 2 Elad 2015-08-16 12:23:16 UTC
Volume UUID is now mandatory for manual prepareImage execution.
Trying to perform prepareImage using vdsClient, without the vol UUID fails. The error is not pretty, reported here:
https://bugzilla.redhat.com/show_bug.cgi?id=1254001

Thread-8321::ERROR::2015-08-16 15:13:31,404::bindingxmlrpc::330::vds::(wrapper) Unexpected exception
Traceback (most recent call last):
  File "/usr/share/vdsm/rpc/bindingxmlrpc.py", line 328, in wrapper
    return f(*args, **kwargs)
TypeError: imagePrepare() takes exactly 5 arguments (4 given)
Thread-8321::INFO::2015-08-16 15:13:31,406::xmlrpc::92::vds.XMLRPCServer::(_process_requests) Request handler for 127.0.0.1:50031 stopped


Used ovirt-3.6.0-5
vdsm-4.17.0-1239.git6575e3f.el7.noarch
vdsm-cli-4.17.0-1239.git6575e3f.el7.noarch

Comment 3 Sandro Bonazzola 2015-11-04 12:57:42 UTC
oVirt 3.6.0 has been released on November 4th, 2015 and should fix this issue.
If problems still persist, please open a new BZ and reference this one.