Bug 1224229 - BitRot :- If peer in cluster doesn't have brick then its should not start bitd on that node and should not create partial volume file
Summary: BitRot :- If peer in cluster doesn't have brick then its should not start bit...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Gluster Storage
Classification: Red Hat Storage
Component: bitrot
Version: rhgs-3.1
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: ---
: RHGS 3.1.0
Assignee: Gaurav Kumar Garg
QA Contact: RajeshReddy
URL:
Whiteboard:
: 1224154 (view as bug list)
Depends On:
Blocks: 1202842 1223636
TreeView+ depends on / blocked
 
Reported: 2015-05-22 11:08 UTC by RajeshReddy
Modified: 2016-09-17 14:23 UTC (History)
11 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of: 1207029
Environment:
Last Closed: 2015-07-29 04:51:04 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2015:1495 0 normal SHIPPED_LIVE Important: Red Hat Gluster Storage 3.1 update 2015-07-29 08:26:26 UTC

Description RajeshReddy 2015-05-22 11:08:49 UTC
+++ This bug was initially created as a clone of Bug #1207029 +++

Description of problem:
=======================
when peer doesn't have brick for volume and Admin enables BitRot for that volume, it starts bitd on that node and also generates volume file which is not complete


Version-Release number of selected component (if applicable):
=============================================================
0.803.gitf64666f.el6.x86_64

How reproducible:
=================
always

Steps to Reproduce:
===================
1. create a volume and make sure that one of the peer in cluster doesn't have any bricks on it
2. Enable BitRot for that volume.
3. check peer where brick is not present


