Exception in thread “main“ redis.clients.jedis.exceptions.JedisConnectionException: .......

简介: 对于防火墙可开放对应端口,或者直接关闭防火墙,开放对应端口如下

原因分析:

1)机器之间网络无法联通

2)ip和端口号不正确

3)虚拟机中防火墙的原因(可能性较大)

4)redis.conf 中bind 127.0.0.1 未用#注释掉

对于防火墙可开放对应端口,或者直接关闭防火墙,开放对应端口如下

输入:systemctl stop firewalld.service   执行停止运行防火墙命令

注释bind 127.0.0.1(注意不要被上方的这个所迷惑)

2345_image_file_copy_230.jpg

意思是不能在redis 保护模式下不安全的访问,解决如下:

在linux 中连接客户端,设置密码,config set requirepass "123456"  //123456为密码

或者进入配置文件将如下改为 no

2345_image_file_copy_232.jpg

2345_image_file_copy_231.jpg至此,应该可以连接上了

目录
相关文章
|
NoSQL Java Redis
Redis - Redis command timed out nested exception is io.lettuce.core.RedisCommandTimeoutException
Redis - Redis command timed out nested exception is io.lettuce.core.RedisCommandTimeoutException
3963 0
|
NoSQL 安全 Java
解决Unknown redis exception及event executor terminated错误的方法
解决这类问题时,保持耐心和细致是关键。通常,通过系统地检查和排除潜在原因,大多数问题最终都能被解决。
2846 1
|
NoSQL Java Redis
【问题篇】解决Unable to connect to Redis; nested exception is io.lettuce.core.RedisConnectionException
【问题篇】解决Unable to connect to Redis; nested exception is io.lettuce.core.RedisConnectionException
4886 0
|
NoSQL Linux 网络安全
解决Caused by: java.net.SocketTimeoutException: connect timed out Exception in thread “main“ redis.cli
解决Caused by: java.net.SocketTimeoutException: connect timed out Exception in thread “main“ redis.cli
692 0
|
Web App开发 Java Apache
HTTP Status 500 - Cannot get Jedis connection; nested exception is redis.clients.jedis.exceptions.Je
HTTP Status 500 - Cannot get Jedis connection; nested exception is redis.clients.jedis.exceptions.JedisConnectionException: Could not get a resource...
3356 0
|
缓存 NoSQL 关系型数据库
美团面试:MySQL有1000w数据,redis只存20w的数据,如何做 缓存 设计?
美团面试:MySQL有1000w数据,redis只存20w的数据,如何做 缓存 设计?
美团面试:MySQL有1000w数据,redis只存20w的数据,如何做 缓存 设计?
|
缓存 NoSQL Java
Redis+Caffeine构建高性能二级缓存
大家好,我是摘星。今天为大家带来的是Redis+Caffeine构建高性能二级缓存,废话不多说直接开始~
2059 0
|
缓存 负载均衡 监控
135_负载均衡:Redis缓存 - 提高缓存命中率的配置与最佳实践
在现代大型语言模型(LLM)部署架构中,缓存系统扮演着至关重要的角色。随着LLM应用规模的不断扩大和用户需求的持续增长,如何构建高效、可靠的缓存架构成为系统性能优化的核心挑战。Redis作为业界领先的内存数据库,因其高性能、丰富的数据结构和灵活的配置选项,已成为LLM部署中首选的缓存解决方案。
1208 25
|
存储 缓存 NoSQL
Redis专题-实战篇二-商户查询缓存
本文介绍了缓存的基本概念、应用场景及实现方式,涵盖Redis缓存设计、缓存更新策略、缓存穿透问题及其解决方案。重点讲解了缓存空对象与布隆过滤器的使用,并通过代码示例演示了商铺查询的缓存优化实践。
593 1
Redis专题-实战篇二-商户查询缓存
|
缓存 运维 监控
Redis 7.0 高性能缓存架构设计与优化
🌟蒋星熠Jaxonic,技术宇宙中的星际旅人。深耕Redis 7.0高性能缓存架构,探索函数化编程、多层缓存、集群优化与分片消息系统,用代码在二进制星河中谱写极客诗篇。
2235 3

热门文章

最新文章