You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This commit adds a background go execution trace capture mechanism to
CRDB. The execution traces are captured with a duration and interval
set by cluster settings.
When the `obs.execution_tracer.interval` cluster setting is set to a
positive value, the execution tracer will be enabled on every node and
begin capturing traces with duration set by the
`obs.execution_tracer.duration` cluster setting (10s by default). The
traces will be captured in the log directory much like cpu and heap
profiles in a direcory named `executiontrace_dump`. The trace capture
will automatically garbage collect the oldest traces if the total
file size consumed by the execution traces exceeds the value of the
`obs.execution_tracer.total_dump_size_limit` cluster setting (4 GiB
by default).
It is encouraged to leave the dump size limit high, and the trace
capture duration low in order to allow for files that are more easily
consumable in external tools. One gigantic file will be much more
challenging to parse and navigate.
Please note that enabling execution trace capture will incur
a performance penalty. This is currently estimated at 1-2%
(https://go.dev/blog/execution-traces-2024#low-overhead-tracing). No
specific measurements have been made with CRDB at the time of this
commit.
Based on work in #146873
Part of: #97215
Release note (observability change, ops change): A new feature
that captures go execution traces on an automatic schedule is now
available. This feature will incur a performance penalty and customers
will typically use this under the guidance of Cockroach Labs support.
There are 3 cluster settings which manipulate this feature:
- `obs.execution_tracer.interval`: set to >0 to enable the tracer and
capture traces at the given interval.
- `obs.execution_tracer.duration`: sets the time over which each trace
captures data.
- `obs.execution_tracer.total_dump_size_limit` : sets the total amount
of disk space to allow execution traces to take up before the oldest
files are garbage collected automatically.
0 commit comments