Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #67975 > unrolled thread

gdb unable to read python frame information

Started byWesley <nispray@gmail.com>
First post2014-03-06 18:03 -0800
Last post2014-03-09 14:37 -0400
Articles 20 on this page of 25 — 6 participants

Back to article view | Back to comp.lang.python


Contents

  gdb unable to read python frame information Wesley <nispray@gmail.com> - 2014-03-06 18:03 -0800
    Re: gdb unable to read python frame information dieter <dieter@handshake.de> - 2014-03-07 08:10 +0100
      Re: gdb unable to read python frame information Wesley <nispray@gmail.com> - 2014-03-07 02:29 -0800
        Re: gdb unable to read python frame information Ned Deily <nad@acm.org> - 2014-03-07 12:47 -0800
          Re: gdb unable to read python frame information Wesley <nispray@gmail.com> - 2014-03-08 05:31 -0800
            Re: gdb unable to read python frame information Wesley <nispray@gmail.com> - 2014-03-08 06:55 -0800
        Re: gdb unable to read python frame information dieter <dieter@handshake.de> - 2014-03-08 07:45 +0100
    Re: gdb unable to read python frame information Neal Becker <ndbecker2@gmail.com> - 2014-03-07 08:23 -0500
      Re: gdb unable to read python frame information Wesley <nispray@gmail.com> - 2014-03-08 05:32 -0800
        Re: gdb unable to read python frame information Mark Lawrence <breamoreboy@yahoo.co.uk> - 2014-03-08 14:14 +0000
          Re: gdb unable to read python frame information Wesley <nispray@gmail.com> - 2014-03-08 07:01 -0800
            Re: gdb unable to read python frame information dieter <dieter@handshake.de> - 2014-03-10 08:13 +0100
    Re: gdb unable to read python frame information Wesley <nispray@gmail.com> - 2014-03-08 19:49 -0800
      Re: gdb unable to read python frame information Mark Lawrence <breamoreboy@yahoo.co.uk> - 2014-03-09 14:57 +0000
        Re: gdb unable to read python frame information Wesley <nispray@gmail.com> - 2014-03-09 18:06 -0700
          Re: gdb unable to read python frame information Mark Lawrence <breamoreboy@yahoo.co.uk> - 2014-03-10 01:48 +0000
            Re: gdb unable to read python frame information Wesley <nispray@gmail.com> - 2014-03-09 19:54 -0700
              Re: gdb unable to read python frame information Mark Lawrence <breamoreboy@yahoo.co.uk> - 2014-03-10 03:11 +0000
              Re: gdb unable to read python frame information dieter <dieter@handshake.de> - 2014-03-10 08:28 +0100
                Re: gdb unable to read python frame information Wesley <nispray@gmail.com> - 2014-03-10 18:43 -0700
                  Re: gdb unable to read python frame information dieter <dieter@handshake.de> - 2014-03-11 08:28 +0100
                Re: gdb unable to read python frame information Wesley <nispray@gmail.com> - 2014-03-10 20:01 -0700
                  Re: gdb unable to read python frame information dieter <dieter@handshake.de> - 2014-03-11 08:31 +0100
          Re: gdb unable to read python frame information dieter <dieter@handshake.de> - 2014-03-10 08:16 +0100
      Re: gdb unable to read python frame information Terry Reedy <tjreedy@udel.edu> - 2014-03-09 14:37 -0400

Page 1 of 2  [1] 2  Next page →


#67975 — gdb unable to read python frame information

FromWesley <nispray@gmail.com>
Date2014-03-06 18:03 -0800
Subjectgdb unable to read python frame information
Message-ID<0b7f74c8-9c70-4950-b431-6c9bbb3f0058@googlegroups.com>
Hi guys,
  My env: centos 6.5 64 bit; gdb 7.1; python 2.6.6

I wanna use gdb to attach my running python scripts.
Successfully import libpython in gdb, but seems all py operations failed to read python information.

