common: use boost::shared_mutex on Windows#46989
Conversation
|
We used this simple test to reproduce this issue and validate the fix: https://github.com/ceph/ceph/blob/main/qa/workunits/windows/test_rbd_wnbd.py Preliminary test results look fine: we're no longer experiencing deadlocks after switching to |
|
I tested this patch on top of Quincy (with more than 15k RBD volumes tested), and the deadlocks never reproduced. So, I can confirm that the fix is working. Moreover, I tried to benchmark the performance impact of this change, and here are the results: There are 5 consecutive runs of 1k RBD volumes. The results seems to be the same (excepting a small difference, which is not likely due to this patch). So, I would say that there is no performance impact with this fix. |
The winpthreads shared mutex implementation causes deadlocks on Windows [1][2]. Specifically, async RBD IO calls are hanging. This also prevents the images from being unmounted. For this reason, we're switching to boost::shared_mutex when using MinGW. [1] cloudbase/wnbd#63 (comment) [2] msys2/MINGW-packages#3319 Trace: https://pastebin.com/raw/i3jpTyS3 Fixes: https://tracker.ceph.com/issues/56480 Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
1bb3ded to
35b67b2
Compare
|
jenkins test windows |
|
jenkins test make check |
|
jenkins test windows The windows job failed with a different error now, a test timeout. It's probably just a flaky test: |
|
jenkins test windows |
|
jenkins test make check arm64 |
1 similar comment
|
jenkins test make check arm64 |

common: use boost::shared_mutex on Windows
The winpthreads shared mutex implementation causes deadlocks on
Windows [1][2]. Specifically, async RBD IO calls are hanging. This
also prevents the images from being unmounted.
For this reason, we're switching to boost::shared_mutex when using
MinGW.
[1] cloudbase/wnbd#63 (comment)
[2] msys2/MINGW-packages#3319
Trace: https://pastebin.com/raw/i3jpTyS3
Fixes: https://tracker.ceph.com/issues/56480
Signed-off-by: Lucian Petrut lpetrut@cloudbasesolutions.com
Checklist
Show available Jenkins commands
jenkins retest this pleasejenkins test classic perfjenkins test crimson perfjenkins test signedjenkins test make checkjenkins test make check arm64jenkins test submodulesjenkins test dashboardjenkins test dashboard cephadmjenkins test apijenkins test docsjenkins render docsjenkins test ceph-volume alljenkins test ceph-volume toxjenkins test windows