[DTrace-devel] [oracle/dtrace-utils] d66ab5: dtrace: BPF program load for '...' failed: No spac...

euloh noreply at github.com
Wed Jan 20 10:45:54 PST 2021


  Branch: refs/heads/2.0-branch-dev
  Home:   https://github.com/oracle/dtrace-utils
  Commit: d66ab5f0035ceed48831c73ad697911c7acc059d
      https://github.com/oracle/dtrace-utils/commit/d66ab5f0035ceed48831c73ad697911c7acc059d
  Author: Eugene Loh <eugene.loh at oracle.com>
  Date:   2021-01-20 (Wed, 20 Jan 2021)

  Changed paths:
    M include/dtrace/options_defines.h
    M libdtrace/dt_bpf.c
    M libdtrace/dt_options.c
    A test/unittest/misc/tst.bpflogsize-cmdline.sh
    A test/unittest/misc/tst.bpflogsize-pragma.sh

  Log Message:
  -----------
  dtrace: BPF program load for '...' failed: No space left on device

A D script that produces BPF code with many code paths can result
in 16 Mbytes of BPF log file, ending with the above error message.
The log file really says nothing about why the BPF load failed.
The actual problem is that we supplied a 16-Mbyte log buffer that
is too small.

If no log buffer is supplied, this problem is not encountered.

Change DTrace's BPF program load to use no log buffer at first.
If the load fails, then retry with a log buffer.  The load should
again fail, but if the failure is not ENOSPC, we can simply report
the log and be done.  If the failure becomes ENOSPC, inform the
user of the problem and what action can be taken to increase the
buffer size.

Provide a new DTrace option to control the log buffer size.

Add tests for this fix.  Specifically, the aggregation function
quantize() can be used, since it must quantize a value into one
of 127 different bins.  The algorithm used has many code paths
and thereby exercises the BPF verifier well.

https://github.com/oracle/dtrace-utils/issues/6
Signed-off-by: Eugene Loh <eugene.loh at oracle.com>
Reviewed-by: Kris Van Hees <kris.van.hees at oracle.com>


  Commit: d53fe3327cdd7cc3bc5f818fe2bac06b9d25a799
      https://github.com/oracle/dtrace-utils/commit/d53fe3327cdd7cc3bc5f818fe2bac06b9d25a799
  Author: Eugene Loh <eugene.loh at oracle.com>
  Date:   2021-01-20 (Wed, 20 Jan 2021)

  Changed paths:
    M libdtrace/dt_aggregate.c

  Log Message:
  -----------
  Clean up "defined but not used" compilation warning

Signed-off-by: Eugene Loh <eugene.loh at oracle.com>
Reviewed-by: Kris Van Hees <kris.van.hees at oracle.com>


Compare: https://github.com/oracle/dtrace-utils/compare/4413e6db035a...d53fe3327cdd



More information about the DTrace-devel mailing list