使用gdb debug nebula

nebula 版本: 1.1.0
部署方式:分布式
想用gdb debug nebula的程序,编译的时候需要加什么参数?
加了 -DCMAKE_BUILD_TYPE=Debug 之后还是不行

执行的命令:

$ gdb --version
GNU gdb (GDB) Red Hat Enterprise Linux 7.6.1-119.el7
$ source ~/software/gcc_dir/gcc/7.5.0/enable
$ gdb nebula-storaged

显示:

Dwarf Error: wrong version in compilation unit header (is 0, should be 2, 3, or 4) [in module /home/nebula/software/nebula1.1.0-test/bin/nebula-storaged]
(no debugging symbols found)...done.

你编译好的binary是在你当前的编译环境里面运行吗?
或者你更新下gdb的版本。

在A机器上编译,然后A机器上执行GDB也不行;
GDB需要升级到什么版本?

8.x的

好的,我试一下,谢谢;