Skip to content

Commit

Permalink
debugging: labs: add hint to make trace-cmd relay setup work with older
Browse files Browse the repository at this point in the history
host tool

Some trainees reported that the perf data file was empty when trying to
display it in kernel shark. The recording actually failed to be pushed
onto the host, with the following error:

Connected with 192.168.0.100:33446
cpus=2
pagesize=4096
trace-cmd: Interrupted system call
  Unsupported file version 7

This error is due to trace-cmd on the host being older enough than the
one on the target to not be able to handle the trace format version used
by the latter.

Fix this issue by forcing the trace format version to an older one.

Signed-off-by: Alexis Lothoré <[email protected]>
  • Loading branch information
Tropicao committed Nov 21, 2024
1 parent 0b73b2f commit e72db85
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,13 @@ \section{ftrace \& uprobes}
^C
\end{bashinput}

{\em Note: if during the recording you encounter an \code{Unsupported file
version 7} error, it likely means that the trace-cmd tool on your
workstation is older than the one on the target, and does not understand
the default trace format used by the target. You can force trace-cmd on the
target to use an older version of the trace data format by also providing
\code{--file-version=6} on the recording command}

Then, using kernelshark tool on the host, analyze the trace:

\begin{bashinput}
Expand Down

0 comments on commit e72db85

Please sign in to comment.