public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* Re: gdb/2347: gdb 6.7 can't attach to process
@ 2007-10-26 21:23 drow
  0 siblings, 0 replies; 5+ messages in thread
From: drow @ 2007-10-26 21:23 UTC (permalink / raw)
  To: gdb-prs, nobody, pdubuc

Synopsis: gdb 6.7 can't attach to process

State-Changed-From-To: open->closed
State-Changed-By: drow
State-Changed-When: Fri Oct 26 21:23:55 2007
State-Changed-Why:
    Resolved, thanks.

http://sourceware.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gdb&pr=2347


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: gdb/2347: gdb 6.7 can't attach to process
@ 2007-10-26 21:18 Paul M. Dubuc
  0 siblings, 0 replies; 5+ messages in thread
From: Paul M. Dubuc @ 2007-10-26 21:18 UTC (permalink / raw)
  To: nobody; +Cc: gdb-prs

The following reply was made to PR gdb/2347; it has been noted by GNATS.

From: "Paul M. Dubuc" <pdubuc@cas.org>
To: gdb-gnats@sources.redhat.com
Cc:  
Subject: Re: gdb/2347: gdb 6.7 can't attach to process
Date: Fri, 26 Oct 2007 17:10:06 -0400

 Please close this PR.  I have submitted a new PR on the gcore problem 
 (see 'corefiles/2349').


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: gdb/2347: gdb 6.7 can't attach to process
@ 2007-10-26 19:08 Daniel Jacobowitz
  0 siblings, 0 replies; 5+ messages in thread
From: Daniel Jacobowitz @ 2007-10-26 19:08 UTC (permalink / raw)
  To: nobody; +Cc: gdb-prs

The following reply was made to PR gdb/2347; it has been noted by GNATS.

From: Daniel Jacobowitz <drow@false.org>
To: "Paul M. Dubuc" <pdubuc@cas.org>
Cc: gdb-gnats@sourceware.org
Subject: Re: gdb/2347: gdb 6.7 can't attach to process
Date: Fri, 26 Oct 2007 14:59:35 -0400

 (Please use reply-to-all so that this can be logged in the build system.)
 
 On Fri, Oct 26, 2007 at 02:49:44PM -0400, Paul M. Dubuc wrote:
 > I got the 32-bit version to build by setting --build=i686-redhat-linux instead.
 
 Yes, sorry.  Sometimes you need both.
 
 > Now that I get the 32-bit version built and running, I notice it still has a 
 > problem that we've been having with earlier versions of GDB.  When we attach to 
 > a process and do a gcore, we can't read the resulting core file back in without 
 > the following errors and corrrupt stack trace:
 
 > (gdb) where
 > #0  0xffffe410 in __kernel_vsyscall ()
 
 > (gdb) where
 > #0  0xffffe410 in ?? ()
 
 I assume this is just a missed feature in gcore; it needs to learn
 that it has to dump the vDSO to disk.  64-bit doesn't use a vDSO
 so you do not encounter this bug.
 
 -- 
 Daniel Jacobowitz
 CodeSourcery


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: gdb/2347: gdb 6.7 can't attach to process
@ 2007-10-25 19:08 Daniel Jacobowitz
  0 siblings, 0 replies; 5+ messages in thread
From: Daniel Jacobowitz @ 2007-10-25 19:08 UTC (permalink / raw)
  To: nobody; +Cc: gdb-prs

The following reply was made to PR gdb/2347; it has been noted by GNATS.

From: Daniel Jacobowitz <drow@false.org>
To: pdubuc@cas.org
Cc: gdb-gnats@sources.redhat.com
Subject: Re: gdb/2347: gdb 6.7 can't attach to process
Date: Thu, 25 Oct 2007 15:03:48 -0400

 On Thu, Oct 25, 2007 at 06:43:37PM -0000, pdubuc@cas.org wrote:
 > gdb32 --version
 
 Item 1: A 32-bit GDB executable will not work well under your kernel.
 There are kernel emulation bugs which were not fixed until later.  I
 do not remember exactly when, but some time around 2.6.21.
 
 > This GDB was configured as "--host=x86_64-unknown-linux-gnu --target=i686-redhat-linux". 
 
 Item 2: That means this is a cross debugger.  Don't do that if you
 want something that can "run" or "attach"; just use
 --host=i686-redhat-linux and --host=x86_64-redhat-linux.
 
 That should fix it.
 
 -- 
 Daniel Jacobowitz
 CodeSourcery