Here is the snippet:
(gdb) python
>import libpython
>end
(gdb) py-bt
#3 (unable to read python frame information)
#5 (unable to read python frame information)
#7 (unable to read python frame information)
#9 (unable to read python frame information)
#18 (unable to read python frame information)
#22 (unable to read python frame information)
#26 (unable to read python frame information)
#28 (unable to read python frame information)
#29 (unable to read python frame information)
#38 (unable to read python frame information)
#39 (unable to read python frame information)
#40 (unable to read python frame information)
#42 (unable to read python frame information)
#44 (unable to read python frame information)
#45 (unable to read python frame information)
#47 (unable to read python frame information)
#49 (unable to read python frame information)
#51 (unable to read python frame information)
#55 (unable to read python frame information)
#62 (unable to read python frame information)
#64 (unable to read python frame information)
#76 (unable to read python frame information)
#88 (unable to read python frame information)
#100 (unable to read python frame information)
(gdb) py-locals
Unable to read information on python frame
(gdb) 

Is there anything wrong?
Thanks.
Wesley

[toc] | [next] | [standalone]


#67979

Fromdieter <dieter@handshake.de>
Date2014-03-07 08:10 +0100
Message-ID<mailman.7889.1394176233.18130.python-list@python.org>
In reply to#67975
Wesley <nispray@gmail.com> writes:

> I wanna use gdb to attach my running python scripts.
> Successfully import libpython in gdb, but seems all py operations failed to read python information.
>
> Here is the snippet:
> (gdb) python
>>import libpython
>>end
> (gdb) py-bt
> #3 (unable to read python frame information)
> #5 (unable to read python frame information)

The simplest possible interpretation would be that your
Python lacks debugging symbols. That often happens with
system installed Python installations (which usually are stripped
to the bare minimal symbol set - as "normal" users do not need
debugging).

Try with a Python that you have generated yourself.

[toc] | [prev] | [next] | [standalone]


#67987

FromWesley <nispray@gmail.com>
Date2014-03-07 02:29 -0800
Message-ID<c583c21d-d0a2-449a-93e2-37db713b33ed@googlegroups.com>
In reply to#67979
Then, how to make python get debug symbols? 

Install python from source with some special configure options?

[toc] | [prev] | [next] | [standalone]


#68007

FromNed Deily <nad@acm.org>
Date2014-03-07 12:47 -0800
Message-ID<mailman.7907.1394225249.18130.python-list@python.org>
In reply to#67987
In article <c583c21d-d0a2-449a-93e2-37db713b33ed@googlegroups.com>,
 Wesley <nispray@gmail.com> wrote:
> Then, how to make python get debug symbols? 
> 
> Install python from source with some special configure options?

If your distribution doesn't have a debug version of Python and you need 
to build your own, add --with-pydebug to your ./configure options.  See:

./configure --help

-- 
 Ned Deily,
 nad@acm.org

[toc] | [prev] | [next] | [standalone]


#68035

FromWesley <nispray@gmail.com>
Date2014-03-08 05:31 -0800
Message-ID<25473c34-fbc6-4e81-ad6d-c86f12f7b72e@googlegroups.com>
In reply to#68007
1. install gdb from source with configure option --with-python

2. install python from source with configure option --with-pydebug

3. Got error in gdb here:
2.6.6 (r266:84292, Jan 22 2014, 09:42:36) 
[GCC 4.4.7 20120313 (Red Hat 4.4.7-4)]
(gdb) py-bt
Undefined command: "py-bt".  Try "help".
(gdb) python
>import libpython
>end
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/usr/local/share/gdb/python/libpython.py", line 49, in <module>
    _type_size_t = gdb.lookup_type('size_t')
gdb.error: No type named size_t.
Error while executing Python code.
(gdb) 

[toc] | [prev] | [next] | [standalone]


#68042

FromWesley <nispray@gmail.com>
Date2014-03-08 06:55 -0800
Message-ID<6b804c8f-2bd9-45cb-95e4-6c8524de5a28@googlegroups.com>
In reply to#68035
Now I use gdb python -p <pid>
then, import libpython
py-bt is null, py-locals raise here:
Unable to locate python frame

What's going on...

[toc] | [prev] | [next] | [standalone]


#68024

Fromdieter <dieter@handshake.de>
Date2014-03-08 07:45 +0100
Message-ID<mailman.7921.1394261170.18130.python-list@python.org>
In reply to#67987
Wesley <nispray@gmail.com> writes:

> Install python from source with some special configure options?

When I last generated Python from source, there was no need
to do anything special to get debugging symbols (the option
("gcc") option "-g" was automatically included).

[toc] | [prev] | [next] | [standalone]


#67996

