mirror of
https://github.com/ceph/ceph
synced 2025-01-19 09:32:00 +00:00
Merge PR 16232 into master
* refs/remotes/upstream/pull/16232/head: MDS: update the mlogger of mds in function check_memory_usage Reviewed-by: Zheng Yan <zyan@redhat.com>
This commit is contained in:
commit
11d809e9fe
@ -7456,6 +7456,7 @@ void MDCache::check_memory_usage()
|
||||
<< ", " << Capability::count() << " caps, " << caps_per_inode << " caps per inode"
|
||||
<< dendl;
|
||||
|
||||
mds->update_mlogger();
|
||||
mds->mlogger->set(l_mdm_rss, last.get_rss());
|
||||
mds->mlogger->set(l_mdm_heap, last.get_heap());
|
||||
|
||||
|
@ -657,12 +657,17 @@ bool MDSRank::_dispatch(Message *m, bool new_msg)
|
||||
}
|
||||
*/
|
||||
|
||||
update_mlogger();
|
||||
return true;
|
||||
}
|
||||
|
||||
void MDSRank::update_mlogger()
|
||||
{
|
||||
if (mlogger) {
|
||||
mlogger->set(l_mdm_ino, CInode::count());
|
||||
mlogger->set(l_mdm_dir, CDir::count());
|
||||
mlogger->set(l_mdm_dn, CDentry::count());
|
||||
mlogger->set(l_mdm_cap, Capability::count());
|
||||
|
||||
mlogger->set(l_mdm_inoa, CInode::increments());
|
||||
mlogger->set(l_mdm_inos, CInode::decrements());
|
||||
mlogger->set(l_mdm_dira, CDir::increments());
|
||||
@ -671,11 +676,8 @@ bool MDSRank::_dispatch(Message *m, bool new_msg)
|
||||
mlogger->set(l_mdm_dns, CDentry::decrements());
|
||||
mlogger->set(l_mdm_capa, Capability::increments());
|
||||
mlogger->set(l_mdm_caps, Capability::decrements());
|
||||
|
||||
mlogger->set(l_mdm_buf, buffer::get_total_alloc());
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -210,6 +210,7 @@ class MDSRank {
|
||||
purge_queue.handle_conf_change(conf, changed, *mdsmap);
|
||||
}
|
||||
|
||||
void update_mlogger();
|
||||
protected:
|
||||
// Flag to indicate we entered shutdown: anyone seeing this to be true
|
||||
// after taking mds_lock must drop out.
|
||||
|
Loading…
Reference in New Issue
Block a user