Skip to content
Snippets Groups Projects
Unverified Commit dbd94a12 authored by Zexi Li's avatar Zexi Li Committed by GitHub
Browse files

Merge pull request #14417 from ioito/automated-cherry-pick-of-#14415-upstream-release-3.8

Automated cherry pick of #14415: fix(host): ceph pool size
parents 1a7ad830 f66242d7
No related branches found
No related tags found
No related merge requests found
......@@ -164,6 +164,9 @@ func (self *CephClient) GetCapacity() (*SCapacity, error) {
for _, pool := range stats.Pools {
if pool.Name == self.pool {
result.UsedCapacitySizeKb = int64(pool.Stats.KbUsed)
if pool.Stats.MaxAvail > 0 {
result.CapacitySizeKb = int64(pool.Stats.MaxAvail / 1024)
}
}
}
if result.CapacitySizeKb == 0 {
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment