Bug 1330426 - cache_meta_lv creation should be made optional for lvmcache configuration
Summary: cache_meta_lv creation should be made optional for lvmcache configuration
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Gluster Storage
Classification: Red Hat Storage
Component: gdeploy
Version: rhgs-3.1
Hardware: All
OS: Linux
unspecified
medium
Target Milestone: ---
: RHGS 3.1.3
Assignee: Nandaja Varma
QA Contact: SATHEESARAN
URL:
Whiteboard:
Depends On:
Blocks: 1311817
TreeView+ depends on / blocked
 
Reported: 2016-04-26 08:42 UTC by SATHEESARAN
Modified: 2016-07-04 01:12 UTC (History)
6 users (show)

Fixed In Version: gdeploy-2.0-13
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-06-23 05:30:25 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2016:1250 0 normal SHIPPED_LIVE gdeploy update for Red Hat Gluster Storage 3.1 update 3 2016-06-23 09:11:59 UTC

Description SATHEESARAN 2016-04-26 08:42:05 UTC
Description of problem:
-----------------------
lvmcache is created as follows :
1. Create cache_data_lv on SSD
2. Create cache_metadata_lv on SSD
3. Convert the lvs created in step1 & step2 as cache-pool
4. Attach the cache-pool to the thinpool

Currently gdeploy requires the creation of cache_metadata_lv manually.
But this cache_metadata_lv is created automatically based on the size of the cache_data_lv.

So this requirement should be made as optional

Version-Release number of selected component (if applicable):
-------------------------------------------------------------
gdeploy-2.0-6

How reproducible:
-----------------
Always

Steps to Reproduce:
-------------------
1. Create lvmcache using [setup-cache] section in conf file to gdeploy

Actual results:
---------------
cache_meta_lvsize is required

Expected results:
-----------------
cache_meta_lv creation should be skipped, unless the argument cache_meta_lvsize is mentioned in the conf file

Additional info:
----------------
Conf file used :

[lv5]
action=setup-cache
ssd=vdc
vgname=RHS_vg1
poolname=lvthinpool
cache_meta_lv=lvcachemeta
cache_lv=lvcache
cache_meta_lvsize=1GB      <---- should be optional
cache_lvsize=5GB

Comment 2 SATHEESARAN 2016-05-11 10:05:11 UTC
Tested with gdeploy-2.0-11

When cache_meta_lv is omitted in conf file, errors were seen.

TASK: [Setup SSD for caching | Convert an existing logical volume to a cache pool LV] *** 
fatal: [10.70.37.124] => One or more undefined variables: 'cache_meta_lv' is undefined
fatal: [10.70.37.204] => One or more undefined variables: 'cache_meta_lv' is undefined

FATAL: all hosts have already failed -- aborting


But the lv.json has marked the attribute 'cache_meta_lv' as a optional argument
The problem I think is there is no default name for "cache_meta_lv"

{
            "name": "cache_meta_lv",
            "required": "false",
            "default": ""
          },


Whereas the cache_lv has the default name as - "rhs_cache"

{
            "name": "cache_lv",
            "required": "false",
            "default": "rhs_cache"
          }


Also I recommend using 'rhgs' instead of 'rhs'

Comment 3 SATHEESARAN 2016-05-11 10:31:17 UTC
Removing the fixed-in-version as the fix failed verification

Comment 4 SATHEESARAN 2016-05-13 07:26:02 UTC
(In reply to SATHEESARAN from comment #2)
> The problem I think is there is no default name for "cache_meta_lv"
> 
> {
>             "name": "cache_meta_lv",
>             "required": "false",
>             "default": ""
>           },
> 
> 
> Whereas the cache_lv has the default name as - "rhs_cache"
> 
> {
>             "name": "cache_lv",
>             "required": "false",
>             "default": "rhs_cache"
>           }
> 
> 
> Also I recommend using 'rhgs' instead of 'rhs'

I was wrong about this statement.
The default value for cache_meta_lv is not required, as lv will automatically create it with the default name

Comment 5 SATHEESARAN 2016-05-25 07:28:56 UTC
Tested with gdeploy-2.0-16 and able to setup the lvmcache.

Comment 7 errata-xmlrpc 2016-06-23 05:30:25 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2016:1250


Note You need to log in before you can comment on or make changes to this bug.