2015-04-02 56 views
0

我遇到麻煩了解是什麼導致了Apache/PHP中的Segfault。Apache/PHP Segfault無法使用gdb backtrace進行診斷

如何找出:

#1)什麼腳本導致錯誤?

#2)錯誤發生在什麼功能?

當我運行回溯時,它看起來像是init出現錯誤。當我進入框架時,我沒有看到任何其他信息。

(gdb) bt 
#0 0x00002aaab0bc906b in object_properties_init() from /etc/httpd/modules/libphp5.so 
#1 0x00002aaab0bc9a8e in _object_and_properties_init() from /etc/httpd/modules/libphp5.so 
#2 0x00002aaab0c3c4e9 in ??() from /etc/httpd/modules/libphp5.so 
#3 0x00002aaab0bf6bae in execute() from /etc/httpd/modules/libphp5.so 
#4 0x00002aaab0bf1160 in ??() from /etc/httpd/modules/libphp5.so 
#5 0x00002aaab0bf6bae in execute() from /etc/httpd/modules/libphp5.so 
#6 0x00002aaab0bb4edf in zend_call_function() from /etc/httpd/modules/libphp5.so 
#7 0x00002aaab0bb5d00 in call_user_function_ex() from /etc/httpd/modules/libphp5.so 
#8 0x00002aaab0bb5d86 in call_user_function() from /etc/httpd/modules/libphp5.so 
#9 0x00002aaab0ac1a5d in ??() from /etc/httpd/modules/libphp5.so 
#10 0x00002aaab0ac1cb5 in ??() from /etc/httpd/modules/libphp5.so 
#11 0x00002aaab0aba753 in ??() from /etc/httpd/modules/libphp5.so 
#12 0x00002aaab0abae8f in ??() from /etc/httpd/modules/libphp5.so 
#13 0x00002aaab0bc6df0 in ??() from /etc/httpd/modules/libphp5.so 
#14 0x00002aaab0b63c35 in php_request_shutdown() from /etc/httpd/modules/libphp5.so 
#15 0x00002aaab0c68cb1 in ??() from /etc/httpd/modules/libphp5.so 
#16 0x00002b21a22bdf4a in ap_run_handler() 
#17 0x00002b21a22c13d8 in ap_invoke_handler() 
#18 0x00002b21a22cbd3a in ap_internal_redirect() 
#19 0x00002aaaaf707c70 in ap_make_dirstr_parent() from /etc/httpd/modules/mod_rewrite.so 
#20 0x00002b21a22bdf4a in ap_run_handler() 
#21 0x00002b21a22c13d8 in ap_invoke_handler() 
#22 0x00002b21a22cbee8 in ap_process_request() 
#23 0x00002b21a22c90d0 in ??() 
#24 0x00002b21a22c51d2 in ap_run_process_connection() 
#25 0x00002b21a22d0389 in ??() 
#26 0x00002b21a22d061a in ??() 
#27 0x00002b21a22d0e7d in ap_mpm_run() 
#28 0x00002b21a22ab058 in main() 


(gdb) frame 0 
#0 0x00002aaab0bc906b in object_properties_init() from /etc/httpd/modules/libphp5.so 

(gdb) frame 3 
#3 0x00002aaab0bf6bae in execute() from /etc/httpd/modules/libphp5.so 

(gdb) frame 15 
#15 0x00002aaab0c68cb1 in ??() from /etc/httpd/modules/libphp5.so 
+0

這很可能是一個附加模塊。你知道你正在使用什麼模塊(例如Oracle模塊,GD模塊) – kainaw 2015-04-02 16:43:29

+0

@ kainaw什麼類型的模塊? PHP還是Apache? – eric 2015-04-03 00:05:23

+0

Php模塊。例子...我安裝了一次錯誤版本的Oracle模塊,並且出現了分段錯誤。 – kainaw 2015-04-03 01:06:22

回答

1

1)什麼腳本導致錯誤?

堆棧跟蹤中沒有足夠的信息告訴您。

您需要安裝libphp5.so的調試符號,並且可能還需要安裝Apache。 然後你可以找出腳本。

如何安裝調試符號的精確細節取決於您使用的操作系統和發行版,而且您也沒有告訴我們。通常它就像apt-get install php5-dbg,yum install php5-debug或類似的東西。

2)什麼函數的錯誤發生在?

錯誤發生在object_properties_init()