This is the mail archive of the
gdb-prs@sources.redhat.com
mailing list for the GDB project.
gdb/224: GDB gets an error on startup warning: unable to set global thread event mask
- To: gdb-gnats at sources dot redhat dot com
- Subject: gdb/224: GDB gets an error on startup warning: unable to set global thread event mask
- From: tdifilippo at bloomberg dot net
- Date: 12 Oct 2001 19:53:16 -0000
- Reply-To: tdifilippo at bloomberg dot net
>Number: 224
>Category: gdb
>Synopsis: GDB gets an error on startup warning: unable to set global thread event mask
>Confidential: no
>Severity: serious
>Priority: high
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Fri Oct 12 12:58:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator: tdifilippo@bloomberg.net
>Release: GDB 5.0
>Organization:
>Environment:
LINUX on an Intel Pentium 4
>Description:
When I attempt to debug my application, which is a multiple thread application using P-Threads, I can't seem to get GDB to properly connect / debug this application. I have tested this version (GDB 5.0) the version that is packaged with LINUX 7.1 also gets this same error. A much older version, does appear to work properly. This version (5.0) does the following at startup : (The name of my app is "igwy")
gdb igwy
GNU gdb 5.0
Copyright 2000 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i686-pc-linux-gnu"...rw_common (): write: No such file or directory.
warning: unable to set global thread event mask
[New Thread 1024 (active)]
rw_common (): write: No such file or directory.
warning: stop_or_attach_thread: generic error
If I try to debug the application by entering "run", it creates a bunch of my threads, but then does the following :
[1]+ Stopped gdb igwy
And then finally :
[root@i561 cp]#
(It returns to the prompt)
At that point, if I do a ps -ef, my threads are still executing as well as the gdb thread :
ps -ef
#
root 1311 1256 0 15:11 ttyS1 00:00:03 gdb igwy
root 1314 1311 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1315 1314 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1316 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1317 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1318 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1319 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1320 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1321 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1322 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1323 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1324 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1325 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1326 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1327 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1328 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1329 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1330 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1331 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1332 1315 0 15:27 ttyS1 00:00:00 /home/cp/igwy
root 1333 1315 0 15:27 ttyS1 0:00:00 /home/cp/igwy
root 1334 1315 0 15:27 ttyS1 0:00:00 /home/cp/igwy
root 1335 1315 0 15:27 ttyS1 0:00:00 /home/cp/igwy
root 1336 1315 0 15:27 ttyS1 0:00:00 /home/cp/igwy
If I try to debug, and execute by running gdb, and attaching a running thread, the following happens :
[root@i561 cp]# gdb igwy 1314
GNU gdb 5.0
Copyright 2000 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i686-pc-linux-gnu"...rw_common (): write: No such file or directory.
warning: unable to set global thread event mask
[New Thread 1024 (active)]
rw_common (): write: No such file or directory.
warning: stop_or_attach_thread: generic error
/home/cp/1314: No such file or directory.
Attaching to program: /home/cp/igwy, Thread 1314
ptrace: Operation not permitted.
(gdb)
(gdb)
If I tried to attach the gdb thread, the console then locks up
[root@i561 cp]# gdb igwy 1314
GNU gdb 5.0
Copyright 2000 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i686-pc-linux-gnu"...rw_common (): write: No such file or directory.
warning: unable to set global thread event mask
[New Thread 1024 (active)]
rw_common (): write: No such file or directory.
warning: stop_or_attach_thread: generic error
/home/cp/1314: No such file or directory.
Attaching to program: /home/cp/igwy, Thread 1314
ptrace: Operation not permitted.
(gdb)
(gdb)
write: No such file or directory.
What is wrong? I got the newest GDB (5.0); the newest kernel (2.4.10); the newest C /libs (3.0)
>How-To-Repeat:
If need be, I will be happy to send you my executables ... don't know if/how it will help. FYI my executable "igwy" does execute by itself!
>Fix:
Don't know ... what causes this! Don't know how to fix it!
>Release-Note:
>Audit-Trail:
>Unformatted: