Date: Sun, 10 Feb 2013 02:37:01 +0400 From: Andrey Zonov <zont@FreeBSD.org> To: Mark Johnston <markjdb@gmail.com> Cc: freebsd-current@FreeBSD.org, Matt Burke <mattblists@icritical.com> Subject: Re: [patch] Userland DTrace Message-ID: <5116CF8D.4020606@FreeBSD.org> In-Reply-To: <20130209214715.GA1954@oddish> References: <51152216.9080905@icritical.com> <20130209214715.GA1954@oddish>
next in thread | previous in thread | raw e-mail | index | archive | help
[-- Attachment #1 --] On 2/10/13 1:47 AM, Mark Johnston wrote: > On Fri, Feb 08, 2013 at 04:04:38PM +0000, Matt Burke wrote: >> I've been spending some time trying to get the fasttrap provider to work >> on FreeBSD without panicing. I believe I have succeeded, at least to the >> point where it's no longer panicing. >> >> There were two panic causes. The first was >> http://www.freebsd.org/cgi/query-pr.cgi?pr=165541 - the FreeBSD port of >> fasttrap.c caused ftp_rcount to be left >0. To fix this I've got rid of >> the early return and reverted to the opensolaris way. >> >> A second panic then showed up intermittently when fasttrap_pid_cleanup_cb >> was run while something in userland had locks. Using sx_try_xlock calls >> has stopped the panics and shouldn't affect operation AFAICT. > > I've run into this too. It can happen even when I'm not using DTrace > since fasttrap.ko is always loaded on my system. The problem is that > fasttrap_exec_exit() is called every time a process exits in this case; > the caller acquires dtrace_lock, and the panic occurs when a callout > thread tries to acquire the lock at the same time. > >> >> This is against r246454. >> >> >> Although this has fixed the panics for me, I'm finding a lot of stuff just >> isn't actually working, with dtrace and the traced process just chewing >> CPU. Truss on the dtrace shows a heck of a lot of ptrace() calls and I >> have no idea what the target is doing... CPU time is split 2:1 >> dtrace:target > > Another panic can occur with an INVARIANTS kernel if a DTrace victim > process forks. I've supplied a patch which fixes this for me here: > http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/171360 > I think you have to carefully ping George, and if he won't answer go ahead with your patches. Someone has to take care of userland dtrace. -- Andrey Zonov [-- Attachment #2 --] -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.18 (Darwin) Comment: GPGTools - http://gpgtools.org iQEcBAEBAgAGBQJRFs+NAAoJEBWLemxX/CvTpDIIALJLGt6V53ksDmgHLB8jp08Y SpV37mK3MK1hFshV5W7qin4nQSHXdp2LW/sqw/qwn2JzgRULBKO1CVzOSlHRZfYV eNwjQ7qWjzfyjDMm7h1VVNe4MvdVY0CxMeTwF5Hdp0UxzhJTW+tQEiYuO9T3g9by elNRfz8Zts9zl2YaP99XKL5QYzWC07yZN4eT+ceOmhXajAuYwC7h8sPsuwS2tgIH QuNnDILdNRgXvhDBqBE2fi2Lf1ZsJArw8OPv9l6JgfdTGW93piwlimZTMe5k8LEG vwVjZT/zTeoezHPQyB1rfE4m7S0LOJw0jHhaZQyFFsjfNiR3ygWSsg2vZ7vc2MA= =TcxV -----END PGP SIGNATURE-----
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5116CF8D.4020606>
