From: "Karli Sjöberg" <Karli.Sjoberg(a)slu.se>
To: "Eli Mesika" <emesika(a)redhat.com>
Cc: "Users(a)ovirt.org" <users(a)ovirt.org>
Sent: Monday, November 4, 2013 1:00:46 PM
Subject: Re: [Users] Cannot delete a template
mån 2013-11-04 klockan 05:56 -0500 skrev Eli Mesika:
----- Original Message -----
> From: "Karli Sjöberg"
<Karli.Sjoberg@slu.se<mailto:Karli.Sjoberg@slu.se>>
> To: "Users@ovirt.org<mailto:Users@ovirt.org>"
> <users@ovirt.org<mailto:users@ovirt.org>>
> Sent: Monday, November 4, 2013 9:08:19 AM
> Subject: [Users] Cannot delete a template
>
> Hi!
>
> I´m trying to delete an old template (NFS Datastore) but engine won´t let
> me.
> Here´s the relevant part of SPM´s vdsmd.log:
Did you notice that VDSM claims that the volume is shared :
CannotDeleteSharedVolume: Shared Volume cannot be deleted: ("Cannot delete
shared image ae73b435-2935-4e9f-9269-c6c8fad2cf38. ......
Yes I noticed that but I don´t even know what that means, betting that´s a
bad thing? How do I change that, I found no toggle of that in Template ->
Edit, or looking at it through Disk?
Do you have any VMs that were created from this old template ,
You can see that when you select a template from the web-admin UI ...
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,269::BindingXMLRPC::161::vds::(wrapper) [130.238.96.66]
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,270::task::568::TaskManager.Task::(_updateState)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::moving from state init ->
> state
> preparing
> Thread-304915::INFO::2013-11-04
> 07:51:56,270::logUtils::41::dispatcher::(wrapper) Run and protect:
> deleteImage(sdUUID='f231d176-a11a-47a8-84e7-12bfa9095bdd',
> spUUID='8b70c99d-50f2-4a30-9214-c51ef20cb48a',
> imgUUID='ae73b435-2935-4e9f-9269-c6c8fad2cf38', postZero='false',
> force='false')
> Thread-304915::INFO::2013-11-04
> 07:51:56,270::fileSD::302::Storage.StorageDomain::(validate)
> sdUUID=f231d176-a11a-47a8-84e7-12bfa9095bdd
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,279::persistentDict::234::Storage.PersistentDict::(refresh) read
> lines (FileMetadataRW)=['CLASS=Data',
'DESCRIPTION=ZFS2-1_DS1_Data',
> 'IOOPTIMEOUTSEC=10', 'LEASERETRIES=3', 'LEASETIMESEC=60',
'LOCKPOLICY=',
> 'LOCKRENEWALINTERVALSEC=5', 'MASTER_VERSION=902',
'POOL_DESCRIPTION=C4241',
>
'POOL_DOMAINS=773370d4-be5d-43d8-95cd-ffd3a6a5b1c8:Active,50aba7a1-bbc1-4eca-8480-45ec37b64e63:Active,4f46680f-a70d-4846-bfc3-9318ce7d4d6d:Active,f231d176-a11a-47a8-84e7-12bfa9095bdd:Active',
> 'POOL_SPM_ID=-1', 'POOL_SPM_LVER=-1',
> 'POOL_UUID=8b70c99d-50f2-4a30-9214-c51ef20cb48a',
> 'REMOTE_PATH=hostnfs5-ua.sto.slu.se:/export/ds1/data',
'ROLE=Master',
> 'SDUUID=f231d176-a11a-47a8-84e7-12bfa9095bdd', 'TYPE=NFS',
'VERSION=3',
> '_SHA_CKSUM=de1b77f5912e94052c4fbd21299f44a6498275d9']
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,280::resourceManager::190::ResourceManager.Request::(__init__)
>
ResName=`Storage.ae73b435-2935-4e9f-9269-c6c8fad2cf38`ReqID=`e412eadc-5af7-426f-94f9-4d52783614e7`::Request
> was made in '/usr/share/vdsm/storage/resourceManager.py' line '189'
at
> '__init__'
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,280::resourceManager::504::ResourceManager::(registerResource)
> Trying to register resource 'Storage.ae73b435-2935-4e9f-9269-c6c8fad2cf38'
> for lock type 'exclusive'
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,281::resourceManager::547::ResourceManager::(registerResource)
> Resource 'Storage.ae73b435-2935-4e9f-9269-c6c8fad2cf38' is free. Now
> locking
> as 'exclusive' (1 active user)
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,281::resourceManager::227::ResourceManager.Request::(grant)
>
ResName=`Storage.ae73b435-2935-4e9f-9269-c6c8fad2cf38`ReqID=`e412eadc-5af7-426f-94f9-4d52783614e7`::Granted
> request
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,281::task::794::TaskManager.Task::(resourceAcquired)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::_resourcesAcquired:
> Storage.ae73b435-2935-4e9f-9269-c6c8fad2cf38 (exclusive)
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,281::task::957::TaskManager.Task::(_decref)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::ref 1 aborting False
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,282::resourceManager::190::ResourceManager.Request::(__init__)
>
ResName=`Storage.f231d176-a11a-47a8-84e7-12bfa9095bdd`ReqID=`544caeb2-9d61-42e4-9fc7-1f7811700f4b`::Request
> was made in '/usr/share/vdsm/storage/resourceManager.py' line '189'
at
> '__init__'
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,282::resourceManager::504::ResourceManager::(registerResource)
> Trying to register resource 'Storage.f231d176-a11a-47a8-84e7-12bfa9095bdd'
> for lock type 'shared'
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,282::resourceManager::547::ResourceManager::(registerResource)
> Resource 'Storage.f231d176-a11a-47a8-84e7-12bfa9095bdd' is free. Now
> locking
> as 'shared' (1 active user)
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,283::resourceManager::227::ResourceManager.Request::(grant)
>
ResName=`Storage.f231d176-a11a-47a8-84e7-12bfa9095bdd`ReqID=`544caeb2-9d61-42e4-9fc7-1f7811700f4b`::Granted
> request
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,283::task::794::TaskManager.Task::(resourceAcquired)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::_resourcesAcquired:
> Storage.f231d176-a11a-47a8-84e7-12bfa9095bdd (shared)
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,283::task::957::TaskManager.Task::(_decref)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::ref 1 aborting False
> Thread-304915::ERROR::2013-11-04
> 07:51:56,313::task::833::TaskManager.Task::(_setError)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::Unexpected error
> Traceback (most recent call last):
> File "/usr/share/vdsm/storage/task.py", line 840, in _run
> return fn(*args, **kargs)
> File "/usr/share/vdsm/logUtils.py", line 42, in wrapper
> res = f(*args, **kwargs)
> File "/usr/share/vdsm/storage/hsm.py", line 1451, in deleteImage
> volsByImg))
> CannotDeleteSharedVolume: Shared Volume cannot be deleted: ("Cannot delete
> shared image ae73b435-2935-4e9f-9269-c6c8fad2cf38. volImgs:
> {'711b744a-763b-43b3-ab7b-22e83e946d3a':
> ImgsPar(imgs=('ae73b435-2935-4e9f-9269-c6c8fad2cf38',
> '7dd3c35f-8ed0-45ad-a726-b05b4e9abb74',
> '230589b8-dff3-4fb0-884f-9db9a47c07ec',
> '34b09185-16ae-4572-8d52-9952eb8e05fb',
> '672dcf0a-cb31-4dc6-810c-8ff4cd5dcd0d',
> '958f2901-1a7e-4baf-bd1e-ee4d330c2006',
> '4a8860b4-f400-4615-b641-c74bb495230f',
> '4e2a0c92-859e-4743-a96a-b525a9bfa546',
> '97d119a6-ee8d-4c12-ab7d-ba51522a4d27',
> 'cd9e401e-c149-4cf0-934b-be060ec0532d',
> '991efa47-5e52-4b93-a70b-067e827acbed',
> '50c0ebd7-7219-4972-9cf4-62281a81f857',
> '0fb579aa-ee73-4ced-ae3d-005f12594fb6',
> 'c50a5f9f-0693-47b8-aed9-45a8b308adaf',
> 'cec48065-742a-4ce8-90ea-c09d9e66083e',
> 'ac2d33a0-76b2-4b50-b7d3-337cc4d4dc00',
> '15703619-8013-4af9-a6cf-59c53142206c',
> 'd5c28f70-950c-4b3d-8b9b-dec358f8760f',
> '4fcece59-2ea3-4691-88c9-e248554c43fe',
> '53691576-41d2-4865-9cbf-de0c39f063db',
> 'f6bb39c1-3f35-4236-ae82-29bb8bf44d75'),
> parent='00000000-0000-0000-0000-000000000000')}",)
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,320::task::852::TaskManager.Task::(_run)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::Task._run:
> 78b8f42d-14cd-48e2-9e3e-61a6610c9f66
> ('f231d176-a11a-47a8-84e7-12bfa9095bdd',
> '8b70c99d-50f2-4a30-9214-c51ef20cb48a',
> 'ae73b435-2935-4e9f-9269-c6c8fad2cf38', 'false', 'false') {}
failed -
> stopping task
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,320::task::1177::TaskManager.Task::(stop)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::stopping in state preparing
> (force False)
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,320::task::957::TaskManager.Task::(_decref)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::ref 1 aborting True
> Thread-304915::INFO::2013-11-04
> 07:51:56,320::task::1134::TaskManager.Task::(prepare)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::aborting: Task is aborted:
> 'Shared Volume cannot be deleted' - code 223
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,321::task::1139::TaskManager.Task::(prepare)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::Prepare: aborted: Shared
> Volume
> cannot be deleted
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,321::task::957::TaskManager.Task::(_decref)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::ref 0 aborting True
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,321::task::892::TaskManager.Task::(_doAbort)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::Task._doAbort: force False
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,321::resourceManager::864::ResourceManager.Owner::(cancelAll)
> Owner.cancelAll requests {}
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,321::task::568::TaskManager.Task::(_updateState)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::moving from state preparing ->
> state aborting
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,322::task::523::TaskManager.Task::(__state_aborting)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::_aborting: recover policy none
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,322::task::568::TaskManager.Task::(_updateState)
> Task=`78b8f42d-14cd-48e2-9e3e-61a6610c9f66`::moving from state aborting ->
> state failed
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,322::resourceManager::830::ResourceManager.Owner::(releaseAll)
> Owner.releaseAll requests {} resources
> {'Storage.f231d176-a11a-47a8-84e7-12bfa9095bdd': < ResourceRef
> 'Storage.f231d176-a11a-47a8-84e7-12bfa9095bdd', isValid: 'True'
obj:
> 'None'>, 'Storage.ae73b435-2935-4e9f-9269-c6c8fad2cf38': <
ResourceRef
> 'Storage.ae73b435-2935-4e9f-9269-c6c8fad2cf38', isValid: 'True'
obj:
> 'None'>}
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,322::resourceManager::864::ResourceManager.Owner::(cancelAll)
> Owner.cancelAll requests {}
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,323::resourceManager::557::ResourceManager::(releaseResource)
> Trying to release resource 'Storage.f231d176-a11a-47a8-84e7-12bfa9095bdd'
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,323::resourceManager::573::ResourceManager::(releaseResource)
> Released resource 'Storage.f231d176-a11a-47a8-84e7-12bfa9095bdd' (0 active
> users)
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,323::resourceManager::578::ResourceManager::(releaseResource)
> Resource 'Storage.f231d176-a11a-47a8-84e7-12bfa9095bdd' is free, finding
> out
> if anyone is waiting for it.
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,323::resourceManager::585::ResourceManager::(releaseResource) No
> one is waiting for resource 'Storage.f231d176-a11a-47a8-84e7-12bfa9095bdd',
> Clearing records.
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,323::resourceManager::557::ResourceManager::(releaseResource)
> Trying to release resource 'Storage.ae73b435-2935-4e9f-9269-c6c8fad2cf38'
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,324::resourceManager::573::ResourceManager::(releaseResource)
> Released resource 'Storage.ae73b435-2935-4e9f-9269-c6c8fad2cf38' (0 active
> users)
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,324::resourceManager::578::ResourceManager::(releaseResource)
> Resource 'Storage.ae73b435-2935-4e9f-9269-c6c8fad2cf38' is free, finding
> out
> if anyone is waiting for it.
> Thread-304915::DEBUG::2013-11-04
> 07:51:56,324::resourceManager::585::ResourceManager::(releaseResource) No
> one is waiting for resource 'Storage.ae73b435-2935-4e9f-9269-c6c8fad2cf38',
> Clearing records.
> Thread-304915::ERROR::2013-11-04
> 07:51:56,324::dispatcher::67::Storage.Dispatcher.Protect::(run) {'status':
> {'message': 'Shared Volume cannot be deleted: ("Cannot delete
shared image
> ae73b435-2935-4e9f-9269-c6c8fad2cf38. volImgs:
> {\'711b744a-763b-43b3-ab7b-22e83e946d3a\':
> ImgsPar(imgs=(\'ae73b435-2935-4e9f-9269-c6c8fad2cf38\',
> \'7dd3c35f-8ed0-45ad-a726-b05b4e9abb74\',
> \'230589b8-dff3-4fb0-884f-9db9a47c07ec\',
> \'34b09185-16ae-4572-8d52-9952eb8e05fb\',
> \'672dcf0a-cb31-4dc6-810c-8ff4cd5dcd0d\',
> \'958f2901-1a7e-4baf-bd1e-ee4d330c2006\',
> \'4a8860b4-f400-4615-b641-c74bb495230f\',
> \'4e2a0c92-859e-4743-a96a-b525a9bfa546\',
> \'97d119a6-ee8d-4c12-ab7d-ba51522a4d27\',
> \'cd9e401e-c149-4cf0-934b-be060ec0532d\',
> \'991efa47-5e52-4b93-a70b-067e827acbed\',
> \'50c0ebd7-7219-4972-9cf4-62281a81f857\',
> \'0fb579aa-ee73-4ced-ae3d-005f12594fb6\',
> \'c50a5f9f-0693-47b8-aed9-45a8b308adaf\',
> \'cec48065-742a-4ce8-90ea-c09d9e66083e\',
> \'ac2d33a0-76b2-4b50-b7d3-337cc4d4dc00\',
> \'15703619-8013-4af9-a6cf-59c53142206c\',
> \'d5c28f70-950c-4b3d-8b9b-dec358f8760f\',
> \'4fcece59-2ea3-4691-88c9-e248554c43fe\',
> \'53691576-41d2-4865-9cbf-de0c39f063db\',
> \'f6bb39c1-3f35-4236-ae82-29bb8bf44d75\'),
> parent=\'00000000-0000-0000-0000-000000000000\')}",)',
'code': 223}}
> Thread-304917::DEBUG::2013-11-04
> 07:51:56,869::BindingXMLRPC::161::vds::(wrapper) [130.238.96.66]
> Thread-304917::DEBUG::2013-11-04
> 07:51:56,870::task::568::TaskManager.Task::(_updateState)
> Task=`f32c1aed-5857-4dfc-90be-8d2f3a4186da`::moving from state init ->
> state
> preparing
> Thread-304917::INFO::2013-11-04
> 07:51:56,870::logUtils::41::dispatcher::(wrapper) Run and protect:
> getSpmStatus(spUUID='8b70c99d-50f2-4a30-9214-c51ef20cb48a', options=None)
> Thread-304917::INFO::2013-11-04
> 07:51:56,870::logUtils::44::dispatcher::(wrapper) Run and protect:
> getSpmStatus, Return response: {'spm_st': {'spmId': 2,
'spmStatus': 'SPM',
> 'spmLver': 72}}
> Thread-304917::DEBUG::2013-11-04
> 07:51:56,870::task::1151::TaskManager.Task::(prepare)
> Task=`f32c1aed-5857-4dfc-90be-8d2f3a4186da`::finished: {'spm_st':
{'spmId':
> 2, 'spmStatus': 'SPM', 'spmLver': 72}}
> Thread-304917::DEBUG::2013-11-04
> 07:51:56,871::task::568::TaskManager.Task::(_updateState)
> Task=`f32c1aed-5857-4dfc-90be-8d2f3a4186da`::moving from state preparing ->
> state finished
> Thread-304917::DEBUG::2013-11-04
> 07:51:56,871::resourceManager::830::ResourceManager.Owner::(releaseAll)
> Owner.releaseAll requests {} resources {}
> Thread-304917::DEBUG::2013-11-04
> 07:51:56,871::resourceManager::864::ResourceManager.Owner::(cancelAll)
> Owner.cancelAll requests {}
> Thread-304917::DEBUG::2013-11-04
> 07:51:56,871::task::957::TaskManager.Task::(_decref)
> Task=`f32c1aed-5857-4dfc-90be-8d2f3a4186da`::ref 0 aborting False
>
> And here´s how it looks like from the storage side:
> # ls -lah
>
/export/ds1/data/f231d176-a11a-47a8-84e7-12bfa9095bdd/images/ae73b435-2935-4e9f-9269-c6c8fad2cf38/
> total 243
> drwxr-xr-x+ 2 36 36 5B Aug 14 07:22 .
> drwxr-xr-x+ 67 36 36 67B Oct 28 15:41 ..
> -rw-rw-r--+ 21 36 36 40G Sep 27 2012 711b744a-763b-43b3-ab7b-22e83e946d3a
> -rw-rw-r--+ 21 36 36 1.0M Aug 14 07:22
> 711b744a-763b-43b3-ab7b-22e83e946d3a.lease
> -rw-rw-r--+ 21 36 36 270B Sep 27 2012
> 711b744a-763b-43b3-ab7b-22e83e946d3a.meta
>
> Any thoughts on how I could get rid of this thing?
>
>
> --
>
> Med Vänliga Hälsningar
> -------------------------------------------------------------------------------
> Karli Sjöberg
> Swedish University of Agricultural Sciences
> Box 7079 (Visiting Address Kronåsvägen 8)
> S-750 07 Uppsala, Sweden
> Phone: +46-(0)18-67 15 66
> karli.sjoberg@slu.se<mailto:karli.sjoberg@slu.se>
>
> _______________________________________________
> Users mailing list
> Users@ovirt.org<mailto:Users@ovirt.org>
>
http://lists.ovirt.org/mailman/listinfo/users
>
--
Med Vänliga Hälsningar
-------------------------------------------------------------------------------
Karli Sjöberg
Swedish University of Agricultural Sciences
Box 7079 (Visiting Address Kronåsvägen 8)
S-750 07 Uppsala, Sweden
Phone: +46-(0)18-67 15 66
karli.sjoberg@slu.se<mailto:karli.sjoberg@adm.slu.se>