lvm filter not generated correclty on rhel7

Bug #1425839 reported by Andreas Scheuring
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
devstack
Fix Released
Undecided
Ian Wienand

Bug Description

Since [1] filters for lvm are set up in /etc/cinder/lvm.conf file. The filter generation works fine on ubuntu, but on a rhel 7 (on x86 & s390) thing go wrong

Ubuntu generated filter:
filter = [ "a/dev/loop0/", "r/.*/" ]

RHEL7 generated filter
filter = [ "a/dev/loop0 stack-volumes-default/", "a/dev/loop1 stack-volumes-lvmdriver-1/", "r/.*/" ]

--> the rhel7 filter just does not make any sense. Seems like an error when parsing some input.

Root Cause (Example):
     IFS=';' read pv vg <<< $pv_info
rhel doesn't interpret the argument after the <<< operator as a single String
--> Solution: use quotation marks for the string argument: ... <<< "$pv_info"

[1] https://github.com/openstack-dev/devstack/commit/0b9e76f280208b5b5ad54bb6fbc4133e63037286

description: updated
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to devstack (master)

Fix proposed to branch: master
Review: https://review.openstack.org/159366

Changed in devstack:
assignee: nobody → Andreas Scheuring (andreas-scheuring)
status: New → In Progress
Changed in devstack:
assignee: Andreas Scheuring (andreas-scheuring) → Ian Wienand (iwienand)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to devstack (master)

Reviewed: https://review.openstack.org/159366
Committed: https://git.openstack.org/cgit/openstack-dev/devstack/commit/?id=15d40a56832baadc65fe5261f5f53ce24ad00e84
Submitter: Jenkins
Branch: master

commit 15d40a56832baadc65fe5261f5f53ce24ad00e84
Author: Andreas Scheuring <email address hidden>
Date: Thu Feb 26 09:08:09 2015 +0100

    Add quotation marks to parse string correclty on rhel7

    Problem:
    On rhel7 the lvm.conf filter is generated wrongly

    Root Cause:

    bash-4.2 (rhel7/centos7) incorrectly splits herestrings
    when combined with IFS. See [1] and [2]

    Quoting the argument is a safe work-around

    [1] http://stackoverflow.com/questions/20144593/trying-to-split-a-string-into-two-variables
    [2] https://bugzilla.redhat.com/show_bug.cgi?id=1196566

    Closes-Bug #1425839
    Change-Id: Ie82fcd7ef0deacbb6aaf18c5c466a5d5baf52681

Changed in devstack:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.