Hey,

I've finally gotten around to making a first pass of an improved slab
rebalancer algorithm. I really need a few folks to try it out!

This exists as a python3 script that you start and point at one of your
instances. It shuts off the internal automover and then attempts to manage
memory fairly.

I'm testing a couple other tunings to the algorithm internally, but I want
to see if this simple approach is good enough for what I would like to cut
at 1.5.0.

Get the latest script here:
https://raw.githubusercontent.com/memcached/memcached/next/scripts/memcached-automove

run it with the defaults:
./memcached-automove --host 127.0.0.1:11211

(it will print information but not do anything)

./memcached-automove --host 127.0.0.1:11211 --automove

(will actually move pages around)

./memcached-automove --host 127.0.0.1:11211 --automove --verbose

(will make a lot of noise while it moves pages around)

there are other options:

--sleep N (default 1) (how long to sleep inbetween tests)

--ratio 0.N (default 0.8)

This gates the maximum delta between the slab class with the highest "age"
(oldest live item) and the slab class with the youngest "age". So if slab
class 1 has an age of more than 20% younger than slab class 5, it will
move a page from 5 to 1.

--window N (default 30)

How many tests to consider for various internals. You can probably safely
ignore this. It attempts to not free memory from classes which recently
needed memory, etc.

It would be useful to do three comparisons, but not strictly necessary:

1) start memcached 1.4.36 (or better) with -o modern. No other changes.
Watch hit rate over time.

2) start 1.4.36+ with -o modern, then immediately telnet in and run:
"slabs automove 0"
Watch hit rate over time.

3) start 1.4.36+ with -o modern, then immediately start
memcached-automove against it.
Watch hit rate over time.

1 should do the worst. 2 should be average. 3 should either match or
beat 2.

Please try it out and let me know! I'm really hoping to finish 1.5.0 soon
and swap the defaults to `-o modern`, and the slab rebalancer algorithm is
once of the last 2 or 3 blockers.

Thanks!
-Dormando

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"memcached" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to memcached+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to