Created attachment 593497 [details] log Description of problem: if I try to create a template from a vm with attached direct lun I get an error that the vm has no disks. I can also create a template when we have a regular disk in the vm. so UI appears to be disregarding the existence of this object in the query. Version-Release number of selected component (if applicable): si6 How reproducible: 100% Steps to Reproduce: 1. try to create a template from a vm with direct lun 2. add regular disk, try to create a template 3. Actual results: we get am error that the vm has no disks and when adding a regular disk we create the template Expected results: we should add direct lun to queries and add an appropriate message. Additional info: backend log
ayal - what's the expectation on creating a VM from a template with a direct lun disk? clone only? I think we can just not allow direct lun disks in tempalte for now? wrt user filtering, if we think this use case is relevant, a user would have a permission to see a direct lun disk since they have a permission to its template.
(In reply to comment #1) > ayal - what's the expectation on creating a VM from a template with a direct > lun disk? clone only? either clone or just not include the disk at all. It's not clear what the correct behaviour should be. > > I think we can just not allow direct lun disks in tempalte for now? The behaviour that was defined the same as for snapshots, when creating a template, the template would not contain the direct lun so this is behaving as designed. > > wrt user filtering, if we think this use case is relevant, a user would have > a permission to see a direct lun disk since they have a permission to its > template.
this is not the correct behaviour. if we do not allow create templates we should block this behaviour from GUI and not leave it as is. reopening bug
(In reply to comment #3) > this is not the correct behaviour. where "this" is? > if we do not allow create templates we should block this behaviour from GUI > and not leave it as is. > reopening bug We allow creating templates from VMs with snappable disks. When creating the template we only clone the snappable disks. So if you have a VM which only has a direct LUN there is no template that can be created from it. Once it has a regular disk (one or more) then you can clone it. This is the defined behaviour and it is exactly as you described it above, so I don't understand what the problem is.
except that our error message is that the vm has no disks which means that we are unaware of its existence in the first place :) aside from giving the wrong error message it means that we are completely ignoring the existence of a direct lun and this was not what was discussed on this feature. I also think that leaving it as is, is a major bug waiting to happen (if for some reason someone will add code that sends the direct lun as a disk to backend and vdsm). just because we do not create the template does not mean that this is the correct behaviour.
Please specify what is going to be fixed here. Not sure what the devel-ack was given for.
(In reply to comment #5) > except that our error message is that the vm has no disks which means that > we are unaware of its existence in the first place :) Error message should indeed be fixed > aside from giving the wrong error message it means that we are completely > ignoring the existence of a direct lun and this was not what was discussed > on this feature. What was discussed is that LUNs are not part of a snapshot > I also think that leaving it as is, is a major bug waiting to happen (if for > some reason someone will add code that sends the direct lun as a disk to > backend and vdsm). I don't know what you mean > > just because we do not create the template does not mean that this is the > correct behaviour. I don't know what you mean here either. devel_ack for changing message.
Ayal - please provide the exact phrase.
Allon, do we allow creation of such templates now? is the code in? (if so please close this bug)
Such creation is still blocked. The exact phrase should be: "Cannot create snapshot. VM has no snappable disks."
I believe you've meant "Cannot create Template. VM has no snappable disks."
Asaf - indeed, my bad.
Patch submitted: http://gerrit.ovirt.org/#/c/7327/
(In reply to comment #11) > I believe you've meant "Cannot create Template. VM has no snappable disks." 'Snappable' is not a word in English. Please avoid using it in formal messages, despite it being catchy. so *if* we go on blocking it, message should be something in the lines of: Template creation requires disks which are eligible for snapshot creation, VM has none. Andrew, can you suggest a better phrasing? Allon, I thought we do not wish to prevent this? (template would be virtual hardware config and networks/cluster info only).
Waiting for Andrew to answer, re-assigning.
Ayal - we don't /want/ to block this, the question is do we want to create such a behviour change given the RHEV-M's release timeline?
Guys, sorry, please ignore my last couple of comments. The correct behaviour we agreed upon is indeed to allow diskless templates. There is already a patch pending review for this in response to #841534. I'm closing this bug as a duplicate. *** This bug has been marked as a duplicate of bug 841534 ***