From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14967 invoked by alias); 1 Dec 2008 22:27:29 -0000 Received: (qmail 14956 invoked by uid 22791); 1 Dec 2008 22:27:28 -0000 X-Spam-Check-By: sourceware.org Received: from smtp-outbound-2.vmware.com (HELO smtp-outbound-2.vmware.com) (65.115.85.73) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 01 Dec 2008 22:26:12 +0000 Received: from mailhost2.vmware.com (mailhost2.vmware.com [10.16.67.167]) by smtp-outbound-2.vmware.com (Postfix) with ESMTP id 82D901B004; Mon, 1 Dec 2008 14:26:09 -0800 (PST) Received: from [10.20.92.151] (promb-2s-dhcp151.eng.vmware.com [10.20.92.151]) by mailhost2.vmware.com (Postfix) with ESMTP id 6803C8E5D1; Mon, 1 Dec 2008 14:26:09 -0800 (PST) Message-ID: <49346409.7010508@vmware.com> Date: Mon, 01 Dec 2008 22:27:00 -0000 From: Michael Snyder User-Agent: Thunderbird 1.5.0.12 (X11/20080411) MIME-Version: 1.0 To: "D. Hugh Redelmeier" CC: "gdb@sourceware.org" Subject: Re: Cannot get thread event message: debugger service failed References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2008-12/txt/msg00001.txt.bz2 D. Hugh Redelmeier wrote: > I'm trying to debug Firefox on Linux. I'm using GDB. Execution of > Firefox is frequently interrupted with this message: > [New Thread 0x44125950 (LWP 30469)] > Cannot get thread event message: debugger service failed > At this point, I enter a "continue" GDB command and execution > proceeds. > > Sometimes the screen locks up until the "continue". So I need to run > GDB somewhere other than the X desktop. > > What is the best way to avoid this problem and get on with debugging > Firefox? (I admit: a quixotic quest.) > > Google finds this for me: > http://sourceware.org/ml/gdb/2006-10/msg00259.html > but I don't see a resolution. > > Some details: > > - I get this message on 64-bit Fedora 9 (on a dual-core machine) and on > 64-bit Ubuntu 8.04 (on a quad core machine) > > - GDB on Fedora 9: gdb-6.8-23.fc9.x86_64 > > - GDB on Ubuntu 8.04: 6.8-1ubuntu3 > > > - I run Firefox this way: Firefox --sync > or: Firefox --sync -no-remote > > - I run gdb later, giving it the executable file and the PID > > - I tell gdb to ignore sigpipe signals: handle SIGPIPE nostop > > - I then let GDB continue Firefox > > - after a small amount of browsing, the dreaded message shows up I have only a few random guesses. 1) Can you try building gdb from sources on your host machine? Could conceivably be some sort of header file issue. 2) We can see where the error message comes from: void check_event in linux-thread-db.c. It's not very informative, it just tells us that the call to td_ta_event_getmsg_p failed. No reason for that suggests itself, other than 1) maybe mis-matched header files 2) maybe privilege issues? Does firefox run as priveleged? I'm guessing that at least parts of it must, otherwise you would not be seeing it taking over and hanging up your X server. If its a privilege issue, can you try running gdb as root? > Sometimes the screen locks up until the "continue". So I need to run > GDB somewhere other than the X desktop. Yeah, this suggests that firefox is grabbing some locks or resources from the X server, which may suggest that it's running privileged. You're already running gdb from a separate pseudo-console, might as well try running it as root as well...