From owner-freebsd-dtrace@freebsd.org Wed Oct 31 18:10:19 2018 Return-Path: Delivered-To: freebsd-dtrace@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 92B9810E129F for ; Wed, 31 Oct 2018 18:10:19 +0000 (UTC) (envelope-from longwitz@incore.de) Received: from dss.incore.de (dss.incore.de [195.145.1.138]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2F61D81840; Wed, 31 Oct 2018 18:10:18 +0000 (UTC) (envelope-from longwitz@incore.de) Received: from inetmail.dmz (inetmail.dmz [10.3.0.3]) by dss.incore.de (Postfix) with ESMTP id CEA32139A5; Wed, 31 Oct 2018 19:10:10 +0100 (CET) X-Virus-Scanned: amavisd-new at incore.de Received: from dss.incore.de ([10.3.0.3]) by inetmail.dmz (inetmail.dmz [10.3.0.3]) (amavisd-new, port 10024) with LMTP id AsTMrV7_v9Dn; Wed, 31 Oct 2018 19:10:10 +0100 (CET) Received: from mail.local.incore (fwintern.dmz [10.0.0.253]) by dss.incore.de (Postfix) with ESMTP id F250F1399F; Wed, 31 Oct 2018 19:10:09 +0100 (CET) Received: from bsdmhs.longwitz (unknown [192.168.99.6]) by mail.local.incore (Postfix) with ESMTP id D372817D; Wed, 31 Oct 2018 19:10:09 +0100 (CET) Message-ID: <5BD9F001.9090603@incore.de> Date: Wed, 31 Oct 2018 19:10:09 +0100 From: Andreas Longwitz User-Agent: Thunderbird 2.0.0.19 (X11/20090113) MIME-Version: 1.0 To: Mark Johnston CC: "freebsd-dtrace@freebsd.org" Subject: Re: Why my DTrace script does not work after installing a new kernel without reboot References: <5BD4E965.9040006@incore.de> <20181027225339.GA4191@spy> In-Reply-To: <20181027225339.GA4191@spy> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-dtrace@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "A discussion list for developers working on DTrace in FreeBSD." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 31 Oct 2018 18:10:19 -0000 In the meantime I found the answer to my question. > Does your patch change the layout of the timeout structure? If so, the > problem is that dtrace(1) is using the CTF from kern.bootfile, but that > doesn't match the layout of the structures used by the running kernel. dtrace() gets the CTF of the kernel and kernel modules from the pathbames returned by kldstat(2). In my case they all start with '/boot/kernel/' because the kernel was loaded from that place. This can be veryfied with 'kldstat -v'. The output does not change after buildung a new kernel and the kernel itself does nit use the variable kern.bootfile. -- Andreas Longwitz