Bug 810089 - glusterd remove brick does not close the unix domain sockets.
Summary: glusterd remove brick does not close the unix domain sockets.
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: glusterd
Version: mainline
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
Assignee: Kaushal
QA Contact: shylesh
URL:
Whiteboard:
Depends On:
Blocks: 817967
TreeView+ depends on / blocked
 
Reported: 2012-04-05 06:26 UTC by Raghavendra G
Modified: 2015-12-01 16:45 UTC (History)
3 users (show)

Fixed In Version: glusterfs-3.4.0
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-07-24 17:13:06 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)
glusterd log file (4.61 MB, application/x-gzip)
2012-04-05 06:26 UTC, Raghavendra G
no flags Details

Description Raghavendra G 2012-04-05 06:26:29 UTC
Created attachment 575293 [details]
glusterd log file

Description of problem:

After remove-brick glusterd doesn't close the unix-domain sockets. It appears (from the series of netstat outputs given below) as though it closes the sockets but reacquires them.

root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
1

root@booradley:~# while true; do gluster volume add-brick replica booradley:/home/export/repl-$i;  export i=$(($i + 1)); sleep 30; done
Add Brick successful
^C
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
4
root@booradley:~#  gluster volume remove-brick replica booradley:/home/export/repl-65
Removing brick(s) can result in data loss. Do you want to Continue? (y/n) y
Remove Brick successful
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
3
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
4
root@booradley:~#  gluster volume add-brick replica booradley:/home/export/repl-3
Add Brick successful
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
5
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
6
root@booradley:~# gluster volume remove-brick replica booradley:/home/export/repl-3
Removing brick(s) can result in data loss. Do you want to Continue? (y/n) y
Remove Brick successful

root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
2
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
3
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
5
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
6

root@booradley:~# gluster volume add-brick replica booradley:/home/export/repl-4
Add Brick successful
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
8
root@booradley:~# gluster volume remove-brick replica booradley:/home/export/repl-4
Removing brick(s) can result in data loss. Do you want to Continue? (y/n) y
Remove Brick successful
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
5
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
7
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
8
root@booradley:~# gluster volume add-brick replica booradley:/home/export/repl-3
Add Brick successful
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
6
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
10

root@booradley:~# gluster volume remove-brick replica booradley:/home/export/repl-3
Removing brick(s) can result in data loss. Do you want to Continue? (y/n) y
Remove Brick successful
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
9
root@booradley:~# netstat -nap | grep -i glusterd | grep unix | wc -l
10


And in glusterd log files, I am seeing following errors:

[2012-04-05 11:43:29.115905] E [glusterd-utils.c:1297:glusterd_brick_unlink_socket_file] 0-glusterd: Failed to remove /tmp/ca3e5f544d226f222f5e841579aa616c.socket error:
 Resource temporarily unavailable

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


How reproducible:


Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:

Comment 1 Anand Avati 2012-04-24 01:55:30 UTC
CHANGE: http://review.gluster.com/3168 (glusterd,glusterfsd : Perform proper cleanup of connections and socket files) merged in master by Anand Avati (avati)

Comment 2 shishir gowda 2012-05-29 10:39:43 UTC
root@shishirng:~# gluster volume info
 
Volume Name: new
Type: Distribute
Volume ID: 72ea227e-91cd-4af9-b5b6-306989684562
Status: Started
Number of Bricks: 2
Transport-type: tcp
Bricks:
Brick1: sng:/export/dir1
Brick2: sng:/export/dir2

root@shishirng:~# netstat -nap | grep -i glusterd | grep unix | wc -l
4

root@shishirng:~# gluster volume remove-brick new sng:/export/dir2
Removing brick(s) can result in data loss. Do you want to Continue? (y/n) y
Remove Brick commit force successful

root@shishirng:~# netstat -nap | grep -i glusterd | grep unix | wc -l
3


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