FromNeal Becker <ndbecker2@gmail.com>
Date2014-03-07 08:23 -0500
Message-ID<mailman.7900.1394198618.18130.python-list@python.org>
In reply to#67975
dieter wrote:

> Wesley <nispray@gmail.com> writes:
> 
>> I wanna use gdb to attach my running python scripts.
>> Successfully import libpython in gdb, but seems all py operations failed to
>> read python information.
>>
>> Here is the snippet:
>> (gdb) python
>>>import libpython
>>>end
>> (gdb) py-bt
>> #3 (unable to read python frame information)
>> #5 (unable to read python frame information)
> 
> The simplest possible interpretation would be that your
> Python lacks debugging symbols. That often happens with
> system installed Python installations (which usually are stripped
> to the bare minimal symbol set - as "normal" users do not need
> debugging).
> 
> Try with a Python that you have generated yourself.

You probably need to install the python-debuginfo package

[toc] | [prev] | [next] | [standalone]


#68037

FromWesley <nispray@gmail.com>
Date2014-03-08 05:32 -0800
Message-ID<73e3cfa2-28d3-4647-8a7f-577e41dffbd1@googlegroups.com>
In reply to#67996
python debuginfo is installed...
Still,py-bt, py-locals.etc cannot read python frame

[toc] | [prev] | [next] | [standalone]


#68040

FromMark Lawrence <breamoreboy@yahoo.co.uk>
Date2014-03-08 14:14 +0000
Message-ID<mailman.7932.1394288074.18130.python-list@python.org>
In reply to#68037
On 08/03/2014 13:32, Wesley wrote:
> python debuginfo is installed...
> Still,py-bt, py-locals.etc cannot read python frame
>

If you don't provide context people are less likely to help you.

-- 
My fellow Pythonistas, ask not what our language can do for you, ask 
what you can do for our language.

Mark Lawrence

---
This email is free from viruses and malware because avast! Antivirus protection is active.
http://www.avast.com

[toc] | [prev] | [next] | [standalone]


#68043

FromWesley <nispray@gmail.com>
Date2014-03-08 07:01 -0800
Message-ID<6dc8a38d-d3a6-44fd-8f39-f73cea1ac4c1@googlegroups.com>
In reply to#68040
So, let me clarify here, in order to try, I get a clean machine.

Centos 6.5 64bit.
Now , I try this:
1. install gdb 7.7 from source , with configure option --with-python

2. install python 2.6.6 from source, with configure option --with-pydebug

3. run a python script

4. from command line, gdb python -p <pid> to attach the running script

5. within gdb, issue python, import libpython, end 
  no errors
6. py-bt outputs nothing, py-locals says Unable to locate python frame
here is the snippet:
[root@localhost Python-2.6.6]# gdb python 52315
GNU gdb (GDB) 7.7
Copyright (C) 2014 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 "x86_64-unknown-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from python...done.
Attaching to program: /home/nipen/test/Python-2.6.6/python, process 52315
Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib64/ld-linux-x86-64.so.2
0x00000030a98e15c3 in ?? ()
(gdb) bt
#0  0x00000030a98e15c3 in ?? ()
#1  0x00007f4cf68d1219 in ?? ()
#2  0x0000000000000000 in ?? ()
(gdb) py-bt
Undefined command: "py-bt".  Try "help".
(gdb) python
>import libpython
>end
(gdb) py-bt
(gdb) 
(gdb) py-locals
Unable to locate python frame
(gdb) 
Unable to locate python frame

[toc] | [prev] | [next] | [standalone]


#68122

Fromdieter <dieter@handshake.de>
Date2014-03-10 08:13 +0100
Message-ID<mailman.7979.1394435643.18130.python-list@python.org>
In reply to#68043
Wesley <nispray@gmail.com> writes:

> So, let me clarify here, in order to try, I get a clean machine.
>
> Centos 6.5 64bit.
> Now , I try this:
> 1. install gdb 7.7 from source , with configure option --with-python
>
> 2. install python 2.6.6 from source, with configure option --with-pydebug
>
> 3. run a python script
>
> 4. from command line, gdb python -p <pid> to attach the running script
>
> 5. within gdb, issue python, import libpython, end 
>   no errors
> 6. py-bt outputs nothing, py-locals says Unable to locate python frame
> here is the snippet:
> [root@localhost Python-2.6.6]# gdb python 52315
> GNU gdb (GDB) 7.7
> ....
> Attaching to program: /home/nipen/test/Python-2.6.6/python, process 52315
> Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols found)...done.
> Loaded symbols for /lib64/ld-linux-x86-64.so.2
> 0x00000030a98e15c3 in ?? ()
> (gdb) bt
> #0  0x00000030a98e15c3 in ?? ()
> #1  0x00007f4cf68d1219 in ?? ()
> #2  0x0000000000000000 in ?? ()

