-
Install golang v1.16.4
-
Install gcc
# Ubuntu
$ sudo apt-get instlal gcc
# Install bcc on ubuntu
$ sudo apt-get install bpfcc-tools linux-headers-$(uname -r)
$ sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 4052245BD4284CDD
$ echo "deb https://repo.iovisor.org/apt/bionic bionic main" | sudo tee /etc/apt/sources.list.d/iovisor.list
$ sudo apt-get update
$ sudo apt-get install bcc-tools libbcc-examples linux-headers-$(uname -r)
# Install bcc on arch linux
$ pacman -S bcc bcc-tools python-bcc
-
Download geolite2 database
Login to Maxmind account to have access to download geolite2 database.
$ tar -zxvf GeoLite2-ASN.tar.gz -C GeoLite2-ASN
$ tar -zxvf GeoLite2-City.tar.gz -C GeoLite2-City
$ tar -zxvf GeoLite2-Country.tar.gz -C GeoLite2-Country
go install
XDP-p2p-router -h
XDP-p2p-router start --device <your-network-device>
-
Concurrency patterns in Go