'Return size of an existing LV for manage_existing.'

def manage_existing_get_size(self, volume, existing_ref, is_snapshot=False):

    if ('source-name' not in existing_ref):
        reason = _('Reference    must    contain    source-name    element.')
        raise exception.ManageExistingInvalidReference(existing_ref=existing_ref, reason=reason)
    lv_name = existing_ref['source-name']
    try:
        vol_obj = self.client.req('volumes', name=lv_name)['content']
    except exception.NotFound:
        kwargs = {'existing_ref': lv_name, 'reason': (('Specified    logical    %s    does    not    exist.' % 'snapshot') if is_snapshot else 'volume')}
        raise exception.ManageExistingInvalidReference(**kwargs)
    lv_size = int(math.ceil((float(vol_obj['vol-size']) / units.Mi)))
    return lv_size
