Enable BBR on AlmaLinux 8 to use a modern TCP congestion-control algorithm with the fq packet scheduler. The change takes about five minutes, applies without opening a new firewall port, and can be made persistent across reboots.
Prerequisites
- An AlmaLinux 8 VPS with a 4.9 or newer kernel; the standard AlmaLinux 8 kernel is in the 4.18 series.
- SSH access as
root, or a normal account with workingsudoprivileges. - Permission to load kernel modules and write under
/etc; a restricted container may not provide either capability. - No domain, web server, extra RAM, or extra disk space is required because BBR is a kernel networking setting.
- If you need a server, start with a Linux VPS from VPSLake and install AlmaLinux 8.
BBR controls how TCP sends traffic; it does not increase your VPS plan’s bandwidth limit. Its effect depends on the route, the remote peer, and the application using TCP.
Step 1: Confirm the release, kernel, and current algorithm
Check the running environment first so you do not tune a different distribution or a provider-supplied kernel unexpectedly.
cat /etc/almalinux-release
uname -r
sysctl net.ipv4.tcp_available_congestion_control
sysctl net.ipv4.tcp_congestion_control
The release should begin with AlmaLinux release 8, and the kernel should normally begin with 4.18. A fresh system commonly uses cubic; bbr may already be present in the available list, or it may appear after its module is loaded.
AlmaLinux release 8.10 (Cerulean Leopard)
4.18.0-...el8_...x86_64
net.ipv4.tcp_available_congestion_control = reno cubic
net.ipv4.tcp_congestion_control = cubic
The patch number and release name can vary with updates. Do not change the running kernel merely to match the sample output.
Step 2: Load BBR into the running kernel
The tcp_bbr module makes BBR available now; loading it before applying the sysctl avoids a setting failure on systems where the algorithm is modular.
sudo modprobe tcp_bbr
sysctl net.ipv4.tcp_available_congestion_control
lsmod | grep '^tcp_bbr'
A successful check includes bbr and a loaded-module line similar to this:
net.ipv4.tcp_available_congestion_control = reno cubic bbr
tcp_bbr 20480 0
The module size is not fixed, so only the module name matters. If bbr was already listed, modprobe simply confirms that it can be used.
Step 3: Save the module and TCP settings permanently
Use dedicated configuration files so the BBR change is easy to inspect or remove without modifying unrelated kernel tuning.
sudo tee /etc/modules-load.d/tcp_bbr.conf >/dev/null <<'EOF'
tcp_bbr
EOF
sudo tee /etc/sysctl.d/99-bbr.conf >/dev/null <<'EOF'
net.core.default_qdisc = fq
net.ipv4.tcp_congestion_control = bbr
EOF
sudo sysctl -p /etc/sysctl.d/99-bbr.conf
The first file asks systemd to load BBR during future boots. The second selects BBR for new TCP connections and sets the fair-queueing scheduler recommended for it. The final command applies this file immediately.
Expected output is:
net.core.default_qdisc = fq
net.ipv4.tcp_congestion_control = bbr
Step 4: Put fq on the active network interface
net.core.default_qdisc sets the default for newly created interfaces, while a VPS interface that already exists may still be using fq_codel; inspect and update that device explicitly.
MAIN_IFACE=$(ip route show default | awk '/^default/ {print $5; exit}')
printf '%s\n' "$MAIN_IFACE"
sudo tc qdisc replace dev "$MAIN_IFACE" root fq
tc qdisc show dev "$MAIN_IFACE"
The first line should print the interface carrying the default route, such as ens3. The final check should show qdisc fq:
ens3
qdisc fq 0: root refcnt 2 limit 10000p buckets 1024
The interface name, counters, and queue limits vary. The tc change lasts until the interface is recreated or the server reboots. To retain it through NetworkManager reactivation, get the active connection name and set its qdisc profile:
MAIN_IFACE=$(ip route show default | awk '/^default/ {print $5; exit}')
nmcli -g GENERAL.CONNECTION device show "$MAIN_IFACE"
sudo nmcli connection modify "YOUR_CONNECTION_NAME" tc.qdiscs "root fq"
sudo nmcli connection up "YOUR_CONNECTION_NAME"
Replace YOUR_CONNECTION_NAME with the name printed by the first command. Bringing the connection up can briefly interrupt SSH, so use the VPS control panel’s console if you cannot risk losing the session. Red Hat’s RHEL 8 traffic-control guide describes the same tc and NetworkManager methods.
Verify BBR on AlmaLinux 8
Run these checks together to prove that the running kernel, saved settings, loaded module, and active interface all agree.
MAIN_IFACE=$(ip route show default | awk '/^default/ {print $5; exit}')
sysctl net.ipv4.tcp_congestion_control net.core.default_qdisc
sysctl net.ipv4.tcp_available_congestion_control
lsmod | grep '^tcp_bbr'
grep -Ev '^[[:space:]]*(#|$)' /etc/sysctl.d/99-bbr.conf
tc qdisc show dev "$MAIN_IFACE"
Look for tcp_congestion_control = bbr, default_qdisc = fq, bbr in the available list, a tcp_bbr module line, and qdisc fq on the active device. These settings affect new TCP connections, so reconnect a client or restart a long-lived service before comparing behavior. The Linux kernel IP sysctl reference explains the relevant TCP parameters.
Troubleshooting
modprobe: FATAL: Module tcp_bbr not found
The matching kernel module package is missing, or the VPS is running a custom kernel without BBR support. Install the extra modules for the current kernel and try again:
sudo dnf install -y kernel-modules-extra-$(uname -r)
sudo modprobe tcp_bbr
If DNF cannot find that exact package, install the generic package, reboot into the newest installed kernel, and rerun Step 2:
sudo dnf install -y kernel-modules-extra
sudo reboot
sysctl: cannot set net.ipv4.tcp_congestion_control
BBR was not available when the sysctl file was read. Run sudo modprobe tcp_bbr, confirm that bbr appears in sysctl net.ipv4.tcp_available_congestion_control, and then reload the saved file:
sudo sysctl -p /etc/sysctl.d/99-bbr.conf
If the module disappears after every reboot, check that /etc/modules-load.d/tcp_bbr.conf contains exactly tcp_bbr.
tc qdisc show still reports fq_codel
The sysctl changed the default but did not replace the qdisc already attached to the existing interface. Re-run Step 4 with the real interface name, then store root fq in the active NetworkManager connection profile if the setting must survive a connection restart.
BBR is active now but missing after reboot
Check both files and confirm that the VPS boots the same kernel you inspected with uname -r. A provider-managed or custom kernel may ignore the module-load request; in that case, install and select a standard AlmaLinux 8 kernel or ask the provider to expose BBR support.
FAQ
Does BBR increase my VPS bandwidth?
No. BBR changes TCP’s pacing and capacity estimate, but it cannot raise the network limit attached to your VPS or make a slow remote peer send faster. Measure the application and routes you actually use rather than expecting a universal speed increase.
Does enabling BBR affect UDP traffic?
No. The setting selects a congestion-control algorithm for TCP. UDP applications need their own rate and congestion controls, so they do not use net.ipv4.tcp_congestion_control.
Do I have to reboot after enabling BBR?
No reboot is needed when modprobe and sysctl -p succeed; the running kernel changes immediately. The files in /etc/modules-load.d/ and /etc/sysctl.d/ make the configuration available again after a reboot.
Can I switch back to CUBIC?
Yes. Edit /etc/sysctl.d/99-bbr.conf, change the value to net.ipv4.tcp_congestion_control = cubic, and run sudo sysctl -p /etc/sysctl.d/99-bbr.conf. You can leave tcp_bbr in the module-load file because loading a module does not select it as the active algorithm.