This looks like a very strange backtrace on C level as well.

The most natural explanation would be: your process is in a very strange
state (due to some C level problem). But, of course, your
"gdb" might have general problems, as well.

[toc] | [prev] | [next] | [standalone]


#68068

FromWesley <nispray@gmail.com>
Date2014-03-08 19:49 -0800
Message-ID<9c70d96c-3ab4-436c-aa90-82f47756ed6c@googlegroups.com>
In reply to#67975
Anybody has suggestions?

This really makes me crazy...

[toc] | [prev] | [next] | [standalone]


#68082

FromMark Lawrence <breamoreboy@yahoo.co.uk>
Date2014-03-09 14:57 +0000
Message-ID<mailman.7955.1394377206.18130.python-list@python.org>
In reply to#68068
On 09/03/2014 03:49, Wesley wrote:
> Anybody has suggestions?
>
> This really makes me crazy...
>

What makes you crazy?  You keep sending messages with no context.  We 
might be smart, but we're not (yet :) mind readers.

-- 
My fellow Pythonistas, ask not what our language can do for you, ask 
what you can do for our language.

Mark Lawrence

---
This email is free from viruses and malware because avast! Antivirus protection is active.
http://www.avast.com

[toc] | [prev] | [next] | [standalone]


#68111

FromWesley <nispray@gmail.com>
Date2014-03-09 18:06 -0700
Message-ID<00b321ae-2fb9-4360-93e4-e7f376444029@googlegroups.com>
In reply to#68082
What's information do you want?

I told the OS, gdb and python version.

And my operation steps.

What do you want more, then, I can type here.

Wesley

[toc] | [prev] | [next] | [standalone]


#68112

FromMark Lawrence <breamoreboy@yahoo.co.uk>
Date2014-03-10 01:48 +0000
Message-ID<mailman.7976.1394416133.18130.python-list@python.org>
In reply to#68111
On 10/03/2014 01:06, Wesley wrote:
> What's information do you want?
>
> I told the OS, gdb and python version.
>
> And my operation steps.
>
> What do you want more, then, I can type here.
>
> Wesley
>

Context, you just keep sending messages like the above which on its own 
is meaningless.  Why should anybody answer your question when you can't 
be bothered to supply all the needed data in one hit?

-- 
My fellow Pythonistas, ask not what our language can do for you, ask 
what you can do for our language.

Mark Lawrence

---
This email is free from viruses and malware because avast! Antivirus protection is active.
http://www.avast.com

[toc] | [prev] | [next] | [standalone]


#68114

FromWesley <nispray@gmail.com>
Date2014-03-09 19:54 -0700
Message-ID<ba897815-b155-4537-a51a-ea16b4b725c9@googlegroups.com>
In reply to#68112
If you don't read the loop from the top, and don't tell me exactly what you want by just keep saying context, please ingore this post.

Thanks.
Wesley

在 2014年3月10日星期一UTC+8上午9时48分41秒,Mark Lawrence写道:
> On 10/03/2014 01:06, Wesley wrote:
> 
> > What's information do you want?
> 
> >
> 
> > I told the OS, gdb and python version.
> 
> >
> 
> > And my operation steps.
> 
> >
> 
> > What do you want more, then, I can type here.
> 
> >
> 
> > Wesley
> 
> >
> 
> 
> 
> Context, you just keep sending messages like the above which on its own 
> 
> is meaningless.  Why should anybody answer your question when you can't 
> 
> be bothered to supply all the needed data in one hit?
> 
> 
> 
> -- 
> 
> My fellow Pythonistas, ask not what our language can do for you, ask 
> 
> what you can do for our language.
> 
> 
> 
> Mark Lawrence
> 
> 
> 
> ---
> 
> This email is free from viruses and malware because avast! Antivirus protection is active.
> 
> http://www.avast.com

[toc] | [prev] | [next] | [standalone]


#68115

