Create redis master-slave with python
First,plz install hiredis
[root@localhost~]#easy_install hiredis
Add a new slave, MASTER-PASSWD is optional
[root@localhost ~]#python redis-mr.py replcate MASTER_HOST:MASTER_PORT SLAVE_HOST:SLAVE_PORT [MASTER-PASSWD]
Delete a slave or promote a slave to master
[root@localhost ~]#python redis-mr.py delete SLAVE_HOST:SLAVE_PORT
Shutdown the redis server
[root@localhost ~]#python redis-mr.py shutdown HOST:PORT