【发布时间】:2015-10-14 11:23:15
【问题描述】:
我正在尝试学习使用 gdb 调试 php。附加到 php 进程后,我收到有关调试 php5-mysql、php5-pgsql 符号的错误。哪里有问题?
# gdb -p 33087
GNU gdb (GDB) 7.4.1-debian
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Attaching to process 33087
Reading symbols from /usr/bin/php5...Reading symbols from /usr/lib/debug/usr/bin/php5...done.
done.
...
Reading symbols from /usr/lib/php5/20100525/pdo.so...Reading symbols from /usr/lib/debug/usr/lib/php5/20100525/pdo.so...done.
done.
Loaded symbols for /usr/lib/php5/20100525/pdo.so
Reading symbols from /usr/lib/php5/20100525/curl.so...Reading symbols from /usr/lib/debug/usr/lib/php5/20100525/curl.so...done.
done.
Reading symbols from /usr/lib/php5/20100525/mcrypt.so...Reading symbols from /usr/lib/debug/usr/lib/php5/20100525/mcrypt.so...done.
done.
...
Reading symbols from /usr/lib/php5/20100525/mysql.so...
warning: the debug information found in "/usr/lib/debug//usr/lib/php5/20100525/mysql.so" does not match "/usr/lib/php5/20100525/mysql.so" (CRC mismatch).
warning: the debug information found in "/usr/lib/debug/usr/lib/php5/20100525/mysql.so" does not match "/usr/lib/php5/20100525/mysql.so" (CRC mismatch).
(no debugging symbols found)...done.
Loaded symbols for /usr/lib/php5/20100525/mysql.so
Reading symbols from /usr/lib/x86_64-linux-gnu/libmysqlclient.so.18...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/x86_64-linux-gnu/libmysqlclient.so.18
Reading symbols from /usr/lib/php5/20100525/mysqli.so...
warning: the debug information found in "/usr/lib/debug//usr/lib/php5/20100525/mysqli.so" does not match "/usr/lib/php5/20100525/mysqli.so" (CRC mismatch).
warning: the debug information found in "/usr/lib/debug/usr/lib/php5/20100525/mysqli.so" does not match "/usr/lib/php5/20100525/mysqli.so" (CRC mismatch).
(no debugging symbols found)...done.
Loaded symbols for /usr/lib/php5/20100525/mysqli.so
Reading symbols from /usr/lib/php5/20100525/pdo_mysql.so...
warning: the debug information found in "/usr/lib/debug//usr/lib/php5/20100525/pdo_mysql.so" does not match "/usr/lib/php5/20100525/pdo_mysql.so" (CRC mismatch).
warning: the debug information found in "/usr/lib/debug/usr/lib/php5/20100525/pdo_mysql.so" does not match "/usr/lib/php5/20100525/pdo_mysql.so" (CRC mismatch).
(no debugging symbols found)...done.
Loaded symbols for /usr/lib/php5/20100525/pdo_mysql.so
Reading symbols from /usr/lib/php5/20100525/pdo_pgsql.so...Reading symbols from /usr/lib/debug/usr/lib/php5/20100525/pdo_pgsql.so...done.
done.
Loaded symbols for /usr/lib/php5/20100525/pdo_pgsql.so
Reading symbols from /usr/lib/x86_64-linux-gnu/libpq.so.5...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/x86_64-linux-gnu/libpq.so.5
...
0x00007fe63e36b18d in poll () from /lib/x86_64-linux-gnu/libc.so.6
(gdb)
如何修复“警告:在“/usr/lib/debug/usr/lib/php5/20100525/mysql.so”中找到的调试信息与“/usr/lib/php5/20100525/mysql”不匹配等错误.so”(CRC 不匹配)。”?有趣的是,其他 php 扩展的符号都可以,但只有 mysql、mysqli、postgres 失败。
Debian Wheezy 7.6,所有的php包都是5.4.41-0+deb7u1。
【问题讨论】:
标签: php gdb php-extension