Skip to content

Conversation

dqminh
Copy link
Contributor

@dqminh dqminh commented Aug 28, 2025

BPF_LOCAL_STORAGE_GET_F_CREATE will create a zero entry if it does not find our cgroup in the CGRP_STORAGE. THis is unnecessary work as the entry should only be written by ebpf_exporter for cgroups that we are interested in, so we should not set the flag.

BPF_LOCAL_STORAGE_GET_F_CREATE will create a zero entry if it does not
find our cgroup in the CGRP_STORAGE. THis is unnecessary work as the entry
should only be written by ebpf_exporter for cgroups that we are
interested in, so we should not set the flag.
Copy link
Contributor

@netoptimizer netoptimizer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Further down you are using the value stored in *ok to select which map to update.
Thus, the BPF_LOCAL_STORAGE_GET_F_CREATE is correctly used here.

@netoptimizer
Copy link
Contributor

Have you seen: netoptimizer#1 (comment)

  • I found that this CGRP_STORAGE was slower than the hash type

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