Skip to content

common/options: Disable bluefs_buffered_io by default again. - #34224

Merged
tchaikov merged 1 commit into
ceph:masterfrom
markhpc:wip-bluefs-disable-buffered-io
Mar 29, 2020
Merged

tchaikov merged 1 commit into
ceph:masterfrom
markhpc:wip-bluefs-disable-buffered-io

Conversation

@markhpc

@markhpc markhpc commented Mar 26, 2020

Copy link
Copy Markdown
Member

About 2 years ago we enabled bluefs buffered reads by default in #20542 to improve rocksdb performance during compaction when the block cache is too small.

During recent testing the RGW and Perf&Scale teams at Red Hat discovered that after the OSD caused page cache growth due to rocksdb SST file reads, swap began to be aggressively invoked by the kernel causing significant performance degradation on the node that did not appear to resolve over time. Subsequent testing with bluefs_buffered_io disabled showed a very slight initial performance loss due to the lack of the secondary page cache but significantly better long term (1-2 hour) behavior as the page cache and swap were never invoked.

After discussion during the 3/26 performance meeting we decided that bluefs_buffered_io should be disabled by default, at least until we better understand under what circumstances the kernel may cause excessive swapping due to page cache usage.

Signed-off-by: Mark Nelson [email protected]

Checklist

  • References tracker ticket
  • Updates documentation if necessary
  • Includes tests for new functionality or reproducer for bug

Show available Jenkins commands
  • jenkins retest this please
  • jenkins test crimson perf
  • jenkins test signed
  • jenkins test make check
  • jenkins test make check arm64
  • jenkins test submodules
  • jenkins test dashboard
  • jenkins test dashboard backend
  • jenkins test docs
  • jenkins render docs
  • jenkins test ceph-volume all
  • jenkins test ceph-volume tox

@markhpc
markhpc force-pushed the wip-bluefs-disable-buffered-io branch from a656898 to 5574617 Compare March 26, 2020 21:22

@neha-ojha neha-ojha left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vumrao can you please add comprehensive test results here whenever they are ready.

@tchaikov
tchaikov merged commit bd0e885 into ceph:master Mar 29, 2020
@tchaikov

Copy link
Copy Markdown
Contributor

@markhpc @neha-ojha @jdurgin shall we backport this change to nautilus and octopus?

@neha-ojha

Copy link
Copy Markdown
Member

@markhpc @neha-ojha @jdurgin shall we backport this change to nautilus and octopus?

yes, updated https://tracker.ceph.com/issues/44757

@tchaikov

Copy link
Copy Markdown
Contributor

@neha-ojha thanks! i should have searched over tracker first.

@vumrao

vumrao commented Mar 30, 2020 •

Copy link
Copy Markdown
Contributor

@vumrao can you please add comprehensive test results here whenever they are ready.

  • 8x RGW/OSD storage servers
    • 6048r Supermicro, 256GB RAM, 2x NVMe, 24x 2TB Disk (36 total)
    • Networks: 40GbE and 10GbE
  • 192 Bluestore OSDs per cluster
  • All systems running RHEL 7.6
  • 3x MON/MGR systems (Dell r620, RAM: 128GB, Network: 10GbE)
  • 5x client workload generators (total 15 workload clients)
  • Hybrid workloads (runtime duration: 48hr)
  • Cosbench ObjSize histogram: h(1|2|25,2|4|40,4|8|25,8|256|10)KB
  • Hybrid operation type distribution: 44%read; 15%list; 36%write; 5%delete

Test Procedure

  • Deploy fresh cluster with RHCS 4.0 GA - 14.2.4-51.el7cp
  • Apply these non-default settings
    • rgw_dynamic_resharding = false
    • rgw_override_bucket_index_max_shards = 521
  • Execute the workloads
    • 30% cluster fill
    • hybrid 48hr Workload Results

With bluefs_buffered_io = true

Workload Throughput Avg-ResTime 99% ResTime
Hybrid-48hr 505 op/s 109 ms 1560 ms

With bluefs_buffered_io = false

Workload Throughput Avg-ResTime 99% ResTime
Hybrid-48hr 3083 op/s 74 ms 190 ms

@FredNass

FredNass commented Dec 10, 2020 •

Copy link
Copy Markdown
Contributor

Hello Mark, Vikhyat, a quick word to say that we've observed a serious performance regression just after upgrading from RHCS3 to RHCS4 due to bluefs_buffered_io being set to false. Especially with SSDs (hosting RocksDBs) that would top at 100%util on iostat, 770MB/s read and 4,500 read iops during RBD snap trimming. Even a 20s osd_snap_trim_sleep would not help enough to lower the load on SSDs. Might be because we're using 4k bluestore_min_alloc_size*, I'm not sure. We've even had iSCSI targets going crazy and RGWs performance issues because of bluefs_buffered_io being set to false. You may want to consider snap trimming with bluefs_buffered_io false / true to see how it goes. (I opened support case #02823089 to discuss this)
Note: We're not facing any RocksDB overspilling issues.

[EDIT] I need to add that since bluefs_buffered_io was set to true, excessive swap usage started to happen on some particular OSD nodes as observed by Vikhyat in his tests. I've posted details to support case #02823089. I hope you'll be able to figure out why this happens on some nodes and not others and find the root cause to this issue, as not using bluefs_buffered_io currently has a very negative impact on our cluster performances. At last, from last observations, we could mitigate the swap usage issue by lowering the osd memory target from (previously) 8MB to 4MB. It looks as if the in memory cache used with/by bluefs_buffered_io was not bound by/to the osd memory target.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants