Dell EMC PS: Fix over-subscription ratio stats

Fixed the provisioned_capacity_gb to use the VolumeReportedSpace
to calculate the over-subscription ratio stats in the Dell EMC
PS volume driver.

Closes Bug: #1719659

Change-Id: I2caa5f2763ec343b0bc875e707924ff9b6424ce5
This commit is contained in:
rajinir 2017-09-26 10:12:23 -05:00
parent ec650aa2c8
commit 761f0c3e66
3 changed files with 9 additions and 3 deletions

View File

@ -58,7 +58,7 @@ class PSSeriesISCSIDriverTestCase(test.TestCase):
self.driver_stats_output = ['TotalCapacity: 111GB',
'FreeSpace: 11GB',
'VolumeReserve: 80GB',
'VolumeReportedSpace: 80GB',
'TotalVolumes: 100']
self.cmd = 'this is dummy command'
self._context = context.get_admin_context()

View File

@ -137,10 +137,11 @@ class PSSeriesISCSIDriver(san.SanISCSIDriver):
1.4.1 - Rebranded driver to Dell EMC.
1.4.2 - Enable report discard support.
1.4.3 - Report total_volumes in volume stats
1.4.4 - Fixed over-subscription ratio calculation
"""
VERSION = "1.4.3"
VERSION = "1.4.4"
# ThirdPartySytems wiki page
CI_WIKI_NAME = "Dell_Storage_CI"
@ -315,7 +316,7 @@ class PSSeriesISCSIDriver(san.SanISCSIDriver):
if line.startswith('FreeSpace:'):
out_tup = line.rstrip().partition(' ')
data['free_capacity_gb'] = self._get_space_in_gb(out_tup[-1])
if line.startswith('VolumeReserve:'):
if line.startswith('VolumeReportedSpace:'):
out_tup = line.rstrip().partition(' ')
provisioned_capacity = self._get_space_in_gb(out_tup[-1])
if line.startswith('TotalVolumes:'):

View File

@ -0,0 +1,5 @@
---
fixes:
- |
Dell EMC PS Driver stats report has been fixed, now reports the
`provisioned_capacity_gb` properly. Fixes bug 1719659.