Bug 764797 (GLUSTER-3065) - make sure the export directories are not re-used as part of another volume
Summary: make sure the export directories are not re-used as part of another volume
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: GLUSTER-3065
Product: GlusterFS
Classification: Community
Component: core
Version: mainline
Hardware: x86_64
OS: Linux
medium
high
Target Milestone: ---
Assignee: Amar Tumballi
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-06-21 08:31 UTC by Amar Tumballi
Modified: 2015-12-01 16:45 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:


Attachments (Terms of Use)

Description Amar Tumballi 2011-06-21 08:31:49 UTC
issues today:

* create a simple 'stripe' volume with 2 bricks, call it 'test'.
* start the volume
* mount client, start populating data.
* umount client.
* stop and delete volume
* now create volume with same bricks (can be any name), but with 'replica' type.
* start the volume, mount the client
* now because exports already had striped data, client side 'cluster/replicate' gets confused. and this case is hard to debug as there is no info whether that export was re-used one or the freshly created one.

--> to fix, make sure a given export belongs to only one volume as long as the export directory exists.

Comment 1 Anand Avati 2011-06-24 01:31:09 UTC
PATCH: http://patches.gluster.com/patch/7619 in master (bring in strict check on export directory being re-used for different volume)

Comment 2 Anand Avati 2011-07-14 05:02:00 UTC
PATCH: http://patches.gluster.com/patch/7837 in master (storage/posix: make sure we are starting on a genuine backend)

Comment 3 Saurabh 2011-07-25 06:02:07 UTC
i have verified this bug, and the new fix works fine,

But I have a question that this fix can be deterrent to customers, who want to convert from a distribute to a distribute-replicate volume. Are we going to give them some workaround to do that kind of conversion?


############logs of verification of the bug #####################


[root@centos-qa-client-2 ~]# /opt/glusterfs/git_inst//sbin/gluster volume create dist1 10.1.12.134:/mnt/dist 10.1.12.135:/mnt/dist
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: /usr/local/bin/python: No such file or directory
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: exec: /usr/local/bin/python: cannot execute: No such file or directory
Creation of volume dist1 has been successful. Please start the volume to access data.
[root@centos-qa-client-2 ~]# /opt/glusterfs/git_inst//sbin/gluster start dist1
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: /usr/local/bin/python: No such file or directory
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: exec: /usr/local/bin/python: cannot execute: No such file or directory
unrecognized word: start (position 0)
[root@centos-qa-client-2 ~]# 
[root@centos-qa-client-2 ~]# 
[root@centos-qa-client-2 ~]# /opt/glusterfs/git_inst//sbin/gluster volume start dist1
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: /usr/local/bin/python: No such file or directory
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: exec: /usr/local/bin/python: cannot execute: No such file or directory
Starting volume dist1 has been successful
[root@centos-qa-client-2 ~]#  /opt/glusterfs/git_inst//sbin/gluster volume stop dist1 
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: /usr/local/bin/python: No such file or directory
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: exec: /usr/local/bin/python: cannot execute: No such file or directory
Stopping volume will make its data inaccessible. Do you want to continue? (y/n) y
Stopping volume dist1 has been successful
[root@centos-qa-client-2 ~]#  /opt/glusterfs/git_inst//sbin/gluster volume delete dist1 
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: /usr/local/bin/python: No such file or directory
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: exec: /usr/local/bin/python: cannot execute: No such file or directory
Deleting volume will erase all information about the volume. Do you want to continue? (y/n) y
Deleting volume dist1 has been successful
[root@centos-qa-client-2 ~]# 
[root@centos-qa-client-2 ~]# 
[root@centos-qa-client-2 ~]# /opt/glusterfs/git_inst//sbin/gluster volume create dist2 10.1.12.134:/mnt/dist 10.1.12.135:/mnt/dist
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: /usr/local/bin/python: No such file or directory
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: exec: /usr/local/bin/python: cannot execute: No such file or directory
'10.1.12.134:/mnt/dist' has been part of a deleted volume with id 74b7de2f-ba0b-4fd7-acc0-c58556430b37. Please re-create the brick directory.
[root@centos-qa-client-2 ~]# 
[root@centos-qa-client-2 ~]# /opt/glusterfs/git_inst//sbin/gluster volume create dist1 10.1.12.134:/mnt/dist 10.1.12.135:/mnt/dist
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: /usr/local/bin/python: No such file or directory
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: exec: /usr/local/bin/python: cannot execute: No such file or directory
'10.1.12.134:/mnt/dist' has been part of a deleted volume with id 74b7de2f-ba0b-4fd7-acc0-c58556430b37. Please re-create the brick directory.
[root@centos-qa-client-2 ~]# rmdir /mnt/dist
[root@centos-qa-client-2 ~]# mkdir /mnt/dist1
[root@centos-qa-client-2 ~]# /opt/glusterfs/git_inst//sbin/gluster volume create dist1 10.1.12.134:/mnt/dist1 10.1.12.135:/mnt/dist
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: /usr/local/bin/python: No such file or directory
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: exec: /usr/local/bin/python: cannot execute: No such file or directory
'10.1.12.135:/mnt/dist' has been part of a deleted volume with id 74b7de2f-ba0b-4fd7-acc0-c58556430b37. Please re-create the brick directory.
[root@centos-qa-client-2 ~]# ssh root.12.135 "rmdir /mnt/dist"
root.12.135's password: 
[root@centos-qa-client-2 ~]# ssh root.12.135 "mkdir /mnt/dist"
root.12.135's password: 
[root@centos-qa-client-2 ~]# /opt/glusterfs/git_inst//sbin/gluster volume create dist1 10.1.12.134:/mnt/dist1 10.1.12.135:/mnt/dist
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: /usr/local/bin/python: No such file or directory
/opt/glusterfs/git_inst//libexec/glusterfs/gsyncd: line 52: exec: /usr/local/bin/python: cannot execute: No such file or directory
Creation of volume dist1 has been successful. Please start the volume to access data.


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