redis启动警告问题:WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value of 128
摘要:1.启动redis,命令: redis-server redis.conf路径文件 2.会发现warning警告,WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxco
阅读全文
posted @
2024-06-01 00:54
卖小女孩的小男孩
阅读(256)
推荐(0)
记一次Redis故障的排查
摘要:背景:最近在公司dev服务器上搭建的redis总会出现异常,需要重启才能正常工作,严重影响开发效率,试图排查解决该问题 步骤:查看redis配置文件:查看/etc/redis.conf文件 loglevel noticelogfile /var/log/redis/redis.log12查看日志文件
阅读全文
posted @
2021-05-21 15:58
卖小女孩的小男孩
阅读(491)
推荐(0)
Failed opening the RDB file root (in server root dir /etc/cron.d) for saving: Permission denied
摘要:问题描述最近在自己的server上的redis命令行碰到set key错误的问题,返回结果如下: set a 1(error) MISCONF Redis is configured to save RDB snapshots, but is currently not able to persis
阅读全文
posted @
2021-05-21 14:24
卖小女孩的小男孩
阅读(1874)
推荐(0)
使用Redis简单实现分布式锁
摘要:分布式锁 分布式锁的几种实现方式:mamcache、redis、zookeeper,本片就redis实现分布式锁进行简单的介绍与实现 redis实现分布式锁 加锁 最简单的方法是使用setnx命令,key是唯一的标志,可以按照业务来命名,而value最好的做法是使用线程ID setnx(key, t
阅读全文
posted @
2021-01-01 15:29
卖小女孩的小男孩
阅读(183)
推荐(0)
MISCONF Redis is configured to save RDB snapshots, but it is currently not a
摘要:开发环境最近遇到了"MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on disk"的问题,服务出现了问题,一看日志是Redis在报这个错误。 查了查网上的资料,解决方案基
阅读全文
posted @
2020-12-09 19:23
卖小女孩的小男孩
阅读(1776)
推荐(0)
Sentinel使用
摘要:基本原理 Sentinel 的原理并不复杂: 启动 n 个 sentinel 实例,这些 sentinel 实例会去监控你指定的 redis master/slaves 当 redis master 节点挂掉后, Sentinel 实例通过 ping 检测失败发现这种情况就认为该节点进入 SDOWN
阅读全文
posted @
2020-06-02 13:22
卖小女孩的小男孩
阅读(91)
推荐(0)
Redis命令操作详解
摘要:一、key pattern 查询相应的key (1)redis允许模糊查询key 有3个通配符 *、?、[] (2)randomkey:返回随机key (3)type key:返回key存储的类型 (4)exists key:判断某个key是否存在 (5)del key:删除key (6)renam
阅读全文
posted @
2020-06-01 02:29
卖小女孩的小男孩
阅读(87)
推荐(0)