matheusfontes opened a new issue, #6717:
URL: https://github.com/apache/cloudstack/issues/6717
<!--
Verify first that your issue/request is not already reported on GitHub.
Also test if the latest release and main branch are affected too.
Always add information AFTER of these HTML comments, but no need to delete
the comments.
-->
##### ISSUE TYPE
<!-- Pick one below and delete the rest -->
* Bug Report
##### COMPONENT NAME
<!--
Categorize the issue, e.g. API, VR, VPN, UI, etc.
-->
~~~
usage
~~~
##### CLOUDSTACK VERSION
<!--
New line separated list of affected versions, commit ID for issues on main
branch.
-->
~~~
4.16 and 4.17
~~~
##### CONFIGURATION
<!--
Information about the configuration if relevant, e.g. basic network,
advanced networking, etc. N/A otherwise
-->
N/A
##### OS / ENVIRONMENT
<!--
Information about the environment if relevant, N/A otherwise
-->
centos 7
##### SUMMARY
<!-- Explain the problem/feature briefly -->
Usage never set volume as deleted and when volume is resized, it is charge
twice (or more)
##### 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 -->
~~~
Cenario 1:
Create a volume and attach it on vm.
Remove volume.
It will be charged forever
Cenario 2:
Create a volume and attach it on vm.
Resive volume.
It will be charged for many times that you resize it
~~~
<!-- You can also paste gist.github.com links for larger files -->
##### EXPECTED RESULTS
<!-- What did you expect to happen when running the steps above? -->
~~~
Stop to charge volume when it is removed.
~~~
##### ACTUAL RESULTS
<!-- What actually happened? -->
<!-- Paste verbatim command output between quotes below -->
~~~
Volume is being charged when it is removed or being charged more than 24
hours.
# > list usagerecords domainid=8e1c4859-9cf4-4414-a218-160b05b9f157
accountid=3e64effb-12a6-4642-95f9-c217c804a3c4 type=6 startdate=2020-01-19
enddate=2020-01-19
{
"account": "21150",
"accountid": "3e64effb-12a6-4642-95f9-c217c804a3c4",
"description": "Volume usage for DATA-600
(40f8412b-65f5-4c2d-a6e3-00a4e0456279) with disk offering Disco Magnético
(34573d38-2dce-4d8b-a0b4-80ad61b1cbc8) and size (1000.00 GB) 1073741824000",
"domain": "skycloud.prv",
"domainid": "8e1c4859-9cf4-4414-a218-160b05b9f157",
"enddate": "2020-01-19'T'23:59:59-03:00",
"offeringid": "34573d38-2dce-4d8b-a0b4-80ad61b1cbc8",
"rawusage": "48",
"size": 1073741824000,
"startdate": "2020-01-19'T'00:00:00-03:00",
"tags": [],
"usage": "48 Hrs",
"usageid": "40f8412b-65f5-4c2d-a6e3-00a4e0456279",
"usagetype": 6,
"zoneid": "74c526f8-52a2-4e2e-8d08-76eae35913a4"
},
~~~
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]