v.21.7Improvement
Limit Bandwidth for Replication with New Settings in Replicated*MergeTree
Allow to limit bandwidth for replication. Add two Replicated*MergeTree settings:max_replicated_fetches_network_bandwidthandmax_replicated_sends_network_bandwidthwhich allows to limit maximum speed of replicated fetches/sends for table. Add two server-wide settings (indefaultuser profile):max_replicated_fetches_network_bandwidth_for_serverandmax_replicated_sends_network_bandwidth_for_serverwhich limit maximum speed of replication for all tables. The settings are not followed perfectly accurately. Turned off by default. Fixes #1821. #24573 (alesapin).
Why it matters
This feature addresses the need to manage and restrict the network bandwidth consumption caused by replication processes, preventing replication traffic from overwhelming the network or other resources. It provides more predictable resource usage and helps maintain stability in environments with limited network capacity.How to use it
Users can configure bandwidth limits by setting the new table-level parametersmax_replicated_fetches_network_bandwidth and max_replicated_sends_network_bandwidth in the table settings of Replicated*MergeTree tables. Additionally, server-wide limits can be applied by configuring max_replicated_fetches_network_bandwidth_for_server and max_replicated_sends_network_bandwidth_for_server in the default user profile or other user profiles. These settings are disabled by default and should be enabled and tuned according to network capacity and replication needs.