What are two basic questions about memcached? Ask! 1. I set the data retention period in memcached to 1 hour. then I restarted a memcached service and found that all the data was lost. what is the root cause? 2. I heard that redis is awesome? Which of the following is used by enterprises? Which one is better? What is the current situation? What are two basic questions about memcached? Ask!
1. I set the data retention period in memcached to 1 hour. then I restarted a memcached service and found that all the data was lost. what is the root cause?
2. I heard that redis is awesome? Which of the following is used by enterprises? Which one is better? What is the current situation?
Share:
------ Solution --------------------
Memcached does not back up data to the hard disk, and the data will naturally disappear after it is restarted.
Redis backs up data to the hard disk.
Both of them need to occupy the limited memory of the server, so you need to allocate the memory properly
Unless you give up the "relational database", the two types of databases will be manipulated at the same time, but the system overhead will be increased in vain.
In fact, mysql also supports memory-based tables, and the performance is not inferior to those of them.
------ Solution --------------------
Memcached is more about data sharing among multiple servers.
The memory table mentioned by Xu is really awesome...