bpftrace fails with BPF_FUNC_get_current_group_id is not available for your kernel version

Solution In Progress - Updated -

Issue

  • bpftrace for traceing cgroup fails with the following errors.

    $ bpftrace -e 'tracepoint:syscalls:sys_enter_openat /cgroup == cgroupid("/sys/fs/cgroup/unified/mycg")/ { printf("%s\n", str(args->filename)); }'
    BPF_FUNC_get_current_group_id is not available for your kernel version
    

Environment

  • Red Hat Enterprise Linux 8
  • bpftrace-0.9-3.el8 or older

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In