On Sun, Nov 09, 2014 at 11:42:20AM -0800, David Chia wrote:
> With the RDB setting, it creates hiccups every (defined in the conf) X
> minutes for taking a snapshot and it uses about (in my case) 1/3 of the
> memory for COW. AOF is better, but AOF rewrite is no different from dumping
> the database. 1/3 of memory reserved for any future dumps is definitely not
> good, not to mention about that performance hit.
Define "hiccup"... if the background operations of Redis are causing you
performance problems, you probably need to reassess the hardware platform
you're running Redis on. On an appropriate system configuration, the
background operations should have no noticeable impact.
Based purely on reading that segment of the example config file, that method
is guaranteed to lose data -- there's no way for Redis to reconstruct the
exact dataset that was in memory after a restart if you've overwritten some
older portions of the AOF.
> Before I try out that aof-rotate, have anyone else dealt something similar
> before? Any insight? Is aof-rotate something Redis gonna support in the
> future?
I doubt that aof-rotate will be supported by Redis mainstream. In your
situation, given that Redis appears to be used as a cache, and you're OK
with losing some data (I assume, given that you considered using RDB for
persistence), I'd recommend considering running Redis purely as a cache.
That will eliminate all "hiccups" due to background persistence operations;
you'll just have to reload all missing data on restart.
- Matt
--
New Yankee Workshop isn't a "how to" for home hobbyists, it's "Baywatch" for
powertool fetishists.
-- Geoff Kinnel, ASR