From owner-freebsd-current@FreeBSD.ORG Mon Oct 18 18:45:31 2010 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E385B106566B for ; Mon, 18 Oct 2010 18:45:31 +0000 (UTC) (envelope-from rpaulo@freebsd.org) Received: from karen.lavabit.com (karen.lavabit.com [72.249.41.33]) by mx1.freebsd.org (Postfix) with ESMTP id A6CDA8FC1A for ; Mon, 18 Oct 2010 18:45:31 +0000 (UTC) Received: from c.earth.lavabit.com (c.earth.lavabit.com [192.168.111.12]) by karen.lavabit.com (Postfix) with ESMTP id DEB4111B809; Mon, 18 Oct 2010 13:45:30 -0500 (CDT) Received: from rui-macbook.lan (bl17-136-196.dsl.telepac.pt [188.82.136.196]) by lavabit.com with ESMTP id HN9SC07LSPX4; Mon, 18 Oct 2010 13:45:30 -0500 References: In-Reply-To: Mime-Version: 1.0 (Apple Message framework v1081) Content-Type: text/plain; charset=iso-8859-1 Message-Id: Content-Transfer-Encoding: quoted-printable From: Rui Paulo Date: Mon, 18 Oct 2010 19:45:27 +0100 To: =?iso-8859-1?Q?Istv=E1n?= X-Mailer: Apple Mail (2.1081) Cc: freebsd-current Subject: Re: DTrace bindings are missing in FreeBSD 9.0 - CURRENT for userland apps X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 18 Oct 2010 18:45:32 -0000 On 12 Oct 2010, at 23:40, Istv=E1n wrote: > Hey, >=20 >=20 > I am not 100% sure this is the right list to approach with this = problem but > let's try this one. >=20 > So I am trying to use dtrace on the previously mentioned system, I = followed > the usual kernel rebuild process using the following wiki: >=20 > http://wiki.freebsd.org/DTrace >=20 > Dtrace works fine and I am able to trace the kernel.[1] >=20 >=20 > My problem is: I can't trace any user land application including = PostgreSQL > and Ruby. >=20 > I added the following lines to the /etc/make.conf as it is written in = the > wiki: >=20 > STRIP=3D > CFLAGS+=3D-fno-omit-frame-pointer >=20 > I compiled both of the softwares and trying to trace them but there = are no > bindings in the dtrace -l ouput >=20 >=20 > # dtrace -l | grep -i ruby >=20 > i might have overlooked something important but not sure what. >=20 > Any help is appreciated. Pls cc my email since i am not on this list. >=20 >=20 > Thank you in advance. >=20 > I. >=20 > 1. >=20 > [root@freebsd9 ~]# uname -a > FreeBSD freebsd9 9.0-CURRENT FreeBSD 9.0-CURRENT #0: Fri Oct 8 = 21:09:20 UTC > 2010 root@freebsd9:/usr/obj/usr/src/sys/DTRACE amd64 > [root@freebsd9 ~]# kldstat > Id Refs Address Size Name > 1 26 0xffffffff80100000 f49bb0 kernel > 2 1 0xffffffff81212000 ad8 dtraceall.ko > 3 1 0xffffffff81213000 4a59 profile.ko > 4 11 0xffffffff81218000 3e2f opensolaris.ko > 5 3 0xffffffff8121c000 3db0 cyclic.ko > 6 9 0xffffffff81220000 13af4b dtrace.ko > 7 1 0xffffffff8135b000 fce0 systrace.ko > 8 1 0xffffffff8136b000 4128 sdt.ko > 9 1 0xffffffff81370000 44b8 lockstat.ko > 10 1 0xffffffff81375000 b94e fasttrap.ko > 11 1 0xffffffff81381000 61ab fbt.ko > 12 1 0xffffffff81388000 4a67 dtnfsclient.ko > 13 1 0xffffffff8138d000 4118 dtmalloc.ko > [root@freebsd9 ~]# >=20 > [root@freebsd9 ~]# cat d.d > vfs:namecache:enter:done > { >=20 > @distribution =3D quantize(strlen((string)arg1)); > } > [root@freebsd9 ~]# dtrace -s d.d > dtrace: script 'd.d' matched 1 probe > ^C >=20 >=20 > value ------------- Distribution ------------- count > 2 | 0 > 4 |@@@@@@@ 1 > 8 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 5 > 16 | 0 >=20 >=20 >=20 The Ruby port doesn't have DTrace support, but the PostgreSQL port has a = DTrace option (only the latest postgresql port). Regards, -- Rui Paulo