jedis 连接 redis:Could not get a resource from the pool——我的出错原因和解决办法
windows 下安装的,本机使用
现象:刚装好开发使用好好的, 重启电脑后就报这个错
网上的所有可能都试过,没有用。
最后,放弃所有包装,用最原始的代码进行连接测试:
Jedis jedis=new Jedis("127.0.0.1");
jedis.auth("7777");//password
jedis.set("firstKey", "hello redis!");
ERR Client sent AUTH, but no password is set
于是,重新设置密码:
redis 127.0.0.1:6379> CONFIG SET requirepass "123456"
OK
redis 127.0.0.1:6379> AUTH 123456
Ok
问题解决!!!
可是,我之前明明设置了密码的,为什么一重启密码就不起作用了呢?
于是,关掉服务器,再打开,重新跑了一下测试代码,玛尼???这个错误又出来啦!!!
参见:
http://blog.csdn.net/rchm8519/article/details/48347797
jedis 连接 redis:Could not get a resource from the pool——我的出错原因和解决办法的更多相关文章
- 通过jedis连接redis单机成功,使用redis客户端可以连接集群,但使用JedisCluster连接redis集群一直报Could not get a resource from the pool
一,问题描述: (如题目)通过jedis连接redis单机成功,使用JedisCluster连接redis集群一直报Could not get a resource from the pool 但是使 ...
- redis使用问题一:Cannot get Jedis connection; nested exception is redis.clients.jedis.exceptions.JedisException: Could not get a resource from the pool] with root cause
本文使用的是spring-data-redis 首先说下redis最简单得使用,除去配置. 需要在你要使用得缓存得地方,例如mybatis在mapper.xml中加入: <cache evict ...
- 用Jedis连接Redis
jedis中的方法名,和Redis的命令几乎一样 1.jar包,作为测试只需要一个jar 2.代码 package com; import java.util.HashMap; import java ...
- redis.clients.jedis.exceptions.JedisConnectionException: Could not get a resource from the pool
超时 Exception in thread "main" redis.clients.jedis.exceptions.JedisConnectionException: jav ...
- Java 使用Jedis连接Redis数据库(-)
redis 安装: Linux 安装redis 1)下载jar包: 使用Jedis需要以下两个jar包: jedis-2.8.0.jar commons-pool2-2.4.2.jar 2)测试red ...
- jedis 连接 redis
一.连接单机版的 redis /** * 直接连接 redis * @throws Exception */ @Test public void test1() throws Exception { ...
- jedis异常:Could not get a resource from the pool
前几天公司后端系统出现了故障,导致app多个功能无法使用,查看日志,发现日志出现较多的redis.clients.jedis.exceptions.JedisConnectionException: ...
- Java链接Redis时出现 “ERR Client sent AUTH, but no password is set” 异常的原因及解决办法
Java链接Redis时出现 "ERR Client sent AUTH, but no password is set" 异常的原因及解决办法 [错误提示] redis.clie ...
- pip install 提示代理连接失败原因及解决办法
# pip install 提示代理连接失败原因及解决办法 1. 错误提示 在公司电脑上安装Python的虚拟环境时输入命令: pip install virtualenv 系统提示以下异常信息: R ...
随机推荐
- centos7 做rails 执行rails server 报错
做操作rails server 时 报错 这个错误时因为一些东西没有安装 gem install execjsgem install therubyracersudo apt-get insta ...
- LayoutInflater作用及使用(转)
作用: 1.对于一个没有被载入或者想要动态载入的界面, 都需要使用inflate来载入. 2.对于一个已经载入的Activity, 就可以使用实现了这个Activiyt的的findViewById方法 ...
- HDU 4731 Minimum palindrome (2013成都网络赛,找规律构造)
Minimum palindrome Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Other ...
- 在ASP.NET Web API中使用OData的Containment
通常情况下,一个OData的EDM(Entity Data Model)在配置的时候定义了,才可以被查询或执行各种操作.比如如下: builder.EntitySet<SomeModel> ...
- 一个例子来看C#泛型是如何登场的
有这样一个有关汽车的类. public class Car { public int ID { get; set; } public string Make { get; set; } } 现在,在客 ...
- finger-guessing game:1场景搭建
场景搭建 //初始化legend组件 init(50, "div_caiquan", 800, 400, main); //定义游戏层 //游戏背景层,结果显示层,点击层 var ...
- oracle exp/imp命令详解
E:\>exp help=y 通过输入 EXP 命令和用户名/口令,您可以 在用户 / 口令之后的命令: 实例: EXP SCOTT/TIGER 或者,您也可以通过输入跟有各种参数的 EXP 命 ...
- 一分钟掌握Android spinner下拉框
Android 自带的spinner下拉框控件是一个不错的系统控件.主要有两种实现方式: 1.静态的spinner 在res\values中加入一个city资源数组文件 2 <resources ...
- 每天一个linux命令-ls命令
查看统计当前目录下文件的个数,包括子目录里的. ls -lR| grep "^-" | wc -l[喝小酒的网摘]http://blog.hehehehehe.cn/a/12311 ...
- XVFB实现selenium在linux上无界面运行安装篇
selenium在linux上无界面运行,其实是非常简单的.具体的方法有使用HtmlUnitDriver或者PhantomJSDriver,有时间我会写写关于这两个东东的文章,其实基本和ChromeD ...