Description of problem: ======================== while creating volume using create_vol.sh, it is not doing all validation in begining. e.g. if brick count is not multiple of replica count it should exit script before running any gluster command rather than giving error later Version-Release number of selected component (if applicable): ============================================================= gluster - 3.6.0.20-1.el6rhs.x86_64 rhs-hadoop:- rhs-hadoop-install-1_20-1.el6rhs.noarch rhs-hadoop-2.3.2-2.noarch How reproducible: ================== always Steps to Reproduce: =================== 1. give even no of brick /usr/share/rhs-hadoop-install/create_vol.sh vol /mnt/gfs --debug rhs-gp-srv7.lab.eng.blr.redhat.com:/bk1 rhs-gp-srv4.lab.eng.blr.redhat.com:/bk1 rhs-gp-srv7.lab.eng.blr.redhat.com:/bk2 ... ... Creating new volume vol. Continue? [y|N] y --- creating the new vol volume... DEBUG: bricks: rhs-gp-srv7.lab.eng.blr.redhat.com:/bk1/vol rhs-gp-srv4.lab.eng.blr.redhat.com:/bk1/vol rhs-gp-srv7.lab.eng.blr.redhat.com:/bk2/vol ERROR 1: gluster vol create vol rhs-gp-srv7.lab.eng.blr.redhat.com:/bk1/vol rhs-gp-srv4.lab.eng.blr.redhat.com:/bk1/vol rhs-gp-srv7.lab.eng.blr.redhat.com:/bk2/vol : number of bricks is not a multiple of replica count Usage: volume create <NEW-VOLNAME> [stripe <COUNT>] [replica <COUNT>] [transport <tcp|rdma|tcp,rdma>] <NEW-BRICK>?<vg_name>... [force] ... ... Actual results: ============== It throws error when volume create command is giving error Expected results: ================= It's better to do all validation in begining and throw error when even no of bricks are supplied rather than waiting for gluster command to give error Additional info:
fixed in 1.28
added to 1.28
Tested with: rhs-hadoop-install-1_34-1.el6rhs.noarch Results: I got installed machine from beaker with only setup_common runned. Then I proceeded by our hadoop installation and configuration guide to point 3. I runned create_vol.sh as mentioned in BZ description. ./create_vol.sh vol /mnt/glusterfs --debug mrg-qe-vm-c2-201.lab.eng.brq.redhat.com:/mnt/brick1 mrg-qe-vm-c2-301.lab.eng.brq.redhat.com:/mnt/brick1 mrg-qe-vm-c2-201.lab.eng.brq.redhat.com:/mnt/brick2 It resulted in this output: *** *** create_vol: version 1.34 *** ERROR: the number of bricks must be a multiple of the replica, which is 2 This indicates, that error is handled without running gluster command. I also found code in create_vol.sh that handles this error. This issue is fixed -> VERIFIED.
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://rhn.redhat.com/errata/RHEA-2014-1275.html