aMule Forum

English => aMule Help => Topic started by: macias on August 09, 2006, 09:46:08 AM

Title: How to make a backtrace without a headache?
Post by: macias on August 09, 2006, 09:46:08 AM
Hello,

  I compiled amule in debug mode however I have problems running it in such a mode. Maybe I didn't understand wiki page about backtrace correctly:
a) via gdb -- annoying, since I can't (don't know how to) run amule automatically, each time I have to type "run" in gdb; also when the program crashes I am still in gdb and I can't (don't know how to) set the audible indicator about crash

b) unlimited core dump -- I have 2GB RAM and I am afraid that on crash, the core file could be 2GB in size -- it is problem for me because I don't have 2GB free space on my disk

  So how could I easily run amule in debug mode, fully automatically, and not worrying about space left on disk?

Thanks for any help, bye
Title: Re: How to make a backtrace without a headache?
Post by: Gerd78 on August 09, 2006, 10:57:42 AM
(a) That's the way gdb works, you have to live with it

(b) You don't need to create core files at all

Just use this script to start aMule:
Code: [Select]
#!/bin/sh
gdb amule << EOF
run
bt
bt full
thread apply all bt
EOF
Title: Re: How to make a backtrace without a headache?
Post by: macias on August 13, 2006, 10:13:27 AM
Thanks a lot, could you just take a look at:

http://forum.amule.org/thread.php?threadid=10789&sid=

and see if I did everything ok?

have a nice day, bye
Title: Re: How to make a backtrace without a headache?
Post by: macias on September 04, 2006, 11:51:06 AM
Quote
Originally posted by Gerd78
(a) That's the way gdb works, you have to live with it
[/code]

I found out (trivial after all) that I could add "quit" and after the whole script I could run mplayer for example. So I can get both -- run gdb and have audible indicator of the crash.

Thanks again, bye