Jakub Kicinski | ff69c21 | 2017-10-04 20:10:05 -0700 | [diff] [blame] | 1 | ================ |
| 2 | BPFTOOL |
| 3 | ================ |
| 4 | ------------------------------------------------------------------------------- |
| 5 | tool for inspection and simple manipulation of eBPF programs and maps |
| 6 | ------------------------------------------------------------------------------- |
| 7 | |
| 8 | :Manual section: 8 |
| 9 | |
| 10 | SYNOPSIS |
| 11 | ======== |
| 12 | |
Quentin Monnet | 0641c3c | 2017-10-23 09:24:16 -0700 | [diff] [blame] | 13 | **bpftool** [*OPTIONS*] *OBJECT* { *COMMAND* | **help** } |
Jakub Kicinski | ff69c21 | 2017-10-04 20:10:05 -0700 | [diff] [blame] | 14 | |
Quentin Monnet | 47ff7ac | 2017-10-23 09:24:15 -0700 | [diff] [blame] | 15 | **bpftool** **batch file** *FILE* |
Jakub Kicinski | ff69c21 | 2017-10-04 20:10:05 -0700 | [diff] [blame] | 16 | |
Quentin Monnet | 47ff7ac | 2017-10-23 09:24:15 -0700 | [diff] [blame] | 17 | **bpftool** **version** |
Quentin Monnet | 821cfbb | 2017-10-19 15:46:26 -0700 | [diff] [blame] | 18 | |
Prashant Bhole | ebbed0f | 2019-02-12 10:25:12 +0900 | [diff] [blame^] | 19 | *OBJECT* := { **map** | **program** | **cgroup** | **perf** | **net** | **feature** } |
Jakub Kicinski | ff69c21 | 2017-10-04 20:10:05 -0700 | [diff] [blame] | 20 | |
Quentin Monnet | 0641c3c | 2017-10-23 09:24:16 -0700 | [diff] [blame] | 21 | *OPTIONS* := { { **-V** | **--version** } | { **-h** | **--help** } |
| 22 | | { **-j** | **--json** } [{ **-p** | **--pretty** }] } |
| 23 | |
Jakub Kicinski | ff69c21 | 2017-10-04 20:10:05 -0700 | [diff] [blame] | 24 | *MAP-COMMANDS* := |
Jakub Kicinski | 0b592b5a | 2018-10-15 16:30:36 -0700 | [diff] [blame] | 25 | { **show** | **list** | **create** | **dump** | **update** | **lookup** | **getnext** |
| 26 | | **delete** | **pin** | **event_pipe** | **help** } |
Jakub Kicinski | ff69c21 | 2017-10-04 20:10:05 -0700 | [diff] [blame] | 27 | |
Jakub Kicinski | 6ebe6db | 2018-01-02 14:48:36 -0800 | [diff] [blame] | 28 | *PROG-COMMANDS* := { **show** | **list** | **dump jited** | **dump xlated** | **pin** |
John Fastabend | b7d3826 | 2018-10-15 11:19:50 -0700 | [diff] [blame] | 29 | | **load** | **attach** | **detach** | **help** } |
Jakub Kicinski | ff69c21 | 2017-10-04 20:10:05 -0700 | [diff] [blame] | 30 | |
Jakub Kicinski | 6ebe6db | 2018-01-02 14:48:36 -0800 | [diff] [blame] | 31 | *CGROUP-COMMANDS* := { **show** | **list** | **attach** | **detach** | **help** } |
Roman Gushchin | 5ccda64 | 2017-12-13 15:18:54 +0000 | [diff] [blame] | 32 | |
Yonghong Song | b04df40 | 2018-05-24 11:21:58 -0700 | [diff] [blame] | 33 | *PERF-COMMANDS* := { **show** | **list** | **help** } |
| 34 | |
Yonghong Song | f6f3bac | 2018-09-05 16:58:06 -0700 | [diff] [blame] | 35 | *NET-COMMANDS* := { **show** | **list** | **help** } |
| 36 | |
Prashant Bhole | ebbed0f | 2019-02-12 10:25:12 +0900 | [diff] [blame^] | 37 | *FEATURE-COMMANDS* := { **probe** | **help** } |
| 38 | |
Jakub Kicinski | ff69c21 | 2017-10-04 20:10:05 -0700 | [diff] [blame] | 39 | DESCRIPTION |
| 40 | =========== |
| 41 | *bpftool* allows for inspection and simple modification of BPF objects |
| 42 | on the system. |
| 43 | |
| 44 | Note that format of the output of all tools is not guaranteed to be |
| 45 | stable and should not be depended upon. |
| 46 | |
Quentin Monnet | a2bc2e5 | 2017-10-23 09:24:06 -0700 | [diff] [blame] | 47 | OPTIONS |
| 48 | ======= |
| 49 | -h, --help |
| 50 | Print short help message (similar to **bpftool help**). |
| 51 | |
| 52 | -v, --version |
| 53 | Print version number (similar to **bpftool version**). |
| 54 | |
Quentin Monnet | 0641c3c | 2017-10-23 09:24:16 -0700 | [diff] [blame] | 55 | -j, --json |
| 56 | Generate JSON output. For commands that cannot produce JSON, this |
| 57 | option has no effect. |
| 58 | |
| 59 | -p, --pretty |
| 60 | Generate human-readable JSON output. Implies **-j**. |
| 61 | |
John Fastabend | c034a17 | 2018-10-15 11:19:55 -0700 | [diff] [blame] | 62 | -m, --mapcompat |
| 63 | Allow loading maps with unknown map definitions. |
| 64 | |
Quentin Monnet | 3322130 | 2018-12-18 10:13:19 +0000 | [diff] [blame] | 65 | -n, --nomount |
| 66 | Do not automatically attempt to mount any virtual file system |
| 67 | (such as tracefs or BPF virtual file system) when necessary. |
| 68 | |
John Fastabend | c034a17 | 2018-10-15 11:19:55 -0700 | [diff] [blame] | 69 | |
Jakub Kicinski | ff69c21 | 2017-10-04 20:10:05 -0700 | [diff] [blame] | 70 | SEE ALSO |
| 71 | ======== |
Quentin Monnet | f98e46a | 2018-11-08 11:52:28 +0000 | [diff] [blame] | 72 | **bpf**\ (2), |
| 73 | **bpf-helpers**\ (7), |
| 74 | **bpftool-prog**\ (8), |
| 75 | **bpftool-map**\ (8), |
| 76 | **bpftool-cgroup**\ (8), |
Quentin Monnet | 49eb7ab | 2019-01-17 15:27:50 +0000 | [diff] [blame] | 77 | **bpftool-feature**\ (8), |
Quentin Monnet | f98e46a | 2018-11-08 11:52:28 +0000 | [diff] [blame] | 78 | **bpftool-net**\ (8), |
| 79 | **bpftool-perf**\ (8) |