diff options
author | Varun Shastry <vshastry@redhat.com> | 2013-11-29 14:49:33 +0530 |
---|---|---|
committer | Vijay Bellur <vbellur@redhat.com> | 2014-01-28 22:41:39 -0800 |
commit | d952c93588a2533a72efdff4f6853c5fa2dec766 (patch) | |
tree | 4e5c3dbc3c5cd1e04a5d0727f99c134948bba07b /extras | |
parent | 6cb2106c22e1ea3758ac63dc725b888470f5dd5a (diff) |
features/quota: Make grep search more accurately
The hook script was searching the info file for "features.quota" to know the
quota status (enable/disabled). When features.quota-deem-statfs the grep is not
accurate. Fixed this issue.
Change-Id: I4104a93c1c1e0ac9fd7ef7bfef993425ab50e651
BUG: 969461
Signed-off-by: Varun Shastry <vshastry@redhat.com>
Reviewed-on: http://review.gluster.org/6380
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Reviewed-on: http://review.gluster.org/6839
Diffstat (limited to 'extras')
-rwxr-xr-x | extras/hook-scripts/add-brick/pre/S28Quota-enable-root-xattr-heal.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/extras/hook-scripts/add-brick/pre/S28Quota-enable-root-xattr-heal.sh b/extras/hook-scripts/add-brick/pre/S28Quota-enable-root-xattr-heal.sh index 2580a4c5885..d5658e3c865 100755 --- a/extras/hook-scripts/add-brick/pre/S28Quota-enable-root-xattr-heal.sh +++ b/extras/hook-scripts/add-brick/pre/S28Quota-enable-root-xattr-heal.sh @@ -80,7 +80,7 @@ then fi ## Is quota enabled? -FLAG=`cat $GLUSTERD_WORKING_DIR/vols/$VOL_NAME/info | grep "^features.quota" \ +FLAG=`cat $GLUSTERD_WORKING_DIR/vols/$VOL_NAME/info | grep "^features.quota=" \ | awk -F'=' '{print $NF}'`; if [ "$FLAG" != "on" ] then @@ -88,7 +88,7 @@ then fi ## Is volume started? -FLAG=`cat $GLUSTERD_WORKING_DIR/vols/$VOL_NAME/info | grep "^status" \ +FLAG=`cat $GLUSTERD_WORKING_DIR/vols/$VOL_NAME/info | grep "^status=" \ | awk -F'=' '{print $NF}'`; if [ "$FLAG" != "1" ] then |