Bug 1122886 - DHT :- If mkdir is in progress (completed only on hashed) and lookup from another mount point race with it, due to selfhealing mkdir will give 'I/IO error' even though Directory is creation is done
Summary: DHT :- If mkdir is in progress (completed only on hashed) and lookup from ano...
Alias: None
Product: Red Hat Gluster Storage
Classification: Red Hat
Component: distribute
Version: rhgs-3.0
Hardware: x86_64
OS: Linux
Target Milestone: ---
: RHGS 3.0.3
Assignee: Susant Kumar Palai
QA Contact: amainkar
Depends On: 1114010 1114557
Blocks: 1162694
TreeView+ depends on / blocked
Reported: 2014-07-24 10:03 UTC by Rachana Patel
Modified: 2015-05-13 17:41 UTC (History)
6 users (show)

Fixed In Version: glusterfs-
Doc Type: Bug Fix
Doc Text:
Previously, if a mkdir sees EEXIST [as a result of lookup and mkdir race] on a non-hashed subvolume, it reports I/O error to the application. With this fix, if the mkdir is successful on the hashed subvolume, then no error is propagated to the client.
Clone Of:
Last Closed: 2015-01-15 13:38:55 UTC

Attachments (Terms of Use)

System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:0038 normal SHIPPED_LIVE Red Hat Storage 3.0 enhancement and bug fix update #3 2015-01-15 18:35:28 UTC

Description Rachana Patel 2014-07-24 10:03:03 UTC
Description of problem:
Create Directory from mount point and while creation is in progress (Directory created only on hashed sub-volume), execute lookup from another mount point 

i.e. from one mout point :- 

[root@OVM1 nfs]# mkdir 3

from another mount point:- ls

Directory creation gives error "mkdir: cannot create directory `3': Input/output error" eventhough Directory is created on all up sub-volumes.

Version-Release number :

How reproducible:

Steps to Reproduce:
1. create and mount distributed volume. (mount on multiple client)
2. from one mount point give mkdir and make sure when Directory is create donly on hashed issue lookup

[root@OVM3 ~]# tree /brick*
├── r1
│   ├── 1
│   ├── 2
│   └── 3
├── r2
│   ├── 1
│   └── 2
└── r3
    ├── 1
    └── 2

10 directories, 0 files

now lookup should come

3. Directory creation fails with 'I/O error' but Directory is present on all up sub-volume

[root@OVM1 nfs]# mkdir 3
mkdir: cannot create directory `3': Input/output error

[root@OVM3 ~]# tree /brick*
├── r1
│   ├── 1
│   ├── 2
│   └── 3
├── r2
│   ├── 1
│   ├── 2
│   └── 3
└── r3
    ├── 1
    ├── 2
    └── 3

12 directories, 0 files

Actual results:
- mkdir fails with error 'mkdir: cannot create directory `3': Input/output error'

Expected results:
- If Directory is created on all upp sub-volumes with same gfid, mkdir should nto give error

Comment 4 Amit Chaurasia 2014-12-17 07:50:37 UTC
I verified by tracing the calls in dht_mkdir and dht_mkdir_hashed_cbk functions while creating folders and performing ls from the mount points.

ls is able to perform healing without any errors or races.
mkdir is complete without any issues.

Marking the bug verified.

Comment 5 Divya 2014-12-30 08:44:44 UTC

Please review the edited doc text and sign-off.

Comment 6 Susant Kumar Palai 2014-12-30 09:21:32 UTC
Doc looks good to me.

Comment 8 errata-xmlrpc 2015-01-15 13:38:55 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.


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