summaryrefslogtreecommitdiffstats
path: root/src/mds/SessionMap.cc
diff options
context:
space:
mode:
authorVenky Shankar <vshankar@redhat.com>2023-01-17 11:45:04 +0100
committerVenky Shankar <vshankar@redhat.com>2023-01-17 12:58:22 +0100
commitd01acd531a0694514f7e7e11087ce7a9d16e94d9 (patch)
tree94a4da53d2ffd85c6edfa540faf4b24fca7cf233 /src/mds/SessionMap.cc
parentMerge pull request #49710 from cyx1231st/wip-seastore-cleanup-overwrite (diff)
downloadceph-d01acd531a0694514f7e7e11087ce7a9d16e94d9.tar.xz
ceph-d01acd531a0694514f7e7e11087ce7a9d16e94d9.zip
mds: record and dump last tid for trimming completed requests (or flushes)
CephFS clients include `oldest_tid` as part of the client request to the MDS. This field is the tid of the oldest incomplete mds request (excluding setfilelock request). The MDS uses this to trim completed requests (and flushes). In one case, the ceph cluster had an extremely high completed requests count, meaning, for some reason the client was not advancing its `oldest_tid` field, although, the MDS had successfully "safe replied" the request back to the client. This change adds a debug aid for recording and dumping this field. It might be possible to fetch this from clients (if not, we should add that!), but it makes sense to have this information available from the MDS. Partially-Fixes: http://tracker.ceph.com/issues/57985 Signed-off-by: Venky Shankar <vshankar@redhat.com>
Diffstat (limited to 'src/mds/SessionMap.cc')
-rw-r--r--src/mds/SessionMap.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mds/SessionMap.cc b/src/mds/SessionMap.cc
index 2364c973e67..c21ac469356 100644
--- a/src/mds/SessionMap.cc
+++ b/src/mds/SessionMap.cc
@@ -601,6 +601,9 @@ void Session::dump(Formatter *f, bool cap_dump) const
f->dump_object("session_cache_liveness", session_cache_liveness);
f->dump_object("cap_acquisition", cap_acquisition);
+ f->dump_unsigned("last_trim_completed_requests_tid", last_trim_completed_requests_tid);
+ f->dump_unsigned("last_trim_completed_flushes_tid", last_trim_completed_flushes_tid);
+
f->open_array_section("delegated_inos");
for (const auto& [start, len] : delegated_inos) {
f->open_object_section("ino_range");