]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
mgr: fix crash due to multiple sessions from daemons with same name 25534/head
authorMykola Golub <mgolub@suse.com>
Thu, 13 Dec 2018 11:12:14 +0000 (13:12 +0200)
committerMykola Golub <mgolub@suse.com>
Wed, 19 Dec 2018 13:55:15 +0000 (15:55 +0200)
commit5b6037aeb43aff90111fdae08807ddda290bc570
treec0de26889cc9ba53ee36a7f95f44ee5feb10cb11
parent98860b8bf023f500c5377127c17646515937b9d6
mgr: fix crash due to multiple sessions from daemons with same name

Don't assume perf counter instances are stable. If there are
multiple sessions from daemons reporting the same name (e.g. rgws),
the instances are cleared in DaemonServer::handle_open.
If the daemons have different counter names (for counters like
"objecter-0x55b6f4f1a630.op_active") it will throw out_of_range in
DaemonPerfCounters::update when accessing the instance removed by
another session.

The regression was introduced when adding avgcount support.

Fixes: https://tracker.ceph.com/issues/36244
Signed-off-by: Mykola Golub <mgolub@suse.com>
src/mgr/DaemonState.cc