RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 673696 - gdb: Linux core files should use linux-thread-db.c
Summary: gdb: Linux core files should use linux-thread-db.c
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: gdb
Version: 6.1
Hardware: All
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: Jan Kratochvil
QA Contact: qe-baseos-tools-bugs
URL:
Whiteboard:
Depends On:
Blocks: 673697 697900
TreeView+ depends on / blocked
 
Reported: 2011-01-29 21:19 UTC by Jeremy Eder
Modified: 2018-11-14 13:26 UTC (History)
4 users (show)

Fixed In Version: gdb-7.2-41.el6
Doc Type: Bug Fix
Doc Text:
Multithreaded program can be dumped into a core file. GDB can load core files and display the list of their threads. Previously, GDB displayed only the LWP (light-weight process) identifier for threads found in the core file. With this update, GDB initializes the libthread_db threads debugging library even while accessing a core file and GDB displays for each thread besides LWP also the pthread_t identifier.
Clone Of:
: 673697 697900 (view as bug list)
Environment:
Last Closed: 2011-05-19 13:48:41 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2011:0638 0 normal SHIPPED_LIVE gdb bug fix and enhancement update 2011-05-18 17:55:45 UTC

Description Jeremy Eder 2011-01-29 21:19:24 UTC
This is upstream gdb bz 8210:
http://sourceware.org/bugzilla/show_bug.cgi?id=8210


Description of problem:
Core dumps have no pthread id on them in gdb on RHEL5 and 6.


When looking on a core dump:
(gdb) info threads
  22 process 18110  0x0000003464eccfc2 in select () from /lib64/libc.so.6
  21 process 18111  0x0000003464ed4108 in epoll_wait () from /lib64/libc.so.6

-----
 
When attaching to a running process all is good:
(gdb) info threads
  22 Thread 0x42337940 (LWP 29132)  0x0000003464eccfc2 in select () from /lib64/libc.so.6
  21 Thread 0x42d38940 (LWP 29133)  0x0000003464ed4108 in epoll_wait () from /lib64/libc.so.6

Comment 2 Jan Kratochvil 2011-01-30 19:40:29 UTC
Checked in: gdb-7.2-39.fc14

New testcases:
+PASS: gdb.threads/gcore-thread.exp: print pthread_t of main
+PASS: gdb.threads/gcore-thread.exp: print pthread_t of thread1
+PASS: gdb.threads/gcore-thread.exp: print pthread_t of thread2
+PASS: gdb.threads/gcore-thread.exp: main pthread_self found
+PASS: gdb.threads/gcore-thread.exp: thread1 pthread_self found
+PASS: gdb.threads/gcore-thread.exp: thread2 pthread_self found

Comment 5 Eva Kopalova 2011-04-05 16:01:01 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
GDB did not display pthread_t for threads found in the core. GDB now displays pthread_t for the threads.

Comment 6 Eva Kopalova 2011-04-08 16:15:36 UTC
    Technical note updated. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    Diffed Contents:
@@ -1 +1 @@
-GDB did not display pthread_t for threads found in the core. GDB now displays pthread_t for the threads.+Multithreaded program can be dumped into a core file. GDB can load core files and display the list of their threads. Previously, GDB displayed only the LWP (light-weight process) identifier for threads found in the core file.  With this update, GDB initializes the libthread_db threads debugging library even while accessing a core file and GDB displays for each thread besides LWP also the pthread_t identifier.

Comment 12 errata-xmlrpc 2011-05-19 13:48:41 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2011-0638.html


Note You need to log in before you can comment on or make changes to this bug.