New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Segfault with PHP7 and Memcached #60

Closed
szicsu opened this Issue Feb 7, 2016 · 5 comments

Comments

Projects
None yet
4 participants
@szicsu

szicsu commented Feb 7, 2016

Sample file: m.php

$m = new Memcached();
$m->addServer('127.0.0.1', 11211);
$m->set('nullValue', NULL, 3600);

Trace:
Program received signal SIGSEGV, Segmentation fault.
0x00007fffeefd7b91 in igbinary_serialize_ex (ret=0x7fffffffa980, ret_len=0x10, z=<optimized out>, memory_manager=<optimized out>) at /opt/igbinary/igbinary.c:433
433 *ret_len = igsd.buffer_size - 1;

Branch: php7-dev-playground2

System info:

PHP 7.0.3-1~dotdeb+8.1 (cli) ( NTS )
Copyright (c) 1997-2016 The PHP Group
Zend Engine v3.0.0, Copyright (c) 1998-2016 Zend Technologies
with Zend OPcache v7.0.6-dev, Copyright (c) 1999-2016, by Zend Technologies

If I turn off the igbinary support, I not get the segfault:
php -d 'memcached.serializer=php' ./m.php

@EugenMayer

This comment has been minimized.

Show comment
Hide comment
@EugenMayer

EugenMayer Mar 10, 2016

Seconding this. Same issue, had to disable igbinary support in memcached

EugenMayer commented Mar 10, 2016

Seconding this. Same issue, had to disable igbinary support in memcached

@EugenMayer

This comment has been minimized.

Show comment
Hide comment
@EugenMayer

EugenMayer Mar 15, 2016

Since dotdeb started to use memcached.serializer=igbinary all memcached builds are broken - this will become a severe issue.

EugenMayer commented Mar 15, 2016

Since dotdeb started to use memcached.serializer=igbinary all memcached builds are broken - this will become a severe issue.

@sfai05

This comment has been minimized.

Show comment
Hide comment
@sfai05

sfai05 May 31, 2016

Same here. Switched to https://github.com/igbinary/igbinary7 still have the problem.

sfai05 commented May 31, 2016

Same here. Switched to https://github.com/igbinary/igbinary7 still have the problem.

@EugenMayer

This comment has been minimized.

Show comment
Hide comment
@EugenMayer

EugenMayer Jul 3, 2016

i tried to verify this once again.

 php --version
PHP 7.0.8-2+0~20160628130014.3+jessie~1.gbp5338fb (cli) ( NTS )

php -i | grep memcached
]/etc/php/7.0/cli/conf.d/25-memcached.ini,
memcached
memcached support => enabled
libmemcached version => 1.0.18

 php -i | grep igbinary
/etc/php/7.0/cli/conf.d/20-igbinary.ini,
igbinary
igbinary support => enabled
igbinary version => 1.2.2-dev

i created your testscript and could neither get a segfault using

php test.php

nor

php -d 'memcached.serializer=igbinary' test.php

I also tried this with the recent php5.5 build, no segfaults here also

EugenMayer commented Jul 3, 2016

i tried to verify this once again.

 php --version
PHP 7.0.8-2+0~20160628130014.3+jessie~1.gbp5338fb (cli) ( NTS )

php -i | grep memcached
]/etc/php/7.0/cli/conf.d/25-memcached.ini,
memcached
memcached support => enabled
libmemcached version => 1.0.18

 php -i | grep igbinary
/etc/php/7.0/cli/conf.d/20-igbinary.ini,
igbinary
igbinary support => enabled
igbinary version => 1.2.2-dev

i created your testscript and could neither get a segfault using

php test.php

nor

php -d 'memcached.serializer=igbinary' test.php

I also tried this with the recent php5.5 build, no segfaults here also

@TysonAndre

This comment has been minimized.

Show comment
Hide comment
@TysonAndre

TysonAndre Jul 16, 2016

Member

The php7 dev playground branches aren't being updated. see https://github.com/igbinary/igbinary7

Member

TysonAndre commented Jul 16, 2016

The php7 dev playground branches aren't being updated. see https://github.com/igbinary/igbinary7

@TysonAndre TysonAndre closed this Jul 16, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment