Created
September 22, 2015 17:14
-
-
Save andytill/511b9f68b581e5b9a4e6 to your computer and use it in GitHub Desktop.
riak util scripts.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## start_cluster.sh | |
for node in {1..3}; do dev/dev$node/bin/riak start; done | |
## cluster_up.sh (clusters the individualnodes) | |
for node in {2..3}; do dev/dev$node/bin/riak-admin cluster join 'dev1@127.0.0.1'; done | |
dev/dev1/bin/riak-admin cluster plan | |
dev/dev1/bin/riak-admin cluster commit | |
dev/dev1/bin/riak-admin member-status | |
## reconfig_to_leveldb.sh | |
echo Changing the backend config to use leveldb | |
PROP="storage_backend" | |
for i in {1..5}; do \ | |
sed -i.bak s/"$PROP = .*"/"$PROP = leveldb"/g dev/dev${i}/etc/riak.conf; \ | |
done | |
## reconfig_to_passive_aae.sh | |
echo reconfiguring to passive aae, read repair only. | |
PROP="anti_entropy" | |
for i in {1..5}; do \ | |
sed -i.bak s/"$PROP = .*"/"$PROP = passive"/g dev/dev${i}/etc/riak.conf; \ | |
done | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment