redis数据库下载?如何连接redis数据库
大家好,感谢邀请,今天来为大家分享一下redis数据库下载的问题,以及和如何连接redis数据库的一些困惑,大家要是还不太明白的话,也没有关系,因为接下来将为大家分享,希望可以帮助到大家,解决大家的问题,下面就开始吧!
怎么获得windows版Redis数据库
怎么获得windows版Redis数据库 Redis on Windows 2.6 prototype Whats new in this release新特性 Thisis a port for Windows based on Redis 2.6. The latest version merged in 2.6.12.这是基于Redis2.6的WINDOWS接口,基于Redis2.6.12的最新版本 Theport
怎么获得windows版Redis数据库
Redis on Windows 2.6 prototype
What's new in this release新特性
· Thisis a port for Windows based on Redis 2.6. The latest version merged in 2.6.12.
·这是基于Redis2.6的WINDOWS接口,基于Redis2.6.12的最新版本
· Theport is similar to the port of Redis 2.4, including the same background savingtechnology.
·此版本的接口同2.4版本相似,使用了同样的后台保存技术.
· Thereis support for x64 version as well as 32 bit versions
·支持64位和32位.
· Forthe 64 bit version, there is a limit of 2^32 objects in a structure, and a maxlength of 2^32 for any object
·在64位版本中,在一个结构类型中最多有2^32个对象,每个对象的最大数据长度为2^32
· Versionnumber now 2.6.8-pre2 to indicate prerelease and to enable changing
·最新的版本是即将发布的2.6.8-pre2,
· Version2.6.8-pre2 fixes several failures that existed in 2.6.8-pre1. Most of thesewere related to handling opening and closing of non-blocking sockets.
· 2.6.8-pre2版本解决了2.6.8-pre1版本中的一些问题,这些问题主要是关于处理打开和关闭非阻塞套接字
· Theunit/protocol desync test is updated to use nonblocking socket and now works onWindows
·经过不同步单元测试非阻塞套接字,证明程序是有效的.
· Thebinaries(unsigned) have been moved to the root to make them easier to find.Previously they were under msvs.
·未签名的程序集被移至根目录下,而之前放在microsoft visual studio目录中
· Signedbinaries can be downloaded using Nuget.
·经过签名的程序集可以在Nuget中下载
Acknowledgements鸣谢
Specialthanks to Du?an Majkic(https://github.com/dmajkic, https://github.com/dmajkic/redis/) for hisproject on GitHub that gave us the opportunity to quickly learn some on theintricacies of Redis code. His project also helped us to build our prototypequickly.
Repo branches
· 2.6:This is the branch for the Windows Redis port based on Redis 2.6.
·这是基于Redis 2.6.的windows接口
· 2.4:This branch has the Windows Redis port based on Redis 2.4.
·这个windows接口同样支持Redis 2.4.
How to build Redis using Visual Studio
怎样使用VS创建Redis数据库
Youcan use the free Express Edition available at http://www.microsoft.com/visualstudio/en-us/products/2010-editions/visual-cpp-express.
可以下载使用VS2010免费简易版
· Openthe solution file msvs\redisserver.sln in Visual Studio 10, select platform(win32 or x64) and build.
Thisshould create the following executables in the msvs\$(Configuration) folder:
使用VS2010打开redisserver.sln解决方案,选择32或64位平台并生成程序.在生成的目录中将包括以下可执行文件.
o redis-server.exe
o redis-benchmark.exe
o redis-cli.exe
o redis-check-dump.exe
o redis-check-aof.exe
Foryour convenience all binaries are be available in the msvs/bin/release|debugdirectories.
所有的程序集在bin/release|debug模块中都可以找到
RedisWatcher Redis查看器
So farthe RedisWatcher is not carried over to 2.6. However this should not beaffected by the Redis version, and the code in the 2.4 branch should work withthe Redis 2.6 binaries.
目前Redis查看器还没有升级到2.6,但是应该不影响使用,2.4版本中的代码应该可以在2.6中运行.
RedisWAInst
So farthe RedisWAInst is not carried over to 2.6. However this should not be affectedby the Redis version, and the code in the 2.4 branch should work with the Redis2.6 binaries.
目前RedisWAInst还没有升级到2.6,但是应该不影响使用,2.4版本中的代码应该可以在2.6中运行.
Release Notes备注
Thebranch has been renamed from 2.6_alpha to 2.6 to indicate that the test passhas been completed.
测试已经通过,版本从2.6_alpha升级为 2.6
Thisis a release version of the software.
此为正式版本
To runthe Redis test suite requires some manual work:
运行测试套件,需要进行一些手动配置:
· Thetests assume that the binaries are in the src folder, so you need to copy thebinaries from the msvs folder to src.
·测试要求所有的程序集位于src文件夹中,所以你需要把程序集从复制到src文件夹中
· Thetests make use of TCL. This must be installed separately.
测试需要单独安装TCL(Tool Command Language)http://baike.baidu.com/subview/5085/8048844.htm#viewPageContent,
· To runthe tests you need to have a Unix shell on your machine. To execute the tests,run the following command: tclsh8.5.exetests/test_helper.tcl.
·运行测试还需要安装unix shell并且运行如下命令
· tclsh8.5.exetests/test_helper.tcl
If aUnix shell is not installed you may see the following error message:"couldn't execute"cat": no such file or directory".
如果你没有安装unix shell,你将看到下面的错误信息:
"couldn'texecute"cat": no such file or directory".
《Redis设计与实现》pdf下载在线阅读,求百度网盘云资源
《Redis设计与实现》(黄健宏)电子书网盘下载免费在线阅读
资源链接:
链接:https://pan.baidu.com/s/1M0lgX6oCAbCTQfyVSURJyQ密码:g1k5
书名:Redis设计与实现
作者:黄健宏
豆瓣评分:8.6
出版社:机械工业出版社
出版年份:2014-6
页数:388
内容简介:
【官方网站】
本书的官方网站 www.RedisBook.com提供了书本试读、相关源码下载和勘误回报等服务,欢迎读者浏览和使用。
【编辑推荐】
系统而全面地描述了 Redis内部运行机制
图示丰富,描述清晰,并给出大量参考信息,是NoSQL数据库开发人员案头必备
包括大部分Redis单机特征,以及所有多机特性
【读者评价】
这本书描述的知识点很丰富,覆盖很全,里面提到特性较多,有不少我们也没用过:)每个命令内部的机制的介绍很不错,很多估计也是首次有详细文档介绍。
——杨卫华(@TimYang)新浪微博技术总监
近几年Redis以其高性能、高灵活性的优点,变得越来越流行。但很多人在使用Redis时,仅仅还是停留在比较表层的功能性认识,缺乏对内部机制原理的深入理解。本书是huangz同学长期对Redis源码的阅读心得结晶,书中对Redis的各个方面都进行了详细且深入的讲解,将复杂的原理用最简单的方式为大家解构和讲解,强烈推荐给每一位Redis的使用者阅读。
—— iammutex,NoSQLFan站长,乐视网技术经理
Redis是近些年来特别火爆的 NoSQL之一。纵观中外各种书籍还没有一本能对 Redis内部进行深入剖析,《Redis设计与实现》可谓开此先河。常和作者在网上交流,知道作者为这本书付出了大量的心血。这本书行文流畅,思路清晰,详细地介绍了 Redis源码的方方面面。无论是想学习 NoSQL、网络编程的初学者,还是源码控的进阶者,本书都会有很大的帮助。
——阮若夷,支付宝高级专家
【内容简介】
本书全面而完整地讲解了Redis的内部机制与实现方式,对Redis的大多数单机功能以及所有多机功能的实现原理进行了介绍,展示了这些功能的核心数据结构以及关键的算法思想,图示丰富,描述清晰,并给出大量参考信息。通过阅读本书,读者可以快速、有效地了解Redis的内部构造以及运作机制,更好、更高效地使用Redis。
本书主要分为四大部分。第一部分“数据结构与对象”介绍了Redis中的各种对象及其数据结构,并说明这些数据结构如何影响对象的功能和性能。第二部分“单机数据库的实现”对Redis实现单机数据库的方法进行了介绍,包括数据库、RDB持久化、AOF持久化、事件等。第三部分“多机数据库的实现”对Redis的Sentinel、复制、集群三个多机功能进行了介绍。第四部分“独立功能的实现”对Redis中各个相对独立的功能模块进行了介绍,涉及发布与订阅、事务、Lua脚本、排序、二进制位数组、慢查询日志、监视器等。本书作者专门维护了www.redisbook.com网站,提供带有详细注释的Redis源代码,以及本书相关的更新内容。
作者简介:
黄健宏软件开发者,他喜欢函数式编程,热爱开源软件。出于对数据库的强烈兴趣,他开始阅读和分析 Redis源代码,并对 Redis 2.6和 Redis 3.0的源代码进行了详细注释。他翻译并维护着 Redis中文文档网站 www.RedisDoc.com,编写了 OORedis库。除此之外,他还是《Redis in Action》一书的译者。
作者的豆瓣主页:douban.com/people/i_m_huangz/
如何连接redis数据库
1、在配置文件redis.conf中把绑定的Ip注释掉
2、在配置文件redis.conf中把protected-mode改为 no
3、在配置文件redis.conf中把requirepass设置redis访问授权密码(自己随意设置就好),也可以登录redis客户端使用命令设置:如下:
./redis-cli
config set requirepass 123//123是密码
经过以上三步基本就可以了,不过也有特殊情况,访问的端口号6379有可能会被防火墙拦截,需要关闭系统的防火墙或取消对6379端口的拦截,这里不在细述。
接下来就可以创建项目实现操作redis数据库了。在这里我用的开发工具是eclipse,在eclipse中创建一个java Project项目如下图所示:
项目创建完成后,在src同级目录下创建lib文件夹,导入操作数据库所需jar包(晚上自行下载),jedis用来操作数据库,commons-pool用来实现数据库连接池。
启动redis服务器:
创建RedisDemoSimple.java代码如下:
packagecom.redis.redisDb;
importredis.clients.jedis.Jedis;publicclassRedisDemoSimple{publicstaticvoidmain(String[]args){//ip地址为虚拟机Ip端口为redis端口
Jedisjedis=newJedis("192.168.228.129",6379);//redis访问权限为redis配置文件中redis.conf中配置的requirepass
jedis.auth("myredis");
jedis.set("redis_first","hello");
System.out.println("keyredis_first:"+jedis.get("redis_first"));
}
}
控制台打印如下:
启动redis客户端查询插入数据库的值:
到此就连接成功了。
好了,本文到此结束,如果可以帮助到大家,还望关注本站哦!