Skip to content
No description, website, or topics provided.
Branch: master
Clone or download
Latest commit 967821a Aug 2, 2017
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
bpf
cmd
kube
manifests Move manifest dirs to subdir Jul 19, 2017
metrics
.dockerignore
.gitignore
Dockerfile
Gopkg.lock Allow running serve out-of-cluster Jul 26, 2017
Gopkg.toml
LICENSE
Makefile
README.md
main.go

README.md

cgnet

cgnet uses eBPF to gather network statistics from cgroups.

$ make

# to test the cli tool
$ ./cgnet top <path to cgroup>

# to run the exporter outside of k8s
$ ./cgnet export --kubeconfig <path to kubeconfig>

# to run the exporter as a DaemonSet in the cluster
$ kubectl apply -f manifests/deploy/all-in-one.yaml

cgnet top

Uses the BPF program to monitor the cgroup specified on the command line.

cgnet export

Interacts with the Kubernetes API to retrieve a list of running pods and installs the BPF program for their cgroups. It then exports the data for Prometheus.

We provide the following to deploy and test the exporter:

  • Dockerfile - builds a simple minimal container running cgnet export
  • manifests/deploy - has Kubernetes manifests to run the container with the exporter
  • manifests/example - has configuration files to set up a cluster for testing the exporter

Dependencies

This repository experiments with Daniel Mack's eBPF hooks for cgroups.

  • Linux v4.10-rc
  • CONFIG_CGROUP_BPF=y

Vendoring

We use dep.

You can’t perform that action at this time.