^ permalink raw reply	[flat|nested] 5+ messages in thread

* gdb/2347: gdb 6.7 can't attach to process
@ 2007-10-25 18:48 pdubuc
  0 siblings, 0 replies; 5+ messages in thread
From: pdubuc @ 2007-10-25 18:48 UTC (permalink / raw)
  To: gdb-gnats


>Number:         2347
>Category:       gdb
>Synopsis:       gdb 6.7 can't attach to process
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    unassigned
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Thu Oct 25 18:48:01 UTC 2007
>Closed-Date:
>Last-Modified:
>Originator:     Paul M. Dubuc
>Release:        6.7
>Organization:
>Environment:
 uname -a
Linux mrldev32 2.6.9-42.0.10.ELlargesmp #1 SMP Fri Feb 16 17:25:40 EST 2007 x86_64 GNU/Linux

 cat /etc/redhat-release
Red Hat Enterprise Linux AS release 4 (Nahant Update 4)

gdb32 --version
GNU gdb 6.7
Copyright (C) 2007 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "--host=x86_64-unknown-linux-gnu --target=i686-redhat-linux". 

file `which gdb32`
/projects/pmd25/gnu34/Linux/x86_64/bin/gdb32: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), for GNU/Linux 2.2.5, dynamically linked (uses shared libs), not stripped 

gdb64 --version
GNU gdb 6.7
Copyright (C) 2007 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "--host=x86_64-unknown-linux-gnu --target=x86_64-redhat-linux"

file `which gdb64`
/projects/pmd25/gnu34/Linux/x86_64/bin/gdb64: ELF 64-bit LSB executable, AMD x86-64, version 1 (SYSV), for GNU/Linux 2.4.0, dynamically linked (uses shared libs), not stripped
>Description:
I build both a 32 and a 64 bit version of gdb because we run both kinds of processes.  With gdb 6.7, neither version is able to attach to a process of its corresponding type. I'm not sure why the configurator picked x86_64-unknown-linux-gnu instead of x86_64-redhat-linux for the host triplet, but I notice that 'uname -p' says "unknown" for the processor type.  If I'm building these wrong, maybe you can tell me what configuration options to use for these machines.
>How-To-Repeat:
 cat loop.c
main()
{
    while(1) { sleep(10); }
}

 gcc -m32 -g loop.c -o a.out32
 gcc -g loop.c -o a.out64
 file a.out32
a.out32: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), for GNU/Linux 2.2.5, dynamically linked (uses shared libs), not stripped
 file a.out64
a.out64: ELF 64-bit LSB executable, AMD x86-64, version 1 (SYSV), for GNU/Linux 2.4.0, dynamically linked (uses shared libs), not stripped

 ./a.out32 &
 ./a.out64 &

 ps
  PID TTY          TIME CMD
45639 pts/28   00:00:00 ksh
31739 pts/28   00:00:00 a.out64
 6223 pts/28   00:00:00 a.out32
24575 pts/28   00:00:00 ps

 gdb32
GNU gdb 6.7
Copyright (C) 2007 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "--host=x86_64-unknown-linux-gnu --target=i686-redhat-linux".
(gdb) attach 6223
Don't know how to attach.  Try "help target".
(gdb) q

 gdb64
GNU gdb 6.7
Copyright (C) 2007 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "--host=x86_64-unknown-linux-gnu --target=x86_64-redhat-linux".
(gdb) attach 31739
Don't know how to attach.  Try "help target".
(gdb) q
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2007-10-26 21:23 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-10-26 21:23 gdb/2347: gdb 6.7 can't attach to process drow
  -- strict thread matches above, loose matches on Subject: below --
2007-10-26 21:18 Paul M. Dubuc
2007-10-26 19:08 Daniel Jacobowitz
2007-10-25 19:08 Daniel Jacobowitz
2007-10-25 18:48 pdubuc

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).