redis常用命令小结
转载于:http://www.itxuexiwang.com/a/shujukujishu/redis/2016/0216/107.html?1455867352
1、redis-benchmark
redis基准信息,redis服务器性能检测
redis-benchmark -h localhost -p 6379 -c 100 -n 100000
100个并发连接,100000个请求,检测host为localhost 端口为6379的redis服务器性能
[root@Architect redis-1.2.6]# redis-benchmark -h localhost -p 6379 -c 100 -n 100000====== PING ====== 10001 requests completed in 0.41 seconds 50 parallel clients 3 bytes payload keep alive: 10.01% <= 0 milliseconds23.09% <= 1 milliseconds85.82% <= 2 milliseconds95.60% <= 3 milliseconds97.20% <= 4 milliseconds97.96% <= 5 milliseconds98.83% <= 6 milliseconds99.41% <= 7 milliseconds99.70% <= 8 milliseconds99.99% <= 9 milliseconds100.00% <= 12 milliseconds24274.27 requests per second
2、redis-cli
redis-cli -h localhost -p 6380 monitor
Dump all the received requests in real time;
监控host为localhost,端口为6380,redis的连接及读写操作
[root@Architect redis-1.2.6]# redis-cli -h localhost -p 6380 monitor+OK+1289800615.808225 "monitor"+1289800615.839079 "GET" "name"+1289800615.853694 "PING"+1289800615.853783 "PING"+1289800615.854646 "PING"+1289800615.854974 "PING"+1289800615.857693 "PING"+1289800615.866862 "PING"+1289800615.871944 "PING"#p#分页标题#e#
redis-cli -h localhost -p 6380 info
Provide information and statistics about the server ;
提供host为localhost,端口为6380,redis服务的统计信息
[root@Architect redis-1.2.6]# redis-cli -h localhost -p 6380 inforedis_version:2.0.4redis_git_sha1:00000000redis_git_dirty:0arch_bits:32multiplexing_api:epollprocess_id:21990uptime_in_seconds:490580uptime_in_days:5connected_clients:103connected_slaves:0blocked_clients:0used_memory:4453240used_memory_human:4.25Mchanges_since_last_save:200bgsave_in_progress:0last_save_time:1290394640bgrewriteaof_in_progress:0total_connections_received:809total_commands_processed:44094018expired_keys:0hash_max_zipmap_entries:64hash_max_zipmap_value:512pubsub_channels:0pubsub_patterns:0vm_enabled:0role:slavemaster_host:localhostmaster_port:6379master_link_status:upmaster_last_io_seconds_ago:18db0:keys=1319,expires=0
3、redis-stat
redis-stat host localhost port 6380 overview
Print general information about a Redis instance;
实时打印出host为localhost,端口为6380,redis实例的总体信息
[root@Architect redis-1.2.6]# redis-stat port 6380 overview ------- data ------ ------------ load ----------------------------- - childs - keys used-mem clients requests connections 1319 5.37M 103 44108021 (+44108021) 810 1319 5.38M 103 44108124 (+103) 810 1319 5.38M 103 44108225 (+101) 810 1319 5.39M 103 44108326 (+101) 810 1319 5.40M 103 44108427 (+101) 810 1319 5.41M 103 44108528 (+101) 810 #p#分页标题#e#
redis-stat host localhost port 6380 overview
Measure Redis server latency;
输出host为localhost,端口为6380,redis服务中每个请求的响应时长
[root@Architect redis-1.2.6]# redis-stat port 6380 latency1: 0.16 ms2: 0.11 ms3: 0.15 ms4: 0.11 ms5: 0.18 ms6: 0.14 ms
redis常用命令小结的更多相关文章
- Redis常用命令
Redis常用命令Redis提供了丰富的命令对数据库和各种数据类型进行操作,这些命令可以再Linux终端使用.1.键值相关命令2.服务器相关命令 一.键值相关命令 1.get get 键值 当 key ...
- 第2讲 Redis常用命令与高级应用
目录 一.redis数据类型 5. sorted sets类型和操作 二.Redis常用命令 1.键值相关命令 2.服务器相关命令 三. redis高级应用 1. 给redis服务器设置密码 2.持久 ...
- Redis常用命令手册:服务器相关命令
Redis提供了丰富的命令(command)对数据库和各种数据类型进行操作,这些command可以在Linux终端使用.在编程时,比如各类语言包,这些命令都有对应的方法.下面将Redis提供的命令做一 ...
- [转]MySQL数据库备份和还原的常用命令小结
MySQL数据库备份和还原的常用命令小结,学习mysql的朋友可以参考下: 备份MySQL数据库的命令 mysqldump -hhostname -uusername -ppassword datab ...
- redis redis常用命令及内存分析总结(附RedisClient工具简介
redis常用命令及内存分析总结(附RedisClient工具简介 by:授客 QQ:1033553122 redis-cli工具 查看帮助 连接redis数据库 常用命令 exists key se ...
- [转帖]Windows批处理(cmd/bat)常用命令小结
Windows批处理(cmd/bat)常用命令小结 非常值得学习的文档 先放这里 有时间做实验, 转载自:“趣IT”微信公共号 前言 批处理文件(batch file)包含一系列 DOS命令,通常用于 ...
- Redis常用命令与高级应用
附: 127.0.0.1:6379> set xiaofei 小飞 OK 127.0.0.1:6379> get xiaofei "\xe5\xb0\x8f\xe9\xa3\x9 ...
- Redis快速起步及Redis常用命令大全
本系列教程内容提要 Java工程师之Redis实战系列教程教程是一个学习教程,是关于Java工程师的Redis知识的实战系列教程,本系列教程均以解决特定问题为目标,使用Redis快速解决在实际生产中的 ...
- redis配置密码 redis常用命令
redis配置密码 1.通过配置文件进行配置yum方式安装的redis配置文件通常在/etc/redis.conf中,打开配置文件找到 [plain] view plain copy #requi ...
随机推荐
- 由Selenium1转变为Selenium2所遇到的问题
1.使用ant脚本运行测试,报NoClassDefError,但使用junit方式运行或debug,都没有错误. 原因:找不到包,但具体是哪个包,不清楚:且为何使用junit方式运行就没有问题,也不清 ...
- Features
imhist分析灰度图阈值分界点 bwlabel分析连通区域 SIFT Scale Invariant:尺度不变性 DoG: Difference of Gaussian, calculated by ...
- 用户行为数据采集核心思维(APP、web数据采集/埋点)
关于数据采集(也就是所谓的埋点),有很多中形式,或者说方法.所有的数据采集都时围绕一个核心的三个点来做区别的处理. 数据采集核心思维三个点: 1.对象: 要采集谁,一个页面.一个按钮,页面或者按钮,就 ...
- swift基础语法(四) 函数、闭包(Closures)
//函数基本定义 func 函数名(参数名:参数类型=默认值) ->返回值类型{代码块} //无参无返回值函数 func hsmin(){ } //单参无返回值函数 func prin(st:S ...
- Taylor定理证明
下图,单独打开查看 当n->inf时如果 Rn(c)趋0, c属于(a,x), 那么在区间(a,x) 内函数在a点生成的taylor级数收敛到函数f.
- 我与solr(一)--solr的配置与安装
感谢upxiaofeng的分享,转载自http://blog.csdn.net/zoubf/article/details/51505940 准备工作: 目前最新版本6.0.下载solr 6.0:So ...
- 解决Ubuntu下Chrome浏览器网页中文字体混乱
在Ubuntu下使用Chrome浏览器时碰到了网页中文字体混乱的现象: 黑体和楷体混杂,看起来非常不美观. 这是由于许多网页并没有指定字体,然后浏览器将调用系统默认字体配置. 首先,安装文泉驿字体: ...
- 算法入门笔记------------Day1
1.C语言使用%d显示float值,不会把float值转换为近似的int值,而是显示垃圾值,使用%f显示int值,也不会把该int值转换为浮点值 2.三位数反转:输入一个三位数,分离它的百位,十位和个 ...
- Lisp 函数
(quote x) [返回x] >>>>>>>>>>>>>>>>>>>>> ...
- WPF 自定义TextBox,可控制键盘输入内容
非原创,整理之前的代码的时候找出来的,可用,与大家分享一下! public class NumbericBoxWithZero : NumericBox { public NumbericBoxWit ...