Welcome! Log In Create A New Profile

Advanced

Re: Nginx and Memcache

Maxim Dounin
October 22, 2010 11:58AM
Hello!

On Fri, Oct 22, 2010 at 09:39:03AM -0400, midas wrote:

> Hi,
>
> I have recently installed Nginx as a front facing server to communicate
> with memcache. My problem is that the PHP code that writes into memcache
> serializes the contents. I cannot turn off serialization but need to
> figure out how to get the string content from memcache. The current
> output from Nginx is of type application/octet-stream. Is there
> something I missed?

As memcached values doesn't store/return any content type - nginx only
able to detect it based on request uri extension (i.e. the same
logic as for static files applies).

See details here:

http://wiki.nginx.org/HttpCoreModule#default_type
http://wiki.nginx.org/HttpCoreModule#types

E.g to make sure all replies from memcached are returned as
text/plain do something like this:

location /memcached/ {
types {}
default_type text/plain;
memcached_pass ...
}

Maxim Dounin

_______________________________________________
nginx mailing list
nginx@nginx.org
http://nginx.org/mailman/listinfo/nginx
Subject Author Posted

Nginx and Memcache

midas October 22, 2010 09:39AM

Re: Nginx and Memcache

Maxim Dounin October 22, 2010 11:58AM

Re: Nginx and Memcache

midas October 22, 2010 03:24PM

Re: Nginx and Memcache

Maxim Dounin October 22, 2010 04:20PM

Re: Nginx and Memcache

midas October 22, 2010 05:05PM

Re: Nginx and Memcache

midas October 26, 2010 11:38AM

Re: Nginx and Memcache

Maxim Dounin October 26, 2010 01:18PM

Re: Nginx and Memcache

midas October 26, 2010 01:34PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 335
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 500 on July 15, 2024
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready