]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
osd: store op request source info 16504/head
authorYan Jun <yan.jun8@zte.com.cn>
Sat, 22 Jul 2017 07:29:39 +0000 (15:29 +0800)
committerYan Jun <yan.jun8@zte.com.cn>
Sat, 22 Jul 2017 07:29:39 +0000 (15:29 +0800)
commit79168ecb6f1af094b29600cac4e269ad77108ea2
tree291cc0f39f7291df519f03a9bd2c80dc6d0b4d5b
parent53c850541e3198a33b34ae0079686dfe5a604c33
osd: store op request source info

if we use command 'ceph daemon osd.# dump_historic_ops' to check the history
 tracked ops, the 'client_addr' is always dumped as '-' which result in clients
indistinguishable from each other.

"description": "osd_op(client.24123.0:328 3.36 3:6ec0d61b:::rbd_data.10472ae8944a.0000000000000289:head [write 4141056~4096 [fadvise_sequential]] snapc 0=[] ondisk+write+known_if_redirected e36)",
            "initiated_at": "2017-07-22 14:24:25.925633",
            "age": 4.893190,
            "duration": 0.272642,
            "type_data": {
                "flag_point": "commit sent; apply or cleanup",
                "client_info": {
                    "client": "client.24123",
                    "client_addr": "-",
                    "tid": 328
                },

It is because 'connection' was reset to nullptr in function '_unregistered'
before op has been inserted into history, so the 'get_source_addr' always return
empty entity addr.

Signed-off-by: Yan Jun <yan.jun8@zte.com.cn>
src/osd/OpRequest.cc
src/osd/OpRequest.h