2011-05-19 43 views
3

我在PHP 5.3.6(源碼編譯,Slackware 13.1 x86,Linode中的VPS)中出現了令人厭惡的段錯誤。它發生在apache和nginx(fpm)中。最後得到了一個核心轉儲:PHP 5.3.6段錯誤(在apache w/mod_php和nginx w/fpm)

0 0x083db383 in _zval_ptr_dtor() 
1 0x083f3c45 in zend_hash_destroy() 
2 0x083e6fba in _zval_dtor_func() 
3 0x083da69a in _zval_dtor() 
4 0x083db3df in _zval_ptr_dtor() 
5 0x083f3c45 in zend_hash_destroy() 
6 0x083e6fba in _zval_dtor_func() 
7 0x083da69a in _zval_dtor() 
8 0x083db3df in _zval_ptr_dtor() 
9 0x083f3c45 in zend_hash_destroy() 
10 0x08406091 in zend_object_std_dtor() 
11 0x0840632e in zend_objects_free_object_storage() 
12 0x0840a44c in zend_objects_store_del_ref_by_handle_ex() 
13 0x0840a23b in zend_objects_store_del_ref() 
14 0x083e6fe1 in _zval_dtor_func() 
15 0x083da69a in _zval_dtor() 
16 0x083db3df in _zval_ptr_dtor() 
17 0x083f3c45 in zend_hash_destroy() 
18 0x08406091 in zend_object_std_dtor() 
19 0x0840632e in zend_objects_free_object_storage() 
20 0x0840a44c in zend_objects_store_del_ref_by_handle_ex() 
21 0x0840a23b in zend_objects_store_del_ref() 
22 0x083e6fe1 in _zval_dtor_func() 
23 0x083da69a in _zval_dtor() 
24 0x083db3df in _zval_ptr_dtor() 
25 0x083f3c45 in zend_hash_destroy() 
26 0x083e6fba in _zval_dtor_func() 
27 0x083da69a in _zval_dtor() 
28 0x083daed6 in shutdown_executor() 
29 0x083e86c8 in zend_deactivate() 
30 0x0838ebad in php_request_shutdown() 
31 0x084a3f26 in main() 

我使用的memcache,APC和蒙戈擴展(從源代碼編譯)。我嘗試禁用APC,但沒有運氣。我的PHP配置:

./configure \ 
    --prefix=/usr/local/php \ 
    --enable-fpm \ 
    --enable-inline-optimization \ 
    --disable-magic-quotes \ 
    --enable-mbstring \ 
    --enable-mbregex \ 
    --enable-safe-mode \ 
    --enable-wddx=shared \ 
    --enable-xml \ 
    --with-gd \ 
    --enable-gd-native-ttf \ 
    --with-png-dir=/usr \ 
    --with-jpeg-dir=/usr \ 
    --with-freetype-dir=/usr \ 
    --with-gettext \ 
    --with-curl \ 
    --with-mysql=/usr \ 
    --with-mysqli=/usr/bin/mysql_config \ 
    --with-regex=system \ 
    --with-zlib-dir=/usr/lib \ 
    --with-openssl \ 
    --with-snmp \ 
    --enable-ucd-snmp-hack 

這隻發生在應用程序的某個頁面上(代碼太大而無法共享)。看起來它在關機時失敗。我在大約6或7年前就看到了關於PHP跟蹤器的這個錯誤報告,但是從那以後還沒有人聽說過任何人看到它。

奇怪的是,前幾天一切正常,直到我部署了一些應用程序的變化。這並不是單一的,我希望我能指出確切的提交方式,但是它的工作時間和下一次我意識到它不起作用之間大約有5次提交。

任何人都可以爲此做出正面或反面,或者我應該提交一份錯誤報告並希望最好?

回答

2

找出(有點)。從http://snaps.php.net/得到最新的開發版本(5.3-201105190430),並編譯&安裝它。這解決了這個問題(顯然他們知道這個問題並將它列入排隊列表)。

謝謝!

2

我有一個客戶經歷了幾乎相同的coredump。他們使用PHP 5.2.17,所以這是一個長期存在的錯誤。謝謝你指出那個工作的快照。我剛剛從PHP的svn中提取了該日期和時間,並與股票5.3.6進行了比較。我懷疑它是其中的一個固定它:

。修正了錯誤#54585(track_errors導致段錯誤)。

。修復了錯誤#54372(從__get()句柄返回的全局對象本身的崩潰)。

。修復了錯誤#54262(將值分配給非數組中的維時崩潰)。

。修復了dtor內部錯誤處理的崩潰。

。修正了當通過php_admin_value設置browscap ini指令時錯誤#54580(get_browser()分段錯誤)。

你說這個問題出現在大約5次提交之間。是否有機會向我提供包含這5個提交的應用程序的差異,以便我們能夠弄清楚上面的哪些修補程序是相關的?這可能有助於確定解決方案。

請隨時發郵件releaze3 AT gmail DOT com。不是我真正的電子郵件,但我會迴應我的真實電子郵件(避免垃圾郵件 - 如果垃圾郵件進入該地址,我不在乎)。希望我們可以共同研究出導致這種情況的原因,併爲人們提供一種無法升級其PHP的解決方法。

0

您可能會被https://bugs.php.net/bug.php?id=63055「與SF2測試套件在zend_gc中的Segfault相關」,這顯然是由於「任何使用帶遞歸數組的zval_dtor都可能觸發此段錯誤」。