See what your computer is doing with Ftrace utilities

Abstract

Ftrace is the official tracer of the Linux kernel. It allows you to see what is happening in the black box that the applications sit on. Ftrace is a very powerful tool, but like all tools, it is useless if you don't know how to use it, or even know its full potential. This tutorial will teach you how to use Ftrace from the command line (all major distributions have Ftrace enabled), as well as how to use trace-cmd and finally, if time allows, the new KernelShark. trace-cmd and KernelShark can be easily downloaded from Steven's git repository on kernel.org (best to get the latest even though your distribution may have an older version available). Steven will first walk you through some of the main commands to display how Ftrace can show you how your applications are being scheduled in, how many page faults they are taking, and even see what other applications may be interfering with your main application. Some of these can be used to see if there's any rouge applications running on your system. Then Steven will walk you through how to use trace-cmd as it allows you to have even more flexibility with its post processing analysis. Finally, an introduction to the new KernelShark, which shows a graphic display of the data that you have retrieved.

Presented by

    Steven Rostedt

    Steven has been working on the Linux kernel since 1998 (started while working on his masters). He has been working on the Linux kernel professionally since 2001. Steven is one of the original developers of the PREEMPT_RT patch which turns Linux into a true real-time operating system. Steven is also the original developer and current maintainer of Ftrace (the official tracer of the Linux kernel). Steven has also created an open source user space tool to interact with Ftrace called trace-cmd, and a GUI for that tool called KernelShark. Steven is now leading a development to rewrite KernelShark and extend it beyond just the Linux kernel. Steven has given talks all over the world on various aspects of Linux. He is part of the Linux Foundation Technical Advisory Board, and on the Linux Plumbers Program Committee. Currently Steven works for VMware as an Open Source Engineer, promoting Open Source both inside and outside the company.