Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pid namespace support #5101

Merged
merged 2 commits into from
Sep 8, 2024
Merged

Pid namespace support #5101

merged 2 commits into from
Sep 8, 2024

Conversation

pagict
Copy link
Contributor

@pagict pagict commented Sep 7, 2024

inspired by the

struct bpf_pidns_info ns = {};

if the cpudist runs in a pid namespace, the filtered pid/tgid are not as expected.
since the kernel does not provide something like iint bpf_get_ns_pid_tgid(u64 dev, u64 ino, struct bpf_pidns_info * ns_data, u32 size), we can create the mapping for the current, then find out the mapped ns pid by the real pid whenever the prev is refered.

@yonghong-song yonghong-song merged commit 9f3d0df into iovisor:master Sep 8, 2024
12 checks passed
dkruces pushed a commit to dkruces/bcc that referenced this pull request Nov 28, 2024
cpudist.py supports run in pid namespace
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants