getting rid of the 1M value limit

130 views
Skip to first unread message

bsergean

unread,
Dec 9, 2008, 12:37:25 AM12/9/08
to memcached
Hi,

http://www.socialtext.net/memcached/index.cgi?faq#what_are_some_limits_in_memcached_i_might_hit
"""
Stored data cannot exceed 1 megabyte in size, since that is the
largest typical slab size.
"""

I'd like to cache datas that are bigger than 1M in size.
I tried to look at the slabs.c code but couldn't figure how to do
that. The FAQ talks about USE_SYSTEM_MALLOC but I'm not sure it's
related.

Any help would be great.

Thanks,
- Benjamin

Toru Maesaka

unread,
Dec 9, 2008, 1:09:21 AM12/9/08
to memc...@googlegroups.com
Hi,

If you MUST, go into slabs.c and grep for the constant, 'POWER_BLOCK'.

Cheers,
Toru

Benjamin Sergeant

unread,
Dec 9, 2008, 10:04:04 AM12/9/08
to memc...@googlegroups.com
#define POWER_BLOCK 1048576

I will play with it. Thanks a lot Toru.

- Benjamin

Trond Norbye

unread,
Dec 9, 2008, 10:17:52 AM12/9/08
to memc...@googlegroups.com
Toru Maesaka wrote:
> Hi,
>
> If you MUST, go into slabs.c and grep for the constant, 'POWER_BLOCK'.
>
>
In addition you _must_ also verify that your client can handle such
values ;)

Cheers,

Trond

Benjamin Sergeant

unread,
Dec 9, 2008, 11:54:06 AM12/9/08
to memc...@googlegroups.com
I'm planning to use cmemcache which calls libmemcache. Do you think there's gonna be problems ? (I'm gonna check today anyway).

- Benjamin

Benjamin Sergeant

unread,
Dec 9, 2008, 1:26:21 PM12/9/08
to memc...@googlegroups.com
It works great, thanks guys !

- Benjamin

ps:
Now I will start thinking about doing things right and not caching my big blobs ...
Reply all
Reply to author
Forward
0 new messages