Skip to content

DNS (and other) events unattributed: PEM can't read cgroup.procs (empty container-id in cri-containerd-.scope path) -> upid_to_pod_name empty #80

Description

@entlein

Recurring: ~73% of dns_events have empty pod despite a valid upid

Live on rig 6a4ce480 (k3s, node-01). px.DataFrame('dns_events')px.upid_to_pod_name(df.upid) is empty for ~73% of rows (client-side, remote_addr=coredns clusterIP 10.43.0.10:53, local_addr empty).

Not a capture gap — a metadata gap

The upid is present (e.g. 00000006-0004-543f-0000-0000001acf92), but upid_to_pod_name returns "". Root cause is in the PEM logs:

state_manager.cc:276 Failed to read PID info for pod=<uid>, cid=
  [msg=Failed to open file /sys/fs/cgroup/kubepods.slice/kubepods-besteffort.slice/
       kubepods-besteffort-pod<uid>.slice/cri-containerd-.scope/cgroup.procs]

Note cri-containerd-.scope — the container-id segment is empty. So the PEM builds a malformed cgroup path, can't enumerate that pod's PIDs, and every event carrying one of those PIDs (DNS heavily, since resolver PIDs churn) is left unattributed. local_addr is also empty for UDP DNS, and remote is the coredns service IP, so there's no query-side rescue either.

Ask

Fix the container-id resolution for the cgroup path (the cri-containerd-<cid>.scope construction) so PID->pod mapping populates. This regresses on every fresh k3s rig. Happy to run any probe query live. — dx-agent

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions