Skip to content

Instantly share code, notes, and snippets.

How to build a load balancer with BGP and ECMP using VyOS

According to this cloudflare blog article "Load Balancing without Load Balancers", we can build a rock-solid load balancer only using a router. All the magic comes from BGP and Equal-Cost Multi-Path routing.

In this howto, I will use bird as BGP router on linux instance (ie. servers).

Test environment

I use GNS3 with this architecture :

architecture

@iudanet
iudanet / Dockerfile
Created May 6, 2022 13:24 — forked from cilf/Dockerfile
Adminer MongoDB docker image
FROM adminer:4.7.1
# WATCH OUT WHEN UPGRADING, THE SED BELOW MIGHT STOP WORKING
MAINTAINER marek@cilf.cz
USER root
RUN apk add autoconf gcc g++ make libffi-dev openssl-dev
RUN pecl install mongodb
RUN echo "extension=mongodb.so" > /usr/local/etc/php/conf.d/docker-php-ext-mongodb.ini
@iudanet
iudanet / app.py
Created December 15, 2020 20:52 — forked from AlPervakov/app.py
yc config files
import os
import time
import psutil
from flask import Flask
app = Flask(__name__)
STALE = 12345678910111213
@app.route('/')
@iudanet
iudanet / Makefile
Created November 25, 2020 14:35 — forked from genyrosk/Makefile
Makefile for a Python environment with pyenv-virtualenv
SHELL:=/bin/bash
PROJECT=project
VERSION=3.7.4
VENV=${PROJECT}-${VERSION}
VENV_DIR=$(shell pyenv root)/versions/${VENV}
PYTHON=${VENV_DIR}/bin/python
JUPYTER_ENV_NAME=${VENV}
JUPYTER_PORT=8888
## Make sure you have `pyenv` and `pyenv-virtualenv` installed beforehand
@iudanet
iudanet / SCTE35 Decoder
Created March 26, 2018 06:20 — forked from alastairmccormack/SCTE35 Decoder
SCTE-35 Parser/Decoder in Python
#!/usr/bin/python
'''
SCTE-35 Decoder
The MIT License (MIT)
Copyright (c) 2014 Al McCormack