推荐学习书目
› Learn Python the Hard Way
Python Sites
› PyPI - Python Package Index
› http://diveintopython.org/toc/index.html
› Pocoo
值得关注的项目
› PyPy
› Celery
› Jinja2
› Read the Docs
› gevent
› pyenv
› virtualenv
› Stackless Python
› Beautiful Soup
› 结巴中文分词
› Green Unicorn
› Sentry
› Shovel
› Pyflakes
› pytest
Python 编程
› pep8 Checker
Styles
› PEP 8
› Google Python Style Guide
› Code Style from The Hitchhiker's Guide
myKing
V2EX  ›  Python

redis 中主从、哨兵和集群这三个有什么区别 ?

  •  
  •   myKing · Sep 4, 2018 · 8047 views
    This topic created in 2944 days ago, the information mentioned may be changed or developed.
    redis 中主从、哨兵和集群这三个有什么区别 ?分别有什么优势?适用于什么场景?在实际工作如何选择?
    6 replies  •  2018-09-04 19:54:58 +08:00
    anthow
        1
    anthow  
       Sep 4, 2018
    哨兵是用来监控主从的健康状况的;集群里面也有主从模式,一般至少是 3 主 3 从,集群模式每个节点不需要全量存储
    stone1342006
        2
    stone1342006  
       Sep 4, 2018
    主从往往是为了读写分离、backup 等目的, 哨兵可以检测主从健康, 主挂了可以把从提升为主, 集群往往是为了数据 sharding, 解决单台机器资源的上限的问题
    nl101531
        3
    nl101531  
       Sep 4, 2018 via Android
    主从为了数据备份,哨兵为了高可用,主挂了哨兵可以切换,集群则是因为单实例能力有限,搞多个分散压力。
    night98
        4
    night98  
       Sep 4, 2018   ❤️ 2
    主从:读写分离,备份
    哨兵:监控,自动转移,选主
    集群:数据 hash 分片,同时包含主从及哨兵特性
    cominghome
        5
    cominghome  
       Sep 4, 2018
    直接 cluster 完事
    metrxqin
        6
    metrxqin  
       Sep 4, 2018
    主从:故障切换 [failover]
    哨兵:监控主服务状态,投票选择主节点
    集群:均衡负载
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   903 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 46ms · UTC 22:35 · PVG 06:35 · LAX 15:35 · JFK 18:35
    ♥ Do have faith in what you're doing.