On Thu, 14 Mar 2019 11:58:39 +0100 Willy Tarreau <w...@1wt.eu> wrote:
> But I know it's possible to do better > using "-ex" or something like this. Here is an example, for "thread apply all backtrace": $ gdb -batch -ex 't a a bt' /bin/sleep 4929 0x00007fa7529904d4 in nanosleep () from /lib64/libc.so.6 Thread 1 (process 4929): #0 0x00007fa7529904d4 in nanosleep () from /lib64/libc.so.6 #1 0x00000000004053d7 in ?? () #2 0x0000000000405220 in ?? () #3 0x00000000004024c0 in ?? () #4 0x00007fa7528d8b5b in __libc_start_main () from /lib64/libc.so.6 #5 0x000000000040257a in ?? () [Inferior 1 (process 4929) detached] Note the use of "-batch", so there won't be GDB prompts such as confirmation for detaching from the process. Cheers, -- Ricardo Nabinger Sanchez http://www.taghos.com.br/