Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: Connect gdb to a running perl process

by rob_au (Abbot)
on Feb 14, 2005 at 09:56 UTC ( #430730=note: print w/ replies, xml ) Need Help??


in reply to Connect gdb to a running perl process

This might be a stupid question, but why are you using gdb to debug your Perl script? Why not invoke the Perl debugger? If you do need to debug using gdb, some of the methodology described at http://modperlbook.org/html/ch21_07.html may be of use.

(By the way, from the where output, I would hazard a guess that your Perl code is executing a sleep statement)

 

perl -le "print unpack'N', pack'B32', '00000000000000000000001000000000'"


Comment on Re: Connect gdb to a running perl process
Select or Download Code
Re^2: Connect gdb to a running perl process
by saintmike (Vicar) on Feb 14, 2005 at 19:32 UTC
    This might be a stupid question, but why are you using gdb to debug your Perl script? Why not invoke the Perl debugger?

    You can't call the perl debugger on a running perl script, can you? Requirement is to not having to restart the process.

    (By the way, from the where output, I would hazard a guess that your Perl code is executing a sleep statement)

    Right, this was a sample script. I was hoping there was a proven sequence of gdb commands to examine perl's internal data structures revealing the current file and line.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://430730]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (7)
As of 2014-12-25 21:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (163 votes), past polls