From: James Simmons Date: Thu, 10 Jun 2021 16:53:57 +0000 (-0400) Subject: LU-14752 obdclass: handle EBUSY returned for lu_object hashtable X-Git-Tag: 2.14.53~87 X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=commitdiff_plain;h=285a29d3b5e47f63a94c0682040ddbf09614f130 LU-14752 obdclass: handle EBUSY returned for lu_object hashtable When the rhashtable grows to a certain size it will be rescaled. When rescaling you can be returned a ENOMEM or EBUSY error. This we reported as: LustreError: 3594004:0:(lu_object.c:2472:lu_object_assign_fid()) ASSERTION( rc == 0 ) failed: failed hashtable insertion: rc = -16 LustreError: 3594004:0:(lu_object.c:2472:lu_object_assign_fid()) LBUG Pid: 3594004, comm: mdt01_020 4.18.0-240.22.1.1toss.t4.x86_64 #1 SMP Tue Apr 13 17:18:40 PDT 2021 Call Trace TBD: Kernel panic - not syncing: LBUG ... Call Trace: dump_stack+0x5c/0x80 panic+0xe7/0x2a9 lbug_with_loc.cold.10+0x18/0x18 [libcfs] lu_object_assign_fid+0x3b8/0x3c0 [obdclass] Add handling the EBUSY case for our lu_object hash. Fixes: aff14dbc522 ("LU-8130 lu_object: convert lu_object cache to rhashtable") Change-Id: Id85f32633117e02850b799e8d95e3e35d982cbd4 Signed-off-by: James Simmons Reviewed-on: https://review.whamcloud.com/43968 Tested-by: jenkins Reviewed-by: Gian-Carlo DeFazio Tested-by: Maloo Reviewed-by: Andreas Dilger Reviewed-by: Neil Brown Reviewed-by: Oleg Drokin --- diff --git a/lustre/obdclass/lu_object.c b/lustre/obdclass/lu_object.c index 21ed4f3..b381cfe 100644 --- a/lustre/obdclass/lu_object.c +++ b/lustre/obdclass/lu_object.c @@ -2479,7 +2479,7 @@ try_again: /* supposed to be unique */ LASSERT(rc != -EEXIST); /* handle hash table resizing */ - if (rc == -ENOMEM) { + if (rc == -ENOMEM || rc == -EBUSY) { msleep(20); goto try_again; }