harikrishna-patnala opened a new issue #4902:
URL: https://github.com/apache/cloudstack/issues/4902
<!--
Verify first that your issue/request is not already reported on GitHub.
Also test if the latest release and master branch are affected too.
Always add information AFTER of these HTML comments, but no need to delete
the comments.
-->
This is an improvement ticket in which volumes of a VM which are not
intended to be deleted (when VM is tried to destroy) are going to be detached
from VM during destroy VM operation.
CloudStack volumes are first-class citizens, they do not belong to a VM.
Therefore data disks must be detached from the destroyed VM and either be
expunged (if that is what the user requested) or be left detached and available
for any volume actions - attach, expunge, extract, etc.
The existing behaviour is upon on destroy of VM (having datadisks) and data
disks are not selected to delete, then during VM destroy these disks are still
marked as attached to VM. Only during VM expunge of VM these volumes are
detached from the VM.
Existing behaviour:
- When destroy VM without expunge and when no data disk is selected for
deletion
VM is stopped and data disks will still shown as attached to
original VM
When tried to recover the VM, the VM is made ready along with its
data disks as before.
- When destroy VM without expunge and when one or more data disks are
selected for deletion
VM is stopped and data disks which are selected for deletion will
be deleted and other data disks will still remain attached
When tried to recover the VM, the VM is made ready along with
remaining data disks which are not deleted
- When destroy VM with expunge and when no data disk is selected for deletion
All data disks are detached from VM
VM will be destroyed and expunged completely
- When destroy VM with expunge and few data disks are selected for deletion
Data disks marked for deletion are deleted and the remaining disks
are detached from VM
VM will be destroyed and expunged completely.
Expected behaviour after improvement
- When destroy VM with expunge or without expunge and no data disk is
selected for deletion
Data disks will be detached from VM during destroy VM itself
##### ISSUE TYPE
<!-- Pick one below and delete the rest -->
* Bug Report
* Improvement Request
* Enhancement Request
* Feature Idea
* Documentation Report
* Other
##### COMPONENT NAME
<!--
Categorize the issue, e.g. API, VR, VPN, UI, etc.
-->
~~~
~~~
##### CLOUDSTACK VERSION
<!--
New line separated list of affected versions, commit ID for issues on master
branch.
-->
~~~
~~~
##### CONFIGURATION
<!--
Information about the configuration if relevant, e.g. basic network,
advanced networking, etc. N/A otherwise
-->
##### OS / ENVIRONMENT
<!--
Information about the environment if relevant, N/A otherwise
-->
##### SUMMARY
<!-- Explain the problem/feature briefly -->
##### STEPS TO REPRODUCE
<!--
For bugs, show exactly how to reproduce the problem, using a minimal
test-case. Use Screenshots if accurate.
For new features, show how the feature would be used.
-->
<!-- Paste example playbooks or commands between quotes below -->
~~~
~~~
<!-- You can also paste gist.github.com links for larger files -->
##### EXPECTED RESULTS
<!-- What did you expect to happen when running the steps above? -->
~~~
~~~
##### ACTUAL RESULTS
<!-- What actually happened? -->
<!-- Paste verbatim command output between quotes below -->
~~~
~~~
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]