Membase and Redis when they have to store on the disk

341 Views Asked by At

I see a lot of benchmark in which people compare Membase with Redis, only when the database can be stored all in memory. Obviously Redis is much better, but, if both start to store the data on the disk, which is better?

1

There are 1 best solutions below

0
On BEST ANSWER

I am not as familiar with Membase as with Redis, but I know the performance of storing to disk is extremely hardware and (even more so) configuration dependent. With Redis, for example, you have a number of persistence choices with wildly different performance characteristics. Choosing which is most appropriate depends a lot on your use cases, durability requirements, and the resources at your disposal.

For maximum performance (with extremely high durability too) you can suffer hardly any penalty for saving to disk with Redis by setting up a master/production Redis server that NEVER saves to disk, and one or more slave servers which replicate the master data and aggressively saves to disk. This means your master only has to service a few extra READ operations to send down the synchronization data to your slave(s), and your slave(s) are the only ones suffering any disk I/O penalties. You can restore the data on restart/crash to your master by temporarily making it a slave of one of your slaves, then restoring it to master when synchronization is complete.