From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33315) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WG9Lm-00067Q-Hr for qemu-devel@nongnu.org; Wed, 19 Feb 2014 10:46:22 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WG9Lh-0005gE-U3 for qemu-devel@nongnu.org; Wed, 19 Feb 2014 10:46:18 -0500 Received: from mx1.redhat.com ([209.132.183.28]:11757) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WG9Lh-0005g4-KU for qemu-devel@nongnu.org; Wed, 19 Feb 2014 10:46:13 -0500 From: Stefan Hajnoczi Date: Wed, 19 Feb 2014 16:45:57 +0100 Message-Id: <1392824759-7093-5-git-send-email-stefanha@redhat.com> In-Reply-To: <1392824759-7093-1-git-send-email-stefanha@redhat.com> References: <1392824759-7093-1-git-send-email-stefanha@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: [Qemu-devel] [PULL 4/6] Update documentation for LTTng ust tracing List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Peter Maydell , =?UTF-8?q?Llu=C3=ADs=20Vilanova?= , Anthony Liguori From: Mohamad Gebai Signed-off-by: Mohamad Gebai Reviewed-by: Alex Benn=C3=A9e Signed-off-by: Stefan Hajnoczi --- docs/tracing.txt | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/docs/tracing.txt b/docs/tracing.txt index bfc261b..bf2e15c 100644 --- a/docs/tracing.txt +++ b/docs/tracing.txt @@ -214,6 +214,42 @@ The "ust" backend uses the LTTng Userspace Tracer li= brary. There are no monitor commands built into QEMU, instead UST utilities should be used t= o list, enable/disable, and dump traces. =20 +Package lttng-tools is required for userspace tracing. You must ensure t= hat the +current user belongs to the "tracing" group, or manually launch the +lttng-sessiond daemon for the current user prior to running any instance= of +QEMU. + +While running an instrumented QEMU, LTTng should be able to list all ava= ilable +events: + + lttng list -u + +Create tracing session: + + lttng create mysession + +Enable events: + + lttng enable-event qemu:g_malloc -u + +Where the events can either be a comma-separated list of events, or "-a"= to +enable all tracepoint events. Start and stop tracing as needed: + + lttng start + lttng stop + +View the trace: + + lttng view + +Destroy tracing session: + + lttng destroy + +Babeltrace can be used at any later time to view the trace: + + babeltrace $HOME/lttng-traces/mysession--