From: Sage Weil Date: Fri, 27 Apr 2018 22:32:38 +0000 (-0500) Subject: ceph_test_rados_api_aio: fix race with full pool and osdmap X-Git-Tag: v12.2.6~164^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=5b0440ec417baa9eb509819ab3e278e22605fede;p=ceph.git ceph_test_rados_api_aio: fix race with full pool and osdmap We send ops until we get a EDQUOT, and then assert our next op to a different object also gets EDQUOT. However, if the second osd doesn't have as new a map it may succeed. Make sure the client has the latest (mon) map, and thus the one marking the pool full, before we send the second op. That ensures the second OSD also has that newer map and also returns EDQUOT. Fixes: http://tracker.ceph.com/issues/23917 Signed-off-by: Sage Weil (cherry picked from commit 5e067b9dcf9bcccd9a1c0153d94818dccf6a0f71) --- diff --git a/src/test/librados/aio.cc b/src/test/librados/aio.cc index d795b84683f..14262259738 100644 --- a/src/test/librados/aio.cc +++ b/src/test/librados/aio.cc @@ -235,6 +235,9 @@ TEST(LibRadosAio, PoolQuotaPP) { } ASSERT_LT(n, 1024); + // make sure we have latest map that marked the pool full + test_data.m_cluster.wait_for_latest_osdmap(); + // make sure we block without FULL_TRY { ObjectWriteOperation op;