Skip to content

Commit 693d7d4

Browse files
authored
Merge pull request ceph#61021 from NitzanMordhai/wip-nitzan-leak-some-memory-locks-hungs
memory lock issues causing hangs during connection shutdown Reviewed-by: Radoslaw Zarzynski <[email protected]>
2 parents 6275935 + b800149 commit 693d7d4

File tree

4 files changed

+7
-5
lines changed

4 files changed

+7
-5
lines changed

qa/suites/rados/valgrind-leaks/1-start.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ overrides:
2525
valgrind:
2626
mon: [--tool=memcheck, --leak-check=full, --show-reachable=yes]
2727
osd: [--tool=memcheck]
28+
stop-daemons-timeout: 1200
2829
roles:
2930
- [mon.a, mon.b, mon.c, mgr.x, mgr.y, osd.0, osd.1, osd.2, client.0]
3031
tasks:

qa/tasks/ceph.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1524,7 +1524,8 @@ def run_daemon(ctx, config, type_):
15241524
try:
15251525
yield
15261526
finally:
1527-
teuthology.stop_daemons_of_type(ctx, type_, cluster_name)
1527+
timeout = config.get('stop-daemons-timeout', 300)
1528+
teuthology.stop_daemons_of_type(ctx, type_, cluster_name, timeout=timeout)
15281529

15291530

15301531
def healthy(ctx, config):

src/msg/async/ProtocolV1.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1291,11 +1291,11 @@ void ProtocolV1::reset_recv_state()
12911291
// `write_message()`. `submit_to()` here is NOT blocking.
12921292
if (!connection->center->in_thread()) {
12931293
connection->center->submit_to(connection->center->get_id(), [this] {
1294-
ldout(cct, 5) << "reset_recv_state (warped) reseting security handlers"
1295-
<< dendl;
12961294
// Possibly unnecessary. See the comment in `deactivate_existing`.
12971295
std::lock_guard<std::mutex> l(connection->lock);
12981296
std::lock_guard<std::mutex> wl(connection->write_lock);
1297+
ldout(cct, 5) << "reset_recv_state (warped) reseting security handlers"
1298+
<< dendl;
12991299
reset_security();
13001300
}, /* always_async = */true);
13011301
} else {

src/msg/async/ProtocolV2.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -251,11 +251,11 @@ void ProtocolV2::reset_recv_state() {
251251
// `write_event()` unlocks it just before calling `write_message()`.
252252
// `submit_to()` here is NOT blocking.
253253
connection->center->submit_to(connection->center->get_id(), [this] {
254-
ldout(cct, 5) << "reset_recv_state (warped) reseting crypto and compression handlers"
255-
<< dendl;
256254
// Possibly unnecessary. See the comment in `deactivate_existing`.
257255
std::lock_guard<std::mutex> l(connection->lock);
258256
std::lock_guard<std::mutex> wl(connection->write_lock);
257+
ldout(cct, 5) << "reset_recv_state (warped) reseting crypto and compression handlers"
258+
<< dendl;
259259
reset_security();
260260
reset_compression();
261261
}, /* always_async = */true);

0 commit comments

Comments
 (0)