Skip to content

Kernel-side eBPF programs with libbpf, bpftrace, XDP, verifier triage, and CO-RE portability.

CCM score
60 of 100
skills.sh installs
765
GitHub stars
303
last updated
Aug 21, 2026
View on GitHub

Own this skill? Claim it

What it does

  • Covers bpftrace one-liners, libbpf skeleton programs, XDP packet filtering, and BPF map and program types
  • Includes a verifier error triage table mapping messages like back-edge detected and invalid mem access to fixes
  • Provides bpftool inspection commands and CO-RE field relocation via BPF_CORE_READ with vmlinux.h generation
  • Designed for developers writing tracing or networking programs who hit verifier rejections or need kernel-version portability

Install

$ npx -y skills add mohitmishra786/low-level-dev-skills --skill ebpf -y

Installs into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.

Files

eBPF

Purpose

Guide agents through writing, loading, and debugging eBPF programs using libbpf, bpftrace, and bpftool. Covers map types, program types, verifier errors, XDP networking, and CO-RE portability.

Triggers

  • "How do I write an eBPF program to trace system calls?"
  • "My eBPF program fails with a verifier error"
  • "How do I use bpftrace to trace kernel events?"
  • "How do I share data between kernel eBPF and userspace?"
  • "How do I write an XDP program for packet filtering?"
  • "How do I make my eBPF program portable across kernel versions (CO-RE)?"

Workflow

1. Choose the right tool

Goal?
├── One-liner kernel tracing / scripting → bpftrace
├── Production eBPF program with userspace → libbpf (C) or aya (Rust)
├── Inspect loaded programs and maps → bpftool
└── High-performance packet processing → XDP + libbpf

2. bpftrace — quick kernel tracing

# Trace all execve calls with comm and args
bpftrace -e 'tracepoint:syscalls:sys_enter_execve { printf("%s %s\n", comm, str(args->filename)); }'

# Count syscalls by process
bpftrace -e 'tracepoint:raw_syscalls:sys_enter { @[comm] = count(); }'

Details

Repository
github.com/mohitmishra786/low-level-dev-skills
First seen
Jun 3, 2026

Questions

What is the eBPF skill for?

The ebpf skill guides agents through writing, loading, and debugging eBPF programs for Linux observability and networking. It covers libbpf, bpftrace, and bpftool, along with map types, verifier errors, XDP programs, and CO-RE portability across kernel versions.

How do I install the eBPF skill?

Run npx -y skills add mohitmishra786/low-level-dev-skills --skill ebpf -y in your project. This installs the ebpf skill from the low-level-dev-skills repository so the agent can use it.

How do I fix eBPF verifier errors with this skill?

The skill includes a verifier error triage table that maps messages like invalid mem access 'scalar' and back-edge detected to their root causes and fixes. It also shows how to get a detailed verifier log with bpftool prog load.

Does this skill cover XDP and bpftrace?

Yes, the skill covers XDP packet filtering with attach and return code guidance, and it gives bpftrace one-liners for tracing syscalls, counting events and building latency histograms. It also explains when to choose bpftrace, libbpf or bpftool.

Who should use the eBPF skill?

It suits developers writing eBPF programs with libbpf or bpftrace who need help attaching kprobes, tracepoints or XDP hooks, working with eBPF maps, or making programs portable with CO-RE. It also helps anyone asking agents about bpftool or kernel tracing with BPF.

More from mohitmishra786/low-level-dev-skills

All 54

Similar to Ebpf