[Bug 586898] [NEW] php5 cli segmentation fault when executing script

Adrian Almenar aalmenar at gmail.com
Fri May 28 17:52:43 BST 2010


Public bug reported:

Binary package hint: php5-cli

Description:	Ubuntu 10.04 LTS
Release:	10.04

php5-cli:
  Installed: 5.3.2-1ubuntu4.2
  Candidate: 5.3.2-1ubuntu4.2
  Version table:
 *** 5.3.2-1ubuntu4.2 0
        500 http://es.archive.ubuntu.com/ubuntu/ lucid-updates/main Packages
        100 /var/lib/dpkg/status
     5.3.2-1ubuntu4 0
        500 http://es.archive.ubuntu.com/ubuntu/ lucid/main Packages


When I execute a php script on the command line i get segmentation fault.

On the log, i see this happens at the moment a SQL Query to the mysql is
raised.

The gdb backtrace is this:
Program received signal SIGSEGV, Segmentation fault.
0x08329955 in gc_zval_possible_root (zv=0xa56a6e4) at /build/buildd/php5-5.3.2/Zend/zend_gc.c:143
143 /build/buildd/php5-5.3.2/Zend/zend_gc.c: No such file or directory.
        in /build/buildd/php5-5.3.2/Zend/zend_gc.c
(gdb) bt
#0 0x08329955 in gc_zval_possible_root (zv=0xa56a6e4) at /build/buildd/php5-5.3.2/Zend/zend_gc.c:143
#1 0x082fd4c1 in _zval_ptr_dtor (zval_ptr=0xa53fd54) at /build/buildd/php5-5.3.2/Zend/zend_gc.h:183
#2 0x08316f94 in zend_hash_destroy (ht=0xa58a674) at /build/buildd/php5-5.3.2/Zend/zend_hash.c:726
#3 0x0832d2b3 in zend_object_std_dtor (object=0xa55c4b8) at /build/buildd/php5-5.3.2/Zend/zend_objects.c:45
#4 0x0832d2f2 in zend_objects_free_object_storage (object=0xa55c4b8) at /build/buildd/php5-5.3.2/Zend/zend_objects.c:114
#5 0x08330e1d in zend_objects_store_del_ref_by_handle_ex (handle=<error type>, handlers=0x8764700) at /build/buildd/php5-5.3.2/Zend/zend_objects_API.c:220
#6 0x08330e5f in zend_objects_store_del_ref (zobject=0xa5a50bc) at /build/buildd/php5-5.3.2/Zend/zend_objects_API.c:172
#7 0x08309cd9 in _zval_dtor_func (zvalue=0xa5a50bc) at /build/buildd/php5-5.3.2/Zend/zend_variables.c:55
#8 0x082fd48d in _zval_ptr_dtor (zval_ptr=0xa58ecd4) at /build/buildd/php5-5.3.2/Zend/zend_variables.h:35
#9 0x08316f94 in zend_hash_destroy (ht=0x8903d1c) at /build/buildd/php5-5.3.2/Zend/zend_hash.c:726
#10 0x08309c96 in _zval_dtor_func (zvalue=0xa5afb00) at /build/buildd/php5-5.3.2/Zend/zend_variables.c:46
#11 0x082fd48d in _zval_ptr_dtor (zval_ptr=0xa581904) at /build/buildd/php5-5.3.2/Zend/zend_variables.h:35
#12 0x08316f94 in zend_hash_destroy (ht=0xa57a8d4) at /build/buildd/php5-5.3.2/Zend/zend_hash.c:726
#13 0x0832d2b3 in zend_object_std_dtor (object=0xa5afb2c) at /build/buildd/php5-5.3.2/Zend/zend_objects.c:45
#14 0x0832d2f2 in zend_objects_free_object_storage (object=0xa5afb2c) at /build/buildd/php5-5.3.2/Zend/zend_objects.c:114
#15 0x08330e1d in zend_objects_store_del_ref_by_handle_ex (handle=<error type>, handlers=0x8764700) at /build/buildd/php5-5.3.2/Zend/zend_objects_API.c:220
#16 0x08330e5f in zend_objects_store_del_ref (zobject=0xa5be2a8) at /build/buildd/php5-5.3.2/Zend/zend_objects_API.c:172
#17 0x08309cd9 in _zval_dtor_func (zvalue=0xa5be2a8) at /build/buildd/php5-5.3.2/Zend/zend_variables.c:55
#18 0x082fd48d in _zval_ptr_dtor (zval_ptr=0xbfffc984) at /build/buildd/php5-5.3.2/Zend/zend_variables.h:35
#19 0x083301fb in zend_std_write_property (object=0xa5c56d8, member=0xa0299e0, value=0xa5d17d8) at /build/buildd/php5-5.3.2/Zend/zend_object_handlers.c:435
#20 0x0837a9d9 in zend_assign_to_object (result=0xa0299b4, object_ptr=0x877b788, property_name=0xa0299e0, value_op=0xa029a14, Ts=0x893febc, opcode=136)
    at /build/buildd/php5-5.3.2/Zend/zend_execute.c:589
#21 0x0837b268 in ZEND_ASSIGN_OBJ_SPEC_UNUSED_CONST_HANDLER (execute_data=0x893fe60) at /build/buildd/php5-5.3.2/Zend/zend_vm_execute.h:17617
#22 0x08333d8e in execute (op_array=0x8a3fa50) at /build/buildd/php5-5.3.2/Zend/zend_vm_execute.h:104
#23 0x082ffbf1 in zend_call_function (fci=0xbfffcbe0, fci_cache=0xbfffcc04) at /build/buildd/php5-5.3.2/Zend/zend_execute_API.c:947
#24 0x0822eaa5 in zif_call_user_func_array (ht=2, return_value=0x8c81364, return_value_ptr=0x0, this_ptr=0x0, return_value_used=1)
    at /build/buildd/php5-5.3.2/ext/standard/basic_functions.c:4782
#25 0x0835d26a in zend_do_fcall_common_helper_SPEC (execute_data=0x893d630) at /build/buildd/php5-5.3.2/Zend/zend_vm_execute.h:313
#26 0x08333d8e in execute (op_array=0x8909eac) at /build/buildd/php5-5.3.2/Zend/zend_vm_execute.h:104
#27 0x08309fa6 in zend_execute_scripts (type=8, retval=0x0, file_count=3) at /build/buildd/php5-5.3.2/Zend/zend.c:1266
#28 0x082ae754 in php_execute_script (primary_file=0xbffff1d4) at /build/buildd/php5-5.3.2/main/main.c:2288
#29 0x083a0c28 in main (argc=5, argv=0xbffff314) at /build/buildd/php5-5.3.2/sapi/cli/php_cli.c:1196

(gdb) frame 22
#22 0x08333d8e in execute (op_array=0x8a3fa50) at /build/buildd/php5-5.3.2/Zend/zend_vm_execute.h:104
104 /build/buildd/php5-5.3.2/Zend/zend_vm_execute.h: No such file or directory.
        in /build/buildd/php5-5.3.2/Zend/zend_vm_execute.h

This was reported on bug 343870 but people said it's not mysql related.

Using strace i see that it locks after sending the query to mysql
server.

If anything else is needed please let me know im willing to help on
this.

** Affects: php5 (Ubuntu)
     Importance: Undecided
         Status: New

-- 
php5 cli segmentation fault when executing script
https://bugs.launchpad.net/bugs/586898
You received this bug notification because you are a member of Ubuntu
Server Team, which is subscribed to php5 in ubuntu.



More information about the Ubuntu-server-bugs mailing list