环境Debian 64 python 2.7.9
1、安装pip
sudo apt-get install python-setuptools
sudo easy_install pip
提示以下错误
.......
cffi.ffiplatform.VerificationError: importing '/home/hawk/g/f2/local/lib/python2.7/site-packages/cryptography/_Cryptography_cffi_70441dc9x8be47966.so': /home/hawk/g/f2/local/lib/python2.7/site-packages/cryptography/_Cryptography_cffi_70441dc9x8be47966.so: symbol EC_GFp_nistp521_method, version OPENSSL_1.0.1 not defined in file libcrypto.so.1.0.0 with link time reference
.......
因为缺少openssl和 libssl-dev
apt-get install openssl libssl-dev
2、用pip安装支持库
pip install tornado
pip install redis
pip install python-dateutil
3、下载RedisLive包
用户git clone https://github.com/kumarnitin/RedisLive.git
或者用wget下载zip包都可以
4、配置RedisLive
cd RedisLive/src
vim redis-live.conf
{
"RedisServers":
[
{
"server": "127.0.0.1",
"port" : 6379,
"password" : "111"
}
],
"DataStoreType" : "redis",
"RedisStatsServer":
{
"server" : "127.0.0.1",
"port" : 6379,
"password" : "111"
},
"SqliteStatsStore" :
{
"path": "to your sql lite file"
}
}
PS:需要密码认证的redis一定写上密码,否则运行redis-monitor.py时,会出现死循环。
4、运行RedisLive
cd RedisLive/src
./redis-monitor.py --duration 60 &
./redis-live.py &
浏览器打开 http://localhost:8888/index.html
安装完成