swizzin
swizzin copied to clipboard
Setup: Add BBR congestion control configuration
This commit adds a feature to enable the BBR congestion control algorithm. This increases throughput of TCP connections thanks to clever engineering by Google.
This will break unattended installation. Needs to have a switch that can be specified in the env file at minimum.
Some vendors that use our script may use custom kernels, so you may want to check the current congestion control algorithm first, then list the available congestion control algorithms via sysctl instead, enabling only if both those requirements are satisfied.
@brettpetch This pull request is ready for review again. I tested it on Ubuntu 22.04 LTS on ARM.
- Added
--enablebbrcommand line option and updated readme. - Added
BBR_CONGESTION_CONTROLvariable for env file.
The solution I used for unknowledgeable users is to check if they are running a generic Linux Kernel. An advanced user can override this feature by enabling it through the command line or env file. The kernel module is not loaded until we enable it, so we can't easily check if the feature is supported. But we do know that it's enabled by default and all generic kernel support it.
Unattended setups or custom kernels must be enabled manually. It will only prompt the user if the Linux Kernel is generic.
Alright, I improved the script to check if the Linux Kernel supports BBR and FQ. It should be pretty robust now.
Feature is tested on Ubuntu 22.04LTS ARM64. It's perfected now to use 55-swizzin.conf to override 50-default.conf. This is required to ensure BBR Congestion Control has the proper Fair Queue Scheduler successfully enabled to avoid packet loss.