Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

systempool_size doesn't consider spare capacity #1

Open
infernix opened this issue Dec 15, 2016 · 3 comments
Open

systempool_size doesn't consider spare capacity #1

infernix opened this issue Dec 15, 2016 · 3 comments

Comments

@infernix
Copy link

Example:

SDS Summary:
...
	990.0 GB (1013750 MB) total capacity
	647.3 GB (662829 MB) unused capacity
	16.0 GB (16384 MB) in-use capacity
	16.0 GB (16384 MB) protected capacity
...
	326.7 GB (334537 MB) spare capacity
	16.0 GB (16384 MB) at-rest capacity

systempool_size returns total 1013750mb, used 16384mb, free 997366mb.

So the calculation total-used=free is off since spare capacity cannot be considered allocateable (e.g. free) space.

@infernix
Copy link
Author

Here's probably the better query for a valid value:

params = {'selectedStatisticsList': [{'type': 'System', 'allIds': '', 'properties': [ 'unusedCapacityInKb','capacityAvailableForVolumeAllocationInKb','spareCapacityInKb']}]}
req = cluster._post('/api/instances/querySelectedStatistics', params=params)

You can then either do total - used - spare to arrive at the same figure as unusedCapacityInKb, but probably a better figure to use for free space is capacityAvailableForVolumeAllocationInKb since you can never allocate more space than that.

@ftersin
Copy link
Contributor

ftersin commented Dec 16, 2016

Thanks. We'll deal with that soon.

@ftersin
Copy link
Contributor

ftersin commented Dec 23, 2016

Fixed in branches of https://github.com/codedellemc/python-scaleioclient (except master branch).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants