I don't know, I'm just guessing. :-) But there's really only two scenarios
that are possible:

1) Ajeet's test is broken, he doesn't really store 5 million unique items,
and fails to detect the cache misses.

2) Stats is broken, Ajeet stores 5 million unique items, but the server
counts them incorrectly.

The two explanations he offered in his original email are both false.
Spymemcached doesn't hash keys before sending them to the server, so his
client doesn't cause key collisions. And a few items are not evicted because
his eviction stat is 0, and his test doesn't show any cache misses.


/Henrik

On Mon, Jul 27, 2009 at 20:48, Jozef Sevcik <sev...@styxys.com> wrote:

>
> Sounds interesting, is that possible ? What are the conditions stats
> *may* be wrong ?
> Thanks
>
> 2009/7/27 Henrik Schröder <skro...@gmail.com>:
> > Another possibility is of course that the stats are wrong.
> >
> >
> > /Henrik
> >
> > On Mon, Jul 27, 2009 at 20:15, Ajeet <asgre...@gmail.com> wrote:
> >>
> >> >
> >> > > 2. The data that I inserted is not there anymore and has been
> evicted
> >> > > ( while inserting the timeout was 30 days, all the testing was done
> in
> >> > > a matter of hours)
> >> >
> >> > Possible.  Are you storing lots of things the same size?  Memcached
> uses
> >> > slabs to allocate memory.  Each slab stores objects of a given size.
> >> > So, if you are storing lots of things the same size, they will get
> >> > evicted from the server.
> >>
> >> Yes all items are more or less the same size.
> >>
> >> >
> >> > You could restart memcached then load it up then run something like:
> >> >
> >> > $ echo stats | nc localhost 11211 | fgrep evictions
> >> > STAT evictions 143202
> >> >
> >> > That would tell you how many evictions occurred.
> >>
> >> I get
> >> STAT evictions 0
> >>
> >> I also have
> >> STAT curr_items 4997968
> >> STAT total_items 4998139
> >>
> >> As I mentioned before, I dont get any cache misses. Btw, I am using
> >> version 1.2.8
> >> The client is spymemcached.
> >>
> >> How can this be if there is no open hashing involved?
> >>
> >> --
> >> Regards,
> >> Ajeet
> >
> >
>
>
>
> --
> Jozef
>

Reply via email to