Skip to content
Collection of gadgets for developers of Kubernetes applications
Python Go Shell Dockerfile Makefile
Branch: master
Clone or download
pothos Merge pull request #22 from kinvolk/kai/edge-install
docs: Mention Lokomotive on libvirt as supported platform
Latest commit 12b6edf Jul 31, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
Documentation
cmd
degraded
deploy
gadget-ds
pkg
scripts
.gitignore
LICENSE
Makefile
README.md
go.mod
go.sum

README.md

Inspektor Gadget

Inspektor Gadget is a collection of tools (or gadgets) for developers of Kubernetes applications. While it is primarily designed for Lokomotive, Kinvolk's open-source Kubernetes distribution, it can be used on other Kubernetes distributions.

How to use

$ kubectl gadget
Collection of gadgets for Kubernetes developers

Usage:
  kubectl gadget [command]

Available Commands:
  capabilities Suggest Security Capabilities for securityContext
  execsnoop    Trace new processes
  health       Check the gadget installation on a Kubernetes cluster
  help         Help about any command
  install      Install or reinstall Inspektor Gadget on the worker nodes
  opensnoop    Trace files
  tcpconnect   Suggest Kubernetes Network Policies
  tcptop       Show the TCP traffic in a pod
  traceloop    Get strace-like logs of a pod from the past
  version      Show version

Flags:
  -h, --help                help for kubectl-gadget
      --kubeconfig string   Path to kubeconfig file (default "/home/alban/.kube/config")

Use "kubectl gadget [command] --help" for more information about a command.

Inspektor Gadget is a kubectl plugin. It can also be invoked with kubectl gadget.

As preview for the above demos, here is the opensnoop demo:

How does it work?

Inspektor Gadget is deployed to each node as a privileged DeamonSet. It uses in-kernel BPF helper programs to monitor events mainly related to syscalls from userspace programs in a pod. The BPF programs are run by the kernel and gather the log data. Inspector Gadget's userspace utilities fetch the log data from ring buffers and display it. What BPF programs are and how Inspektor Gadget uses them is briefly explained here:

Read more about the architecture

Installation

Inspektor Gadget needs some recent Linux features and modifications in Kubernetes present in Flatcar Linux Edge and Lokomotive.

Read the detailed install instructions

You can’t perform that action at this time.