FromMark Lawrence <breamoreboy@yahoo.co.uk>
Date2014-03-10 03:11 +0000
Message-ID<mailman.7977.1394421111.18130.python-list@python.org>
In reply to#68114
On 10/03/2014 02:54, Wesley wrote:
> If you don't read the loop from the top, and don't tell me exactly what you want by just keep saying context, please ingore this post.
>
> Thanks.
> Wesley
>
> 在 2014年3月10日星期一UTC+8上午9时48分41秒,Mark Lawrence写道:
>> On 10/03/2014 01:06, Wesley wrote:
>>
>>> What's information do you want?
>>
>>>
>>
>>> I told the OS, gdb and python version.
>>
>>>
>>
>>> And my operation steps.
>>
>>>
>>
>>> What do you want more, then, I can type here.
>>
>>>
>>
>>> Wesley
>>
>>>
>>
>>
>>
>> Context, you just keep sending messages like the above which on its own
>>
>> is meaningless.  Why should anybody answer your question when you can't
>>
>> be bothered to supply all the needed data in one hit?
>>
>>
>>
>> --
>>
>> My fellow Pythonistas, ask not what our language can do for you, ask
>>
>> what you can do for our language.
>>
>>
>>
>> Mark Lawrence
>>
>>
>>
>> ---
>>
>> This email is free from viruses and malware because avast! Antivirus protection is active.
>>
>> http://www.avast.com
>

Ah, that explains things, you're using the notoriously bug ridden google 
groups.  You could read and action this 
https://wiki.python.org/moin/GoogleGroupsPython but I'd suggest you 
equip yourself with a decent email client.  Thunderbird comes highly 
recommended.

-- 
My fellow Pythonistas, ask not what our language can do for you, ask 
what you can do for our language.

Mark Lawrence

---
This email is free from viruses and malware because avast! Antivirus protection is active.
http://www.avast.com

[toc] | [prev] | [next] | [standalone]


#68124

Fromdieter <dieter@handshake.de>
Date2014-03-10 08:28 +0100
Message-ID<mailman.7981.1394436528.18130.python-list@python.org>
In reply to#68114
Wesley <nispray@gmail.com> writes:

> If you don't read the loop from the top, and don't tell me exactly what you want by just keep saying context, please ingore this post.

You are doing things only a few people do: trying to debug
a Python process on C level -- and you observe really strange things.
It is very difficult to guess from the distance what goes wrong.

Apparently, your gdb sees a very strange state of the debugged
process. But why?

Missing symbols was the first guess (the
gdb output you have provided does not suggest this - but
I have not seen the "reading symbols from "python" ..."; thus,
there may still be a problem with this).

A runaway process is another guess.

Some gdb problem another one.


I would approach the situation by simplifying the setup.
Instead of attaching a running Python process, I would
use "gdb python"; then "run"; then "CTRL-C" and there look
what "bt" gives you (this should demonstrate whether your
"gdb" is set up correctly and can debug Python on C level).
Then you write an infinitely running function in Python,
run it and again interrupt with "gdb" to see whether the "py-*"
commands are working. If this all work, you come again
to your actual task -- understanding what your python process
is doing.

[toc] | [prev] | [next] | [standalone]


#68188

FromWesley <nispray@gmail.com>
Date2014-03-10 18:43 -0700
Message-ID<09ebd498-fb4a-4036-8703-9f7c7a580ffa@googlegroups.com>
In reply to#68124
[root@localhost ~]# gdb python
GNU gdb (GDB) Red Hat Enterprise Linux (7.2-60.el6_4.1)
Copyright (C) 2010 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 "x86_64-redhat-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/bin/python...Reading symbols from /usr/lib/debug/usr/bin/python2.6.debug...done.
done.
(gdb) run
Starting program: /usr/bin/python 
warning: the debug information found in "/usr/lib/debug//usr/lib64/libpython2.6.so.1.0.debug" does not match "/usr/lib64/libpython2.6.so.1.0" (CRC mismatch).

warning: the debug information found in "/usr/lib/debug/usr/lib64/libpython2.6.so.1.0.debug" does not match "/usr/lib64/libpython2.6.so.1.0" (CRC mismatch).

