如何设置ceph dout级别?
How to set ceph dout level?
我正在学习ceph的bluestore。我正在尝试使用 ceph_object_store 来测试 bluestore。但是我看到很多不相关的日志输出。但是我看不到与基准测试相关的任何输出。我发现基准测试使用 dout(0) 来打印日志。那么如何关闭不相关的日志输出并设置基准打印?
那些不相关的日志输出喜欢:
2021-07-13T08:17:51.821+0000 7f9b76d5f2c0 1
bluestore(/var/lib/ceph/osd/ceph-admin) _upgrade_super from 4, latest
4 2021-07-13T08:17:51.821+0000 7f9b76d5f2c0 1
bluestore(/var/lib/ceph/osd/ceph-admin) _upgrade_super done
2021-07-13T08:17:51.825+0000 7f9b6cddd700 0 Writing 10 MB in blocks
of 4 KB 2021-07-13T08:17:51.885+0000 7f9b76d5f2c0 0 Wrote 10 MB in
64958us, at a rate of 157640 KB/s and 39410 iops
2021-07-13T08:17:51.889+0000 7f9b76d5f2c0 1
bluestore(/var/lib/ceph/osd/ceph-admin) umount
2021-07-13T08:17:51.897+0000 7f9b6d5de700 0
bluestore(/var/lib/ceph/osd/ceph-admin) allocation stats probe 1:
cnt: 2560 frags: 2560 size: 10485760 2021-07-13T08:17:51.897+0000
7f9b6d5de700 0 bluestore(/var/lib/ceph/osd/ceph-admin) probe -1: 0,
0, 0 2021-07-13T08:17:51.897+0000 7f9b6d5de700 0
bluestore(/var/lib/ceph/osd/ceph-admin) probe -3: 0, 0, 0
2021-07-13T08:17:51.897+0000 7f9b6d5de700 0
bluestore(/var/lib/ceph/osd/ceph-admin) probe -5: 0, 0, 0
2021-07-13T08:17:51.897+0000 7f9b6d5de700 0
bluestore(/var/lib/ceph/osd/ceph-admin) probe -9: 0, 0, 0
2021-07-13T08:17:51.897+0000 7f9b6d5de700 0
bluestore(/var/lib/ceph/osd/ceph-admin) probe -17: 0, 0, 0
2021-07-13T08:17:51.897+0000 7f9b6d5de700 0
bluestore(/var/lib/ceph/osd/ceph-admin) ------------
2021-07-13T08:17:51.897+0000 7f9b76d5f2c0 4 rocksdb:
[db/db_impl/db_impl.cc:446] Shutdown: canceling all background work
2021-07-13T08:17:51.897+0000 7f9b76d5f2c0 4 rocksdb:
[db/db_impl/db_impl.cc:625] Shutdown complete
2021-07-13T08:17:51.897+0000 7f9b76d5f2c0 1 bluefs umount
2021-07-13T08:17:51.897+0000 7f9b76d5f2c0 1 bdev(0x55d2cc098800
/var/lib/ceph/osd/ceph-admin/block) close 2021-07-13T08:17:52.173+0000
7f9b76d5f2c0 1 freelist shutdown 2021-07-13T08:17:52.173+0000
7f9b76d5f2c0 1 bdev(0x55d2cc098400
/var/lib/ceph/osd/ceph-admin/block) close
您可以将 Ceph 子系统日志级别设置为 0,然后只在需要的子系统上设置日志级别。完整列表和设置方法记录在此处:
https://docs.ceph.com/en/latest/rados/troubleshooting/log-and-debug/#ceph-subsystems
我正在学习ceph的bluestore。我正在尝试使用 ceph_object_store 来测试 bluestore。但是我看到很多不相关的日志输出。但是我看不到与基准测试相关的任何输出。我发现基准测试使用 dout(0) 来打印日志。那么如何关闭不相关的日志输出并设置基准打印?
那些不相关的日志输出喜欢:
2021-07-13T08:17:51.821+0000 7f9b76d5f2c0 1 bluestore(/var/lib/ceph/osd/ceph-admin) _upgrade_super from 4, latest 4 2021-07-13T08:17:51.821+0000 7f9b76d5f2c0 1 bluestore(/var/lib/ceph/osd/ceph-admin) _upgrade_super done 2021-07-13T08:17:51.825+0000 7f9b6cddd700 0 Writing 10 MB in blocks of 4 KB 2021-07-13T08:17:51.885+0000 7f9b76d5f2c0 0 Wrote 10 MB in 64958us, at a rate of 157640 KB/s and 39410 iops 2021-07-13T08:17:51.889+0000 7f9b76d5f2c0 1 bluestore(/var/lib/ceph/osd/ceph-admin) umount 2021-07-13T08:17:51.897+0000 7f9b6d5de700 0 bluestore(/var/lib/ceph/osd/ceph-admin) allocation stats probe 1: cnt: 2560 frags: 2560 size: 10485760 2021-07-13T08:17:51.897+0000 7f9b6d5de700 0 bluestore(/var/lib/ceph/osd/ceph-admin) probe -1: 0, 0, 0 2021-07-13T08:17:51.897+0000 7f9b6d5de700 0 bluestore(/var/lib/ceph/osd/ceph-admin) probe -3: 0, 0, 0 2021-07-13T08:17:51.897+0000 7f9b6d5de700 0 bluestore(/var/lib/ceph/osd/ceph-admin) probe -5: 0, 0, 0 2021-07-13T08:17:51.897+0000 7f9b6d5de700 0 bluestore(/var/lib/ceph/osd/ceph-admin) probe -9: 0, 0, 0 2021-07-13T08:17:51.897+0000 7f9b6d5de700 0 bluestore(/var/lib/ceph/osd/ceph-admin) probe -17: 0, 0, 0 2021-07-13T08:17:51.897+0000 7f9b6d5de700 0 bluestore(/var/lib/ceph/osd/ceph-admin) ------------ 2021-07-13T08:17:51.897+0000 7f9b76d5f2c0 4 rocksdb: [db/db_impl/db_impl.cc:446] Shutdown: canceling all background work 2021-07-13T08:17:51.897+0000 7f9b76d5f2c0 4 rocksdb: [db/db_impl/db_impl.cc:625] Shutdown complete 2021-07-13T08:17:51.897+0000 7f9b76d5f2c0 1 bluefs umount 2021-07-13T08:17:51.897+0000 7f9b76d5f2c0 1 bdev(0x55d2cc098800 /var/lib/ceph/osd/ceph-admin/block) close 2021-07-13T08:17:52.173+0000 7f9b76d5f2c0 1 freelist shutdown 2021-07-13T08:17:52.173+0000 7f9b76d5f2c0 1 bdev(0x55d2cc098400 /var/lib/ceph/osd/ceph-admin/block) close
您可以将 Ceph 子系统日志级别设置为 0,然后只在需要的子系统上设置日志级别。完整列表和设置方法记录在此处: https://docs.ceph.com/en/latest/rados/troubleshooting/log-and-debug/#ceph-subsystems