From 17b174db287e450343e51051623e2fcaa792fef3 Mon Sep 17 00:00:00 2001 From: Original Author James Simmons Date: Thu, 10 Jun 2021 12:53:57 -0400 Subject: [PATCH] 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. Lustre-change: https://review.whamcloud.com/43968 Lustre-commit: 285a29d3b5e47f63a94c0682040ddbf09614f130 Fixes: aff14dbc522 ("LU-8130 lu_object: convert lu_object cache to rhashtable") Change-Id: Id85f32633117e02850b799e8d95e3e35d982cbd4 Test-Parameters: fortestonly Signed-off-by: James Simmons Signed-off-by: Gian-Carlo DeFazio Reviewed-on: https://review.whamcloud.com/44170 Tested-by: jenkins Reviewed-by: Oleg Drokin --- lustre/obdclass/lu_object.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lustre/obdclass/lu_object.c b/lustre/obdclass/lu_object.c index 8847a4e..d30a782 100644 --- a/lustre/obdclass/lu_object.c +++ b/lustre/obdclass/lu_object.c @@ -2460,7 +2460,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; } -- 1.8.3.1