[Thread debugging using libthread_db enabled]
Python 2.6.6 (r266:84292, Nov 22 2013, 12:16:22) 
[GCC 4.4.7 20120313 (Red Hat 4.4.7-4)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> 
Program received signal SIGTSTP, Stopped (user).
0x00000034214e15c3 in __select_nocancel () at ../sysdeps/unix/syscall-template.S:82
82      T_PSEUDO (SYSCALL_SYMBOL, SYSCALL_NAME, SYSCALL_NARGS)
Missing separate debuginfos, use: debuginfo-install python-2.6.6-51.el6.x86_64

Seems no debuginfo installed, but actually I have installed before, here is check:

root@localhost ~]# debuginfo-install python-2.6.6-51.el6.x86_64
Loaded plugins: auto-update-debuginfo, fastestmirror, refresh-packagekit
enabling epel-debuginfo
Loading mirror speeds from cached hostfile
epel/metalink                                                                                                                                  | 4.7 kB     00:00     
epel-debuginfo/metalink                                                                                                                        | 4.9 kB     00:00     
 * base: mirrors.yun-idc.com
 * epel: mirrors.hustunique.com
 * epel-debuginfo: mirrors.hustunique.com
 * extras: mirrors.yun-idc.com
 * rpmforge: mirror.hmc.edu
 * updates: mirrors.stuhome.net
adobe-linux-x86_64                                                                                                                             |  951 B     00:00     
base                                                                                                                                           | 3.7 kB     00:00     
debug                                                                                                                                          | 2.5 kB     00:00     
debug/primary_db                                                                                                                               | 966 kB     00:06     
epel                                                                                                                                           | 4.2 kB     00:00     
epel/primary_db                                                                                                                                | 6.0 MB     01:19     
epel-debuginfo                                                                                                                                 | 3.0 kB     00:00     
epel-debuginfo/primary_db                                                                                                                      | 587 kB     00:07     
extras                                                                                                                                         | 3.4 kB     00:00     
google64                                                                                                                                       |  951 B     00:00     
rpmforge                                                                                                                                       | 1.9 kB     00:00     
updates                                                                                                                                        | 3.4 kB     00:00     
Checking for new repos for mirrors
Package matching python-debuginfo-2.6.6-51.el6.x86_64 already installed. Checking for update.
Package glibc-debuginfo-2.12-1.132.el6.x86_64 already installed and latest version
Package glibc-debuginfo-2.12-1.132.el6.x86_64 already installed and latest version
Package glibc-debuginfo-2.12-1.132.el6.x86_64 already installed and latest version
Package glibc-debuginfo-2.12-1.132.el6.x86_64 already installed and latest version
Package glibc-debuginfo-2.12-1.132.el6.x86_64 already installed and latest version
Package matching python-debuginfo-2.6.6-51.el6.x86_64 already installed. Checking for update.
Package glibc-debuginfo-2.12-1.132.el6.x86_64 already installed and latest version
No debuginfo packages available to install

在 2014年3月10日星期一UTC+8下午3时28分30秒,dieter写道:
> Wesley <nispray@gmail.com> writes:
> 
> 
> 
> > If you don't read the loop from the top, and don't tell me exactly what you want by just keep saying context, please ingore this post.
> 
> 
> 
> You are doing things only a few people do: trying to debug
> 
> a Python process on C level -- and you observe really strange things.
> 
> It is very difficult to guess from the distance what goes wrong.
> 
> 
> 
> Apparently, your gdb sees a very strange state of the debugged
> 
> process. But why?
> 
> 
> 
> Missing symbols was the first guess (the
> 
> gdb output you have provided does not suggest this - but
> 
> I have not seen the "reading symbols from "python" ..."; thus,
> 
> there may still be a problem with this).
> 
> 
> 
> A runaway process is another guess.
> 
> 
> 
> Some gdb problem another one.
> 
> 
> 
> 
> 
> I would approach the situation by simplifying the setup.
> 
> Instead of attaching a running Python process, I would
> 
> use "gdb python"; then "run"; then "CTRL-C" and there look
> 
> what "bt" gives you (this should demonstrate whether your
> 
> "gdb" is set up correctly and can debug Python on C level).
> 
> Then you write an infinitely running function in Python,
> 
> run it and again interrupt with "gdb" to see whether the "py-*"
> 
> commands are working. If this all work, you come again
> 
> to your actual task -- understanding what your python process
> 
> is doing.

[toc] | [prev] | [next] | [standalone]


Page 1 of 2  [1] 2  Next page →

Back to top | Article view | comp.lang.python


csiph-web