laravel redis sentinel 和 redis cluster 配置
laravel redis sentinel配置:
'redis' => [
'cluster' => false, 'options' => [
'replication' => 'sentinel',
'service' => 'redis-master',
'parameters' => [
'password' => 'xxxxxxx',
'database' => 0,
],
], 'default' => [
'tcp://192.168.0.11:27000', 'tcp://192.168.0.23:27002', 'tcp://192.168.0.24:27001',
],
],
laravel redis cluster配置:
'redis' => [
'cluster' => true,
'options' => ['cluster' => 'redis'],
'default' => [
[
'host' => '192.168.0.11',
'port' => 6381,
'database' => 0,
'timeout' => 15,
'read_write_timeout' => 1800, //redis客户端连接以后的读写超时时间(默认是60s)
'password' => null,
],
[
'host' => '192.168.0.11',
'port' => 6382,
'database' => 0,
'timeout' => 15,
'read_write_timeout' => 1800,
'password' => null,
],
[
'host' => '192.168.0.11',
'port' => 6383,
'database' => 0,
'timeout' => 15,
'read_write_timeout' => 1800,
'password' => null,
],
[
'host' => '192.168.0.11',
'port' => 6384,
'database' => 0,
'timeout' => 15,
'read_write_timeout' => 1800,
'password' => null,
],
[
'host' => '192.168.0.11',
'port' => 6385,
'database' => 0,
'timeout' => 15,
'read_write_timeout' => 1800,
'password' => null,
],
[
'host' => '192.168.0.11',
'port' => 6386,
'database' => 0,
'timeout' => 15,
'read_write_timeout' => 1800,
'password' => null,
]
],
],
laravel redis sentinel 和 redis cluster 配置的更多相关文章
- (转)基于Redis Sentinel的Redis集群(主从&Sharding)高可用方案
转载自:http://warm-breeze.iteye.com/blog/2020413 本文主要介绍一种通过Jedis&Sentinel实现Redis集群高可用方案,该方案需要使用Jedi ...
- 基于Redis Sentinel的Redis集群(主从Sharding)高可用方案(转)
本文主要介绍一种通过Jedis&Sentinel实现Redis集群高可用方案,该方案需要使用Jedis2.2.2及以上版本(强制),Redis2.8及以上版本(可选,Sentinel最早出现在 ...
- 基于Redis Sentinel的Redis集群(主从&Sharding)高可用方案
本文主要介绍一种通过Jedis&Sentinel实现Redis集群高可用方案,该方案需要使用Jedis2.2.2及以上版本(强制),Redis2.8及以上版本(可选,Sentinel最早出现在 ...
- 【Redis】使用Redis Sentinel实现Redis HA
阅读目录 1 sentinel down-after-milliseconds mymaster 30000 sentinel failover-timeout mymaster 18000 sent ...
- redis sentinel 集群监控 配置
环境: ip 172.16.1.31 26379 redis sentinel ip 172.16.1.30 6379 主 1 ip 172.16.1.31 6380 从 1 ip ...
- Redis Sentinel实现高可用配置
一般情况下yum安装redis的启动目录在:”/usr/sbin” :配置目录在”/etc/redis/”在其目录下会有默认的redis.conf和redis-sentinel.conf redis高 ...
- CentOS7 配置 Redis Sentinel主从集群配置
Redis Sentinel主从集群 环境.准备 slave配置 sentinel配置 测试 C#连接Redis Sentinel 1.环境.准备 单实例3台CentOS7服务器,IP地址.: 192 ...
- 利用Redis Sentinel实现redis主从自动切换
redis主从配置很简单,只需要在slave的配置里加slaveof 192.168.0.100 6379(master的ip和端口) 如果master有密码再设置 masterauth passwo ...
- redis sentinel(哨兵)配置解读
1 port <sentinel-port> :哨兵实例运行所在的端口(默认26379) 2 sentinel announce-ip:哨兵将会在gossip hello消息中使用指定的i ...
随机推荐
- JQuery通过click事件获取当前点击对象的id,name,value属性等
$(".test").click(function () { var val=$(this).attr("id"); })
- Cogs 376. [IOI2002]任务安排(后效性DP)
[IOI2002]任务安排 ★☆ 输入文件:batch.in 输出文件:batch.out 简单对比 时间限制:1 s 内存限制:128 MB N个任务排成一个序列在一台机器上等待完成(顺序不得改变) ...
- 洛谷 P1950 长方形_NOI导刊2009提高(2) 题解
P1950 长方形_NOI导刊2009提高(2) 题目描述 小明今天突发奇想,想从一张用过的纸中剪出一个长方形. 为了简化问题,小明做出如下规定: (1)这张纸的长宽分别为n,m.小明讲这张纸看成是由 ...
- 【微信小程序】如何获取用户绑定手机号
用户调用wx.login()方法,获取登录用户凭证code wx.login({ success: function(res) { console.log('loginCode', res.code) ...
- 请解释或描述一下Django的架构
对于Django框架遵循MVC设计,并且有一个专有名词:MVT M全拼为Model,与MVC中的M功能相同,负责数据处理,内嵌了ORM框架 V全拼为View,与MVC中的C功能相同,接收HttpReq ...
- C 库函数 - strcspn()
定义 size_t strcspn(const char *str1, const char *str2) 参数 str1 -- 要被检索的 C 字符串. str2 -- 该字符串包含了要在 str1 ...
- Android中相对布局的两个控件
<Button android:id="@+id/button3" android:layout_width="wrap_content" android ...
- web 安全登录算法
摘自:http://hi.baidu.com/weiqi228/blog/item/922e961bbcc2c0188618bfb5.html 对于 Web 应用程序,安全登录是很重要的.但是目前大多 ...
- .netFramework 升级NetCore 问题汇总及解决方案
升级版本: NetCore sdk 2.2.108 .AspNetCore 2.2.0.EFCore 2.2.6 所有程序引用均从NuGet上下载,并支持NetCore 问题: 问题1:No coer ...
- 2018-2019 20165226 Exp9 Web安全基础
2018-2019 20165226 Exp9 Web安全基础 目录 一.实验内容说明及基础问题回答 二.实验过程 Webgoat准备 XSS攻击 ① Phishing with XSS 跨站脚本钓鱼 ...