Skip to content

Troubleshooting

Outcome: the surprises every bandwhich user meets, each as a symptom with the check that names it and the fix that follows. Most of these happened in this guide's lab, and the entry says so; each fix is a chapter that already exists — this page is the index of mishaps.

"Insufficient permissions to listen on network interface(s)"

The privilege is missing (chapter 4). Check: are you running under sudo, or has the binary been given the four capabilities (getcap $(command -v bandwhich) shows them)? If neither, grant one. If both are in place and it still refuses, suspect the environment: containers and sandboxes can exclude the capture capabilities from the ceiling every process runs under, in which case no grant from inside can work — the lab's transcript t01 shows that exact case, ceiling decoded capability by capability. Fall back to ss -tnp (chapter 11) and note the limit as the environment's, not yours.

"Cannot find interface …"

The name is wrong, or the interface is down. Check: ip link lists the names this machine actually has (lo, eth0, wlan0, and less obvious ones). Interface names are not portable between machines — the lab's sandbox called its real interface host0. This error arrives before any permission question (transcript t10), so a refusal naming an interface is never about privilege.

"Failed to get stdout … use the --raw flag"

You asked for the drawn display with output going somewhere that is not a terminal — a pipe, a file, a script (transcript t10). Fix: add --raw (chapter 7). There is no flag to force the drawn tables into a file; the raw lines are the file format.

"The process I care about says <UNKNOWN>"

The matcher lost the join (chapter 9). Usual causes, in order: the process exited before it could be scanned (short-lived tools do this routinely — the lab's 0.060-second client did); the packets are a closing connection's tail, which outlives its socket entry; or the socket is owned by a process whose /proc entries you may not read, which points back at the privilege grant's cap_sys_ptrace half. Check: run the traffic again, longer, and look while it is mid-flight (ss -tnp shows the owner independently). A small <UNKNOWN> row beside a healthy transfer is normal; a large one means the traffic's owner is genuinely not on this machine's process list — a tunnel (chapter 9) is the usual truth.

"My download shows as upload — and download is zero"

You are watching loopback, or traffic to a service on the same machine (chapters 6 and 10). Both ends are local, so every packet's source is local and lands in the "up" column. Fix: read the pair of process rows — the sender's row carries the flow — and use a remote address outside this machine when you need the direction split to mean something.

"The rate is impossible — bigger than my connection"

Three honest ways this happens, all in chapter 10: the smoothing window overshoots at the start of a fast transfer (the lab saw 2,501,702 for a flow limited to 2 MiB per second); a burst's held figure outlives the burst (the same impossible number repeating digit for digit is the tell); or you are adding both ends of a same-machine conversation, counting bytes twice. Check: watch three refreshes. A real rate breathes; a held or doubled one explains itself by standing still or by appearing in two rows at once.

"The process vanished but its numbers are still there"

Not vanished — remembered. After a process's last byte, the sampler's window keeps it listed with connections: 0 and a decaying rate for a few refreshes (transcript t03). Check the connection count before concluding anything is still sending.

"No names, only addresses"

Resolution is off (-n in your command or script), or the lookups are failing, or they simply have not landed yet — names arrive a refresh or two behind the traffic (chapter 8, transcript t05). Check: run once without -n and wait. If names never come, the resolver your machine uses cannot answer reverse lookups for those addresses, and the addresses remain the facts to work with.

"The table I want is not on screen"

The window is too small for all three (chapter 4): the display drops tables to fit. Fix: widen the terminal, or ask for the one table directly with --processes, --connections, or --addresses (chapter 7).