我不擅长英语,对此我很抱歉。现在,有一个关于我何时用GDB调试samba的问题。
# gdb /usr/local/samba/sbin/smbd
GNU gdb Red Hat Linux (5.2.1-4)
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it
我正在尝试使用gdb调试Linux,我用"compile kernel with debug info“编译了内核。一旦内核编译完成,我正在尝试提供GDB文件vmlinux (运行上面的命令会出现下面的错误)
GNU gdb (Ubuntu 7.7.1-0ubuntu5~14.04.2) 7.7.1
Reading symbols from file...(no debugging symbols found)...done.
"/home/Linux/vmlinux" is not a core dump: File format not recognized
我是gdb的新手。当我调试我的程序时,我只得到像下面这样的回溯。
Program received signal SIGSEGV, Segmentation fault.
0x000000003075a238 in ?? ()
(gdb) backtrace
#0 0x000000003075a238 in ?? ()
#1 0x00007fff72825da8 in ?? ()
#2 0x0000000000000008 in ?? ()
#3 0x000000003063c340 in ?? ()
#4 0x0000000000000000 in ?? ()
(gdb)
我猜有
我正在调试我的linux内核模块。它会导致死锁,我正在尝试弄清楚是怎么回事。我使用的是vmware + gdb。其思想是将函数挂钩并将回溯记录到文件中。我正在尝试以下操作:
(gdb) br _raw_spin_lock
Breakpoint 5 at 0xffffffff815eb700: file kernel/spinlock.c, line 136.
(gdb) commands 5
Type commands for breakpoint(s) 5, one per line.
End with a line saying just "end".
>silent
我试图用gdb调试一个名为xdf的程序,但当我运行gdb xdf时,我得到了以下错误:
"/home/nealtitusthomas/X-ray_astronomy/heasoft-6.24/x86_64-pc-linux-gnu-libc2.27/bin/xdf": not in executable format: File format not recognized
该程序以符号方式链接,file /home/nealtitusthomas/X-ray_astronomy/heasoft-6.24/x86_64-pc-linux-gnu-libc2.27/bin/xdf的
我一直试图让内核在QEMU中执行,使用GDB对其进行远程调试,但我无法通过或设置断点。以下是GDB会话:
linux (master *) $ gdb vmlinux
GNU gdb (Debian 7.12-6) 7.12.0.20161007-git
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
[LICENSE TEXT]
The target architecture
我正在尝试使用GDB进行调试(以找到一个恼人的分段错误)。当我跑步时:
gdb ./filename
在命令行中,我得到以下错误:
This GDB was configured as "i686-pc-linux-
gnu"..."/path/exec": not in executable
format: File format not recognized
当我执行:
file /path/executable/
我得到以下信息:
ELF 64-bit LSB executable, AMD x86-64,
version 1 (SYSV), for