From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29907 invoked by alias); 20 Dec 2019 06:47:40 -0000 Mailing-List: contact systemtap-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: systemtap-owner@sourceware.org Received: (qmail 8390 invoked by uid 48); 20 Dec 2019 06:47:30 -0000 From: "agentzh at gmail dot com" To: systemtap@sourceware.org Subject: [Bug tapsets/25290] process(EXE).begin may occasionally miss already-running target processes from EXE Date: Fri, 20 Dec 2019 06:47:00 -0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: systemtap X-Bugzilla-Component: tapsets X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: agentzh at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: systemtap at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2019-q4/txt/msg00085.txt.bz2 https://sourceware.org/bugzilla/show_bug.cgi?id=3D25290 --- Comment #2 from agentzh --- Okay, with fche's guidance on IRC, I've narrowed it down to a race condition that the utrace process.begin callback would be invoked when the stap sessi= ons state is still STAP_SESSION_STARTING instead of STAP_SESSION_RUNNING occasionally. As per fche's suggestion on IRC, I'd propose the following patch to fix thi= s: https://pastebin.com/WumwHdAT I've tested this patch myself on 3.10 kernels from CentOS, 4.15 kernels from Ubuntu and 5.0 kernels from Fedora. And it's quite stable now. Also tested = the process(EXE).end and process(EXE).thread.{begin,end} probes. All look fine = now. Feedback welcome! Thanks! --=20 You are receiving this mail because: You are the assignee for the bug.