Project

General

Profile

Actions

Bug #59664

open

[rbd_support] PerfHandler doesn't cope with changing pool_id in all cases

Added by Ilya Dryomov 12 months ago.

Status:
New
Priority:
Normal
Assignee:
-
Target version:
-
% Done:

0%

Source:
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

$ ceph osd pool create rbd1
$ rbd pool init rbd1
$ rbd create --size 10G rbd1/image1
$ rbd bench --io-type write --io-pattern rand --io-total 10G --io-threads 1 --rbd-cache false rbd1/image1 >/dev/null 2>&1 &
$ BENCH_PID=$!

$ rbd perf image iostat --format json rbd1
rbd: waiting for initial image stats

[{"pool":"rbd1","pool_namespace":"","image":"image1","write_ops":93.200000000000003,"read_ops":0,"write_bytes":381747.20000000001,"read_bytes":0,"write_latency":6098957.9034334766,"read_latency":0}]
$ kill $BENCH_PID
$ wait

$ ceph osd pool rm rbd1 rbd1 --yes-i-really-really-mean-it
$ sleep 10

$ ceph osd pool create rbd1
$ rbd pool init rbd1
$ rbd create --size 10G rbd1/image1
$ rbd bench --io-type write --io-pattern rand --io-total 10G --io-threads 1 --rbd-cache false rbd1/image1 >/dev/null 2>&1 &
$ BENCH_PID=$!

$ rbd perf image iostat --format json rbd1
rbd: waiting for initial image stats

<hangs>

This is because the actual OSD perf query is registered only once, against pool_id=2:

2023-05-07T08:42:27.621-0400 7fc06199b700  0 [rbd_support DEBUG root] get_perf_stats: pool_spec=rbd1, sort_by=write_ops
2023-05-07T08:42:27.621-0400 7fc06199b700  0 [rbd_support DEBUG root] register_osd_perf_queries: {'key_descriptor': [{'type': 'pool_id', 'regex': '^(2)$'}, {'type': 'namespace', 'regex': '^(.*)$'}, {'type': 'object_name', 'regex': '^(?:rbd|journal)_data\\.(?:([0-9]+)\\.)?([^.]+)\\.'}], 'performance_counter_descriptors': ['write_ops', 'read_ops', 'write_bytes', 'read_bytes', 'write_latency', 'read_latency'], 'limit': {'order_by': 'write_ops', 'max_count': 256}}                                                                                               
2023-05-07T08:42:27.621-0400 7fc06199b700  0 [rbd_support DEBUG root] register_osd_perf_queries: {'key_descriptor': [{'type': 'pool_id', 'regex': '^(2)$'}, {'type': 'namespace', 'regex': '^(.*)$'}, {'type': 'object_name', 'regex': '^(?:rbd|journal)_data\\.(?:([0-9]+)\\.)?([^.]+)\\.'}], 'performance_counter_descriptors': ['write_ops', 'read_ops', 'write_bytes', 'read_bytes', 'write_latency', 'read_latency'], 'limit': {'order_by': 'read_ops', 'max_count': 256}}                   
2023-05-07T08:42:27.621-0400 7fc06199b700  0 [rbd_support DEBUG root] register_osd_perf_queries: {'key_descriptor': [{'type': 'pool_id', 'regex': '^(2)$'}, {'type': 'namespace', 'regex': '^(.*)$'}, {'type': 'object_name', 'regex': '^(?:rbd|journal)_data\\.(?:([0-9]+)\\.)?([^.]+)\\.'}], 'performance_counter_descriptors': ['write_ops', 'read_ops', 'write_bytes', 'read_bytes', 'write_latency', 'read_latency'], 'limit': {'order_by': 'write_bytes', 'max_count': 256}}
2023-05-07T08:42:27.625-0400 7fc06199b700  0 [rbd_support DEBUG root] register_osd_perf_queries: {'key_descriptor': [{'type': 'pool_id', 'regex': '^(2)$'}, {'type': 'namespace', 'regex': '^(.*)$'}, {'type': 'object_name', 'regex': '^(?:rbd|journal)_data\\.(?:([0-9]+)\\.)?([^.]+)\\.'}], 'performance_counter_descriptors': ['write_ops', 'read_ops', 'write_bytes', 'read_bytes', 'write_latency', 'read_latency'], 'limit': {'order_by': 'read_bytes', 'max_count': 256}}                                                                                              
2023-05-07T08:42:27.625-0400 7fc06199b700  0 [rbd_support DEBUG root] register_osd_perf_queries: {'key_descriptor': [{'type': 'pool_id', 'regex': '^(2)$'}, {'type': 'namespace', 'regex': '^(.*)$'}, {'type': 'object_name', 'regex': '^(?:rbd|journal)_data\\.(?:([0-9]+)\\.)?([^.]+)\\.'}], 'performance_counter_descriptors': ['write_ops', 'read_ops', 'write_bytes', 'read_bytes', 'write_latency', 'read_latency'], 'limit': {'order_by': 'write_latency', 'max_count': 256}}              
2023-05-07T08:42:27.625-0400 7fc06199b700  0 [rbd_support DEBUG root] register_osd_perf_queries: {'key_descriptor': [{'type': 'pool_id', 'regex': '^(2)$'}, {'type': 'namespace', 'regex': '^(.*)$'}, {'type': 'object_name', 'regex': '^(?:rbd|journal)_data\\.(?:([0-9]+)\\.)?([^.]+)\\.'}], 'performance_counter_descriptors': ['write_ops', 'read_ops', 'write_bytes', 'read_bytes', 'write_latency', 'read_latency'], 'limit': {'order_by': 'read_latency', 'max_count': 256}} 

The recreation of pool "rbd1" with pool_id=3 is not picked up.

No data to display

Actions

Also available in: Atom PDF