- (i) Sync-Rep (1): two VMs, one as the Redis leader and the other as a follower; and
- (ii) Sync-Rep (2): three VMs, one as the Redis leader and the other two as followers.
- Note: We run clients on follower VMs to force the system to have one RTT so that it’s compatible with SMR-based approach.
-
Start VMs
- Start appropriate number of VMs according to Sync-Rep (1) or (2).
- OS Assumption: Ubuntu 16.04
-
On each VM, complete the following steps:
-
Clone Rabia repository
sudo su mkdir -p ~/go/src && cd ~/go/src git clone https://github.com/haochenpan/rabia.git
-
Install Rabia and its dependencies (Dependencies of Sync-Rep are included in Rabia's installation script.)
cd ./rabia/deployment . ./install/install.sh
-
Clone Sync-Rep repository
cd ~/go/src git clone https://github.com/YichengShen/redis-sync-rep.git cd redis-sync-rep
-
Configure IP of master VM
- In
config.yaml
, change 'MasterIp' to the IP of your master VM.
- In
-
Start Redis server: You could configure the current VM either as a master or a replica.
- configure as master
. ./deployment/startRedis/startServer.sh
- configure as replica
. ./deployment/startRedis/startServer.sh replica
- configure as master
-
Adjust parameters related to batching in
config.yaml
- Change ‘NClients’ and ‘ClientBatchSize’.
-
-
From one of the client VMs, run the main program
go run main.go
The program will run according to the configuration file and print out the results which will also be saved in the logs folder.