LoginSignup
0
0

More than 3 years have passed since last update.

redisのデータ調査用にCentOS 6にredis-rdb-toolsを入れた時のやり方

Last updated at Posted at 2019-05-22

user=hoge

$ wget https://bootstrap.pypa.io/2.6/get-pip.py
$ python get-pip.py --user
$ /home/hoge/.local/bin/pip install --upgrade pip --user
$ /home/hoge/.local/bin/pip install rdbtools python-lzf --user
$ pip install --upgrade pip --user

$ wget https://github.com/sripathikrishnan/redis-rdb-tools/archive/master.zip
$ unzip master.zip
$ cd redis-rdb-tools-master/
$ python setup.py install --user

$ /home/hoge/.local/bin/rdb --help

$ /home/hoge/.local/bin/rdb -c memory /var/redis/6379/dump.rdb --bytes 128 -f memory.csv
$ head memory.csv

database,type,key,size_in_bytes,encoding,num_elements,len_largest_element
0,list,lizards,241,quicklist,5,19
0,list,user_list,190,quicklist,3,7
2,hash,baloon,138,ziplist,3,11
2,list,armadillo,231,quicklist,5,20
2,hash,aroma,129,ziplist,3,11

基本は本家のインストール手順を確認してください。

気になった個所


rootのパスワードを聞くのが面倒だったため、すべてユーザ権限でインストール(python楽)

python2.6は古い系の警告が多かった。

gitのバージョンも古かったのでhttpsドメインに対してclone出来なかったが、zipからの解凍で回避。

CentOS6は、プログラムが古くて手間がかかりますね💦

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0