|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #58766 memcached nginx binary data problem
Submitted: 2009-07-17 06:24 UTC Modified: 2012-03-07 17:17 UTC
From: wwDevil at gmail dot com Assigned: andrei (profile)
Status: Closed Package: memcached (PECL)
PHP Version: 5.2.6 OS: ubuntu 9.0.4
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
Solve the problem:
9 - 5 = ?
Subscribe to this entry?

 [2009-07-17 06:24 UTC] wwDevil at gmail dot com
Binary data saved in cache not reading from cache by nginx

Reproduce code:
$memDB = new Memcached();
$fp = fopen('png.png','r');
$data = fread($fp, filesize('png.png'));

nginx conf
location / {
    #all non static request in index.php. wdevil
    add_header    Content-Type  "image/png;";
    set             $memcached_key   "/test";
    memcached_pass  localhost:11211;

nginx response to browser binary data. no png binary.
If i replace Memcached --> Memcache class. All ok.

Expected result:
png img in browser


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2009-07-17 06:26 UTC] wwDevil at gmail dot com
Version 	1.0.0
libmemcached version 	0.31
Session support 	yes
igbinary support 	no
 [2009-07-17 12:44 UTC]
Try turning compression off.

$m->setOption(Memcached::OPT_COMPRESSION, false);
 [2012-03-07 17:17 UTC]
Closing because of age. Please try version 2.0.1 and reopen if this still occurs. 
Might have been due to compression being on.
 [2012-03-07 17:17 UTC]
-Status: Open +Status: Closed -Assigned To: +Assigned To: andrei
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon May 27 23:01:30 2024 UTC