[LU-5937] 'lfs find --size ...' fails to detect striped directories above a given size Created: 19/Nov/14  Updated: 01/Jul/16  Resolved: 07/Jul/15

Status: Resolved
Project: Lustre
Component/s: None
Affects Version/s: Lustre 2.7.0
Fix Version/s: Lustre 2.8.0

Type: Bug Priority: Major
Reporter: John Hammond Assignee: John Hammond
Resolution: Fixed Votes: 0
Labels: dne2

Severity: 3
Rank (Obsolete): 16576

 Description   

The supporting code for lfs find implicitly assumes a regular file in a few places. See the LL_IOC_LOV_GETSTRIPE, LL_IOC_MDC_GETINFO, IOC_MDC_GETFILEINFO, IOC_MDC_GETFILESTRIPE case of ll_dir_ioctl() where we return the attributes of the master inode

q:lustre# mkdir d0
q:lustre# lfs mkdir -c4 d1
q:lustre# touch d0/f{0..4095} d1/f{0..4095}
q:lustre# stat d0 d1
  File: `d0'
  Size: 184320    	Blocks: 368        IO Block: 4096   directory
Device: 2c54f966h/743766374d	Inode: 180144002274699275  Links: 2
Access: (0755/drwxr-xr-x)  Uid: (    0/    root)   Gid: (    0/    root)
Access: 2014-11-19 11:19:46.000000000 -0600
Modify: 2014-11-19 11:20:24.000000000 -0600
Change: 2014-11-19 11:20:24.000000000 -0600
  File: `d1'
  Size: 212992    	Blocks: 8          IO Block: 4096   directory
Device: 2c54f966h/743766374d	Inode: 180144002274699276  Links: 2
Access: (0755/drwxr-xr-x)  Uid: (    0/    root)   Gid: (    0/    root)
Access: 2014-11-19 11:19:53.000000000 -0600
Modify: 2014-11-19 11:20:37.000000000 -0600
Change: 2014-11-19 11:20:37.000000000 -0600
q:lustre# lfs find --size +1K .
.
./d0
./d1
q:lustre# lfs find --size +4K .
./d0


 Comments   
Comment by Jodi Levi (Inactive) [ 21/Nov/14 ]

Di,
Can you please have a look at this one?
Thank you!

Comment by Gerrit Updater [ 24/Nov/14 ]

wangdi (di.wang@intel.com) uploaded a new patch: http://review.whamcloud.com/12826
Subject: LU-5937 llite: merge attr for striped dir in dir_ioctl
Project: fs/lustre-release
Branch: master
Current Patch Set: 1
Commit: 47ea9738135f8e4227834094be3af65ee948854e

Comment by Gerrit Updater [ 19/Jan/15 ]

John L. Hammond (john.hammond@intel.com) uploaded a new patch: http://review.whamcloud.com/13456
Subject: LU-5937 lfs: ensure a valid directory size in lfs find
Project: fs/lustre-release
Branch: master
Current Patch Set: 1
Commit: ef16d531da708af9eb82b0b7f70a0320d65e937c

Comment by Gerrit Updater [ 03/Mar/15 ]

Oleg Drokin (oleg.drokin@intel.com) merged in patch http://review.whamcloud.com/13456/
Subject: LU-5937 lfs: ensure a valid directory size in lfs find
Project: fs/lustre-release
Branch: master
Current Patch Set:
Commit: 7d9c948c6016b10ed0d07e20cbd7925e108b3450

Comment by Peter Jones [ 07/Jul/15 ]

Landed for 2.8

Generated at Sat Feb 10 01:55:48 UTC 2024 using Jira 9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c.