[root@rhs-client38 ~]# tail -f /var/log/glusterfs/bitd.log 
[2015-03-26 09:09:06.033443] I [MSGID: 100030] [glusterfsd.c:2288:main] 0-/usr/sbin/glusterfs: Started running /usr/sbin/glusterfs version 3.7dev (args: /usr/sbin/glusterfs -s localhost --volfile-id gluster/bitd -p /var/lib/glusterd/bitd/run/bitd.pid -l /var/log/glusterfs/bitd.log -S /var/run/gluster/38ca86c29620f999da1ff58a74366ae5.socket)
[2015-03-26 09:09:06.045709] I [event-epoll.c:629:event_dispatch_epoll_worker] 0-epoll: Started thread with index 1
[2015-03-26 09:09:06.603114] E [graph.y:365:graphyyerror] 0-parser: syntax error: line 3 (volume 'bit-rot'): "end-volume"
allowed tokens are 'volume', 'type', 'subvolumes', 'option', 'end-volume'()
[2015-03-26 09:09:06.603198] E [MSGID: 100026] [glusterfsd.c:2142:glusterfs_process_volfp] 0-: failed to construct the graph
[2015-03-26 09:09:06.603381] W [glusterfsd.c:1212:cleanup_and_exit] (--> 0-: received signum (0), shutting down


[root@rhs-client38 ~]# cat /var/lib/glusterd/bitd/bitd-server.vol
volume bit-rot
    type features/bit-rot
end-volume


[root@rhs-client38 ~]# ps auxww | grep bitd
root     20690  0.0  0.0 103252   864 pts/2    S+   14:59   0:00 grep bitd

Actual results:
===============
bitd was started and partially created vol file is present

Expected results:
================
It should not start bitd and should not create vol file

Additional info:
================

--- Additional comment from Anand Avati on 2015-03-31 08:11:43 EDT ---

REVIEW: http://review.gluster.org/10071 (glusterd: bitd daemon should not start on the node which dont have any brick) posted (#1) for review on master by Gaurav Kumar Garg (ggarg)

--- Additional comment from Anand Avati on 2015-04-01 02:27:44 EDT ---

REVIEW: http://review.gluster.org/10071 (glusterd: bitd daemon should not start on the node which dont have any brick) posted (#2) for review on master by Gaurav Kumar Garg (ggarg)

--- Additional comment from Anand Avati on 2015-04-06 03:26:39 EDT ---

REVIEW: http://review.gluster.org/10071 (glusterd: bitd daemon should not start on the node which dont have any brick) posted (#3) for review on master by Gaurav Kumar Garg (ggarg)

--- Additional comment from Anand Avati on 2015-04-06 06:16:14 EDT ---

REVIEW: http://review.gluster.org/10071 (glusterd: bitd daemon should not start on the node which dont have any brick) posted (#4) for review on master by Gaurav Kumar Garg (ggarg)

--- Additional comment from Anand Avati on 2015-04-06 09:17:40 EDT ---

REVIEW: http://review.gluster.org/10071 (glusterd: bitd daemon should not start on the node which dont have any brick) posted (#5) for review on master by Niels de Vos (ndevos)

--- Additional comment from Anand Avati on 2015-04-07 02:30:59 EDT ---

REVIEW: http://review.gluster.org/10071 (glusterd: bitd daemon should not start on the node which dont have any brick) posted (#6) for review on master by Gaurav Kumar Garg (ggarg)

--- Additional comment from Anand Avati on 2015-04-09 08:00:02 EDT ---

REVIEW: http://review.gluster.org/10071 (glusterd: bitd daemon should not start on the node which dont have any brick) posted (#7) for review on master by Gaurav Kumar Garg (ggarg)

--- Additional comment from Anand Avati on 2015-04-10 03:00:29 EDT ---

REVIEW: http://review.gluster.org/10071 (glusterd: bitd daemon should not start on the node which dont have any brick) posted (#8) for review on master by Gaurav Kumar Garg (ggarg)

--- Additional comment from Anand Avati on 2015-04-10 06:13:49 EDT ---

COMMIT: http://review.gluster.org/10071 committed in master by Venky Shankar (vshankar) 
------
commit accd61fb64b96c4af47aa6cfa41adb0f2e47a60a
Author: GauravKumarGarg <ggarg>
Date:   Tue Mar 31 16:41:08 2015 +0530

    glusterd: bitd daemon should not start on the node which dont have any brick
    
    If user enable bitrot from node1 which have brick then glusterd starting
    bitd daemon on node1 as well as glusterd starting bitd deamon on another node2
    which does not have any brick (node1 and node2 are part of cluster).
    
    With this fix glusterd will not start bitd daemon on the node which
    don't have brick.
    
    Change-Id: Ic1c68d204221d369d89d628487cdd5957964792e
    BUG: 1207029
    Signed-off-by: Gaurav Kumar Garg <ggarg>
    Reviewed-on: http://review.gluster.org/10071
    Tested-by: Gluster Build System <jenkins.com>
    Reviewed-by: Atin Mukherjee <amukherj>
    Reviewed-by: Venky Shankar <vshankar>
    Tested-by: Venky Shankar <vshankar>

--- Additional comment from Anand Avati on 2015-04-15 02:20:06 EDT ---

REVIEW: http://review.gluster.org/10241 (glusterd: do not pass volinfo in glusterd_svc_manager function) posted (#1) for review on master by Gaurav Kumar Garg (ggarg)

--- Additional comment from Anand Avati on 2015-04-22 08:49:39 EDT ---

REVIEW: http://review.gluster.org/10241 (glusterd: do not pass volinfo in glusterd_svc_manager function) posted (#2) for review on master by Gaurav Kumar Garg (ggarg)

--- Additional comment from Anand Avati on 2015-04-23 03:03:15 EDT ---

REVIEW: http://review.gluster.org/10241 (glusterd: do not pass volinfo in glusterd_svc_manager function) posted (#3) for review on master by Gaurav Kumar Garg (ggarg)

--- Additional comment from Anand Avati on 2015-04-25 16:45:20 EDT ---

REVIEW: http://review.gluster.org/10241 (glusterd: do not pass volinfo in glusterd_svc_manager function) posted (#4) for review on master by Gaurav Kumar Garg (ggarg)

--- Additional comment from Anand Avati on 2015-04-27 02:07:10 EDT ---

REVIEW: http://review.gluster.org/10241 (glusterd: do not pass volinfo in glusterd_svc_manager function) posted (#5) for review on master by Gaurav Kumar Garg (ggarg)

--- Additional comment from Anand Avati on 2015-04-27 05:38:50 EDT ---

REVIEW: http://review.gluster.org/10241 (glusterd: do not pass volinfo in glusterd_svc_manager function) posted (#6) for review on master by Gaurav Kumar Garg (ggarg)

--- Additional comment from Anand Avati on 2015-04-30 05:44:05 EDT ---

COMMIT: http://review.gluster.org/10241 committed in master by Krishnan Parthasarathi (kparthas) 
------
commit 7648c0de36c7927b588abc66734c5b94afb08c00
Author: Gaurav Kumar Garg <ggarg>
Date:   Wed Apr 15 11:37:22 2015 +0530

    glusterd: do not pass volinfo in glusterd_svc_manager function
    
    On restarting of glusterd first it will start all the bricks present
    in the volume then it will start all the services. During starting of
    all the services it may pass volinfo as a NULL. It will cause Assert
    failure in glusterd_bitdsvc_manager function and will cause a glusterd
    crash.
    
    Change-Id: Ia14cf5022da88516cdd576eb2d1e0e7b17a3782b
    BUG: 1207029
    Signed-off-by: Gaurav Kumar Garg <ggarg>
    Reviewed-on: http://review.gluster.org/10241
    Tested-by: Gluster Build System <jenkins.com>
    Reviewed-by: Atin Mukherjee <amukherj>
    Reviewed-by: Krishnan Parthasarathi <kparthas>
    Tested-by: Krishnan Parthasarathi <kparthas>

--- Additional comment from Anand Avati on 2015-05-01 03:50:18 EDT ---

REVIEW: http://review.gluster.org/10481 (glusterd: do not pass volinfo in glusterd_svc_manager function) posted (#1) for review on release-3.7 by Gaurav Kumar Garg (ggarg)

--- Additional comment from RajeshReddy on 2015-05-15 04:24:59 EDT ---

Tested with build glusterfs-3.7.0beta2, Bitrot is not enabled if brick is not part of volume so closing the bug

Comment 2 Gaurav Kumar Garg 2015-06-05 11:13:59 UTC
commit accd61fb64b96c4af47aa6cfa41adb0f2e47a60a
   will solve this problem. patch for this patch already available in rhgs-3.1 branch so moving status of this bug ON_QA

Comment 3 Venky Shankar 2015-06-05 12:08:29 UTC
*** Bug 1224154 has been marked as a duplicate of this bug. ***

Comment 4 RajeshReddy 2015-06-08 10:55:05 UTC
Tested with glusterfs-fuse-3.7.0-3 and reported problem is not seen so marking this bug as verified

Comment 5 errata-xmlrpc 2015-07-29 04:51:04 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://rhn.redhat.com/errata/RHSA-2015-1495.html


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