[LU-6738] lfs fid2path with invalid fid triggers LBUG: lmv_fld_lookup()) ASSERTION( (fid_seq_in_fldb(fid_seq(fid)) || fid_seq_is_local_file(fid_seq(fid))) && fid_is_sane(fid) ) failed: [0x100190000:0x39b4fc:0x0] is insane! Created: 17/Jun/15 Updated: 27/Jul/17 Resolved: 27/Jul/17 |
|
| Status: | Closed |
| Project: | Lustre |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Minor |
| Reporter: | Patrick Farrell (Inactive) | Assignee: | WC Triage |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | patch | ||
| Severity: | 3 |
| Rank (Obsolete): | 9223372036854775807 |
| Description |
|
On file systems with more than one MDT, lmv_find_target calls lmv_fld_lookup, which sanity checks the provided fid... However, when this is called from lfs fid2path, the fid has not yet been sanity checked. As a result, passing an invalid fid in to fid2path causes an LBUG. This is present in any version of Lustre which supports multiple MDTs. The crash below is from a Cray system running 2.5, but the bug is present in current master. Run this command from a client on a file system with multiple MDTs: lfs fid2path /[fs_mount_point] [0x100190000:0x39b4b2:0x0] And it will LBUG: > 2015-06-11T18:11:48.877805+00:00 c1-0c0s1n1 LustreError: 20721:0:(lmv_fld.c:72:lmv_fld_lookup()) ASSERTION( (fid_seq_in_fldb(fid_seq(fid)) || fid_seq_is_local_file(fid_seq(fid))) && fid_is_sane(fid) ) failed: [0x100190000:0x39b4fc:0x0] is insane! The fix is straightforward - Sanity check the FID in ll_fid2path. Patch coming in a moment. |
| Comments |
| Comment by Gerrit Updater [ 17/Jun/15 ] |
|
Patrick Farrell (paf@cray.com) uploaded a new patch: http://review.whamcloud.com/15328 |
| Comment by Di Wang [ 17/Jun/15 ] |
|
Hmm, It seems this problem has been fixed in |
| Comment by Patrick Farrell (Inactive) [ 18/Jun/15 ] |
|
Oops - Thank you, Di, I missed that fix. Sloppy on my part. I still think it would be good to sanity check the fid immediately after we get it from userspace, in ll_fid2path, but there's no crash any more in master. Thanks for taking a look. |
| Comment by Patrick Farrell (Inactive) [ 27/Jul/17 ] |
|
Fixed elsewhere as noted by Di. |