From: Mikhail Khodos Date: Mon, 5 Aug 2013 19:27:51 +0000 (-0700) Subject: Add support for volume extension to Nexenta Systems volume driver X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=955f0ebbd1f95e0b35b0ad982178ac8a847ab8d2;p=openstack-build%2Fcinder-build.git Add support for volume extension to Nexenta Systems volume driver Change-Id: Ie082076292825aaac69b0c5f8aa7351ce6ab9cb9 --- diff --git a/cinder/volume/drivers/nexenta/volume.py b/cinder/volume/drivers/nexenta/volume.py index fb1e94db0..ad22a1c59 100644 --- a/cinder/volume/drivers/nexenta/volume.py +++ b/cinder/volume/drivers/nexenta/volume.py @@ -128,6 +128,17 @@ class NexentaDriver(driver.ISCSIDriver): # pylint: disable=R0921 '%sG' % (volume['size'],), CONF.nexenta_blocksize, CONF.nexenta_sparse) + def extend_volume(self, volume, new_size): + """Extend an existing volume. + + :param volume: volume reference + :param new_size: volume new size in GB + """ + LOG.info(_('Extending volume: %(id)s New size: %(size)s GB'), + {'id': volume['id'], 'size': new_size}) + self.nms.zvol.set_child_prop(self._get_zvol_name(volume['name']), + 'volsize', '%sG' % new_size) + def delete_volume(self, volume): """Destroy a zvol on appliance.