Bug 1369697

Summary: rm -rf * failed with error "Directory not empty" while rebalance+lookup are in-progress
Product: Red Hat Gluster Storage Reporter: Prasad Desala <tdesala>
Component: distributeAssignee: Mohit Agrawal <moagrawa>
Status: CLOSED WONTFIX QA Contact: Prasad Desala <tdesala>
Severity: high Docs Contact:
Priority: low    
Version: rhgs-3.1CC: moagrawa, nbalacha, rhs-bugs, storage-qa-internal
Target Milestone: ---Keywords: ZStream
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: dht-rm-rf
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-04-16 18:16:14 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Prasad Desala 2016-08-24 07:38:51 UTC
Description of problem:
=======================
With infinite loop of lookups from mount point, added multiple bricks to a distributed replica volume and started rebalance with force option.
While rebalance and lookups are in-progress, started removing files and directories from the mount point using "rm -rf *". 
Removing data failed for few files and directories with error "Directory not empty".

Version-Release number of selected component (if applicable):
=============================================================
3.7.9-10.el7rhgs.x86_64

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

Steps to Reproduce:
===================
1. create and mount Dist-rep volume. 
2. create files and Directories on it. In my case, i untarred linux kernel package.
3. From mount, keep sending continuous lookups.
4. add new bricks to that volume.
5. start rebalance with start force option.
6. While rebalance and lookups are in-progress, from mount point start deleting data using rm -rf *.

Actual results:
===============
File/Directory deletion is failing with error "Directory not empty".

Expected results:
================
rm -rf should not fail with such error if all sub-volumes were up.