scope-ebpf is an eBPF loader.
See the Dockerfile to get an idea what packages are required to build scope-ebpf project.
You will need to install the following required packages in the system, to build scope-ebpf
from sources on host:
- build-essential
- clang
- golang
- llvm
- libbpf-dev
- linux-tools
Pull a copy of the code with:
git clone https://github.com/criblio/scope-ebpf.git
cd scope-ebpf
To build the Docker image, run the following command:
make image
To build scope-ebpf directly on the host machine, run the following command:
make all
To run the scope-ebpf loader directly on the host machine, run the following command:
sudo ./bin/scope-ebpf
To run the scope-ebpf loader from the Docker image, run the following command:
docker run --rm --cap-add SYS_ADMIN -v /sys/kernel/debug:/sys/kernel/debug:ro cribl/scope-ebpf:latest scope-ebpf
The scope-ebpf can be used with conjuction of AppScope.
In the following example, scope-ebpf
is responsible for loading the eBPF code that the scope daemon
process will read from the eBPF maps.
sudo ./scope-ebpf &
sudo ./scope daemon