Mercurial > hg > Members > nobuyasu > jungle_benchmark
changeset 16:704bcc773b96
Modifed capistrano file
author | Nobuyasu |
---|---|
date | Fri, 24 Jan 2014 18:09:16 +0900 |
parents | 6e7a01afaaf8 |
children | 9ecbc7400fbb |
files | distributed/capistrano_jungle.rb distributed/hello_post.rb distributed/nodes.txt distributed/nodes_stress_write_cassandra.rb |
diffstat | 4 files changed, 50 insertions(+), 116 deletions(-) [+] |
line wrap: on
line diff
--- a/distributed/capistrano_jungle.rb Thu Jan 23 05:52:31 2014 +0900 +++ b/distributed/capistrano_jungle.rb Fri Jan 24 18:09:16 2014 +0900 @@ -1,45 +1,19 @@ set :user, "mass" - -role :pall00, "133.13.62.1","133.13.62.2","133.13.62.3","133.13.62.4","133.13.62.5","133.13.62.6","133.13.62.7","133.13.62.8","133.13.62.9","133.13.62.10" -role :pall01, "133.13.62.11","133.13.62.12","133.13.62.13","133.13.62.14","133.13.62.15","133.13.62.16","133.13.62.17","133.13.62.18","133.13.62.19","133.13.62.20" -role :pall02, "133.13.62.21","133.13.62.22","133.13.62.23","133.13.62.24","133.13.62.25","133.13.62.26","133.13.62.27","133.13.62.28","133.13.62.29","133.13.62.30" -role :pall03, "133.13.62.31","133.13.62.32","133.13.62.33","133.13.62.34","133.13.62.35","133.13.62.36","133.13.62.37","133.13.62.38","133.13.62.39","133.13.62.40" -role :pall04, "133.13.62.41","133.13.62.42","133.13.62.43","133.13.62.44","133.13.62.45","133.13.62.46","133.13.62.47","133.13.62.48" - - - -# -# 62.1(mass01) and 62.48(mass48) remove from the list. -# -# bldsv03 : use mass12 ~ mass15 (All : mass12 ~ mass17) -#role :pall00, "mass12.cs.ie.u-ryukyu.ac.jp","mass13.cs.ie.u-ryukyu.ac.jp","mass14.cs.ie.u-ryukyu.ac.jp","mass15.cs.ie.u-ryukyu.ac.jp" - -# bldsv04 : use mass18 ~ mass21 (All: mass18 ~ mass23) -#role :pall01, "mass18.cs.ie.u-ryukyu.ac.jp","mass19.cs.ie.u-ryukyu.ac.jp","mass20.cs.ie.u-ryukyu.ac.jp","mass21.cs.ie.u-ryukyu.ac.jp" +role :pall00, "133.13.62.44","133.13.62.45","133.13.62.46","133.13.62.47","133.13.62.48" -# bldsv05 : use mass24 ~ mass27 (All: mass24 ~ mass29) -#role :pall02, "mass24.cs.ie.u-ryukyu.ac.jp","mass25.cs.ie.u-ryukyu.ac.jp","mass26.cs.ie.u-ryukyu.ac.jp","mass27.cs.ie.u-ryukyu.ac.jp" - -# bldsv06 : use mass30 ~ mass33 (All: mass30 ~ mass35) -#role :pall03, "mass30.cs.ie.u-ryukyu.ac.jp","mass31.cs.ie.u-ryukyu.ac.jp","mass32.cs.ie.u-ryukyu.ac.jp","mass33.cs.ie.u-ryukyu.ac.jp" - -# bldsv07 : use mass36 ~ mass38 (All: mass36 ~ mass41) -#role :pall04, "mass36.cs.ie.u-ryukyu.ac.jp","mass37.cs.ie.u-ryukyu.ac.jp","mass38.cs.ie.u-ryukyu.ac.jp","mass39.cs.ie.u-ryukyu.ac.jp" +#role :pall00, "133.13.62.44","133.13.62.45","133.13.62.46","133.13.62.47" +#role :pall01, "133.13.62.39","133.13.62.40","133.13.62.41","133.13.62.42","133.13.62.43" +#role :pall02, "133.13.62.34","133.13.62.35","133.13.62.36","133.13.62.37","133.13.62.38" +#role :pall03, "133.13.62.29","133.13.62.30","133.13.62.31","133.13.62.32","133.13.62.33" +#role :pall04, "133.13.62.19","133.13.62.20","133.13.62.21","133.13.62.22","133.13.62.23","133.13.62.24","133.13.62.25","133.13.62.26","133.13.62.27","133.13.62.28" +#role :pall05, "133.13.62.9","133.13.62.10","133.13.62.11","133.13.62.12","133.13.62.13","133.13.62.14","133.13.62.15","133.13.62.16","133.13.62.17","133.13.62.18" +#role :pall06, "133.13.62.1","133.13.62.2","133.13.62.3","133.13.62.4","133.13.62.5","133.13.62.6","133.13.62.7","133.13.62.8" -# bldsv08 : use mass42 ~ mass45 (All: mass42 ~ mass48) -#role :pall05, "mass42.cs.ie.u-ryukyu.ac.jp","mass43.cs.ie.u-ryukyu.ac.jp","mass44.cs.ie.u-ryukyu.ac.jp","mass45.cs.ie.u-ryukyu.ac.jp" - -#role :pall00, "mass12.cs.ie.u-ryukyu.ac.jp" +#*** CR *** +#role :pall07, "133.13.62.101", "133.13.62.102" +#role :pall08, "133.13.62.103","133.13.62.104","133.13.62.105","133.13.62.106","133.13.62.107","133.13.62.108","133.13.62.109","133.13.62.110","133.13.62.111","133.13.62.112" -#role :pall00, "mass12.cs.ie.u-ryukyu.ac.jp","mass18.cs.ie.u-ryukyu.ac.jp" -#role :pall00, "mass12.cs.ie.u-ryukyu.ac.jp","mass18.cs.ie.u-ryukyu.ac.jp","mass24.cs.ie.u-ryukyu.ac.jp","mass30.cs.ie.u-ryukyu.ac.jp" -#role :pall01, "mass13.cs.ie.u-ryukyu.ac.jp","mass19.cs.ie.u-ryukyu.ac.jp","mass25.cs.ie.u-ryukyu.ac.jp","mass31.cs.ie.u-ryukyu.ac.jp" - -#role :pall00, "mass01.cs.ie.u-ryukyu.ac.jp" -#role :pall00, "mass48.cs.ie.u-ryukyu.ac.jp" - -# max number of cluster is 24 task :mkdir_maven do run "sudo mkdir /usr/local/apache-maven" @@ -70,6 +44,11 @@ run "mkdir /home/mass/.m2" run "cp -r /home/mass/share/student/k128576/m2/repository /home/mass/.m2/" end + +task :killalljava do + run "killall java" +end + task :killjava do run "pkill java" end @@ -102,26 +81,22 @@ run "sleep 0.$RANDOM && export MAVEN_OPTS='-Xmx3g -Xms3g' && /usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/hg/jungle-network/pom.xml exec:java -Dexec.mainClass='app.bbs.DistributeApp' -Dexec.args='-level fatal -host bldsv12.cr.ie.u-ryukyu.ac.jp -port 10000 -p 20000 -bp 8080' " end -task :cp_cassandra do - run "cp -r /home/mass/share/student/k128576/cassandra /home/mass/student/k128576/" +task :cp_cassandra2 do + run "cp -r /home/mass/share/student/k128576/cassandra/apache-cassandra-2.0.4 /home/mass/student/k128576/cassandra" end task :gen_conf do - run "/usr/local/bin/ruby /home/mass/share/student/k128576/cassandra/generate_yaml.rb > /home/mass/student/k128576/cassandra/apache-cassandra-1.2.1/conf/cassandra.yaml" + run "/usr/local/bin/ruby /home/mass/share/student/k128576/cassandra/generate_yaml.rb > /home/mass/student/k128576/cassandra/apache-cassandra-2.0.4/conf/cassandra.yaml" end task :start_cassandra do - run "cd /home/mass/student/k128576/cassandra/ && /home/mass/student/k128576/cassandra/apache-cassandra-1.2.1/bin/cassandra -f" + run "cd /home/mass/student/k128576/cassandra/ && /home/mass/student/k128576/cassandra/apache-cassandra-2.0.4/bin/cassandra -f" end task :rsync_bbs do run "rsync -av /home/mass/share/student/k128576/hg/bulletinboard /home/mass/student/k128576/cassandra/" end -task :rsync_core do - run "rsync -av /home/mass/share/student/k128576/hg/jungle-core /home/mass/student/k128576/hg/" -end - task :clean_bbs do run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml clean" end @@ -130,52 +105,54 @@ run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml compile" end -task :one_cassandra_bbs do +task :install_bbs do + run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml install" +end + +task :rsync_core do + run "rsync -av /home/mass/share/student/k128576/hg/jungle-core /home/mass/student/k128576/hg/" +end + +task :one_bbs do run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml exec:java -Dexec.mainClass='jp.ac.u_ryukyu.ie.cr.shoshi.jungle.bbs.App' -Dexec.args='-one' " end -task :one_bbs4 do - run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml exec:java -Dexec.mainClass='jp.ac.u_ryukyu.ie.cr.shoshi.jungle.bbs.App' -Dexec.args='-one -rep 4' " +task :one_bbs5 do + run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml exec:java -Dexec.mainClass='jp.ac.u_ryukyu.ie.cr.shoshi.jungle.bbs.App' -Dexec.args='-one -rep 5' " end task :one_bbs8 do run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml exec:java -Dexec.mainClass='jp.ac.u_ryukyu.ie.cr.shoshi.jungle.bbs.App' -Dexec.args='-one -rep 8' " end - -task :quorum_cassandra_bbs do +task :quorum_bbs do run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml exec:java -Dexec.mainClass='jp.ac.u_ryukyu.ie.cr.shoshi.jungle.bbs.App' -Dexec.args='-quorum' " end -task :all_cassandra_bbs do +task :quorum_bbs5 do + run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml exec:java -Dexec.mainClass='jp.ac.u_ryukyu.ie.cr.shoshi.jungle.bbs.App' -Dexec.args='-quorum -rep 5' " +end + +task :all_bbs do run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml exec:java -Dexec.mainClass='jp.ac.u_ryukyu.ie.cr.shoshi.jungle.bbs.App' -Dexec.args='-all' " end -task :all_bbs2 do - run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml exec:java -Dexec.mainClass='jp.ac.u_ryukyu.ie.cr.shoshi.jungle.bbs.App' -Dexec.args='-all -rep 2' " -end - -task :all_bbs4 do - run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml exec:java -Dexec.mainClass='jp.ac.u_ryukyu.ie.cr.shoshi.jungle.bbs.App' -Dexec.args='-all -rep 4' " -end - -task :all_bbs8 do - run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml exec:java -Dexec.mainClass='jp.ac.u_ryukyu.ie.cr.shoshi.jungle.bbs.App' -Dexec.args='-all -rep 8' " -end - -task :all_bbs24 do - run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml exec:java -Dexec.mainClass='jp.ac.u_ryukyu.ie.cr.shoshi.jungle.bbs.App' -Dexec.args='-all -rep 23' " +task :all_bbs5 do + run "/usr/local/apache-maven/apache-maven-3.0.5/bin/mvn -f /home/mass/student/k128576/cassandra/bulletinboard/pom.xml exec:java -Dexec.mainClass='jp.ac.u_ryukyu.ie.cr.shoshi.jungle.bbs.App' -Dexec.args='-all -rep 5' " end task :delete_var do run "rm -rf /home/mass/student/k128576/cassandra/var" end -task :cp_var do - run "rm -rf /home/mass/student/k128576/cassandra/var" - run "cp -r /home/mass/student/k128576/cassandra/backup/var /home/mass/student/k128576/cassandra/" +task :kill9bbs do + run "ps aux |grep maven |grep -v grep |awk '{print $2}'| xargs kill -9" end -task :kill_bbs do - run "ps aux |grep bullet |grep -v grep |awk '{print $2}'| xargs kill" + +task :rm_snappy do + run "rm /home/mass/student/k128576/cassandra/apache-cassandra-2.0.4/lib/snappy-java-1.0.5.jar" end +task :cp_snappy do + run "cp /home/mass/share/student/k128576/cassandra/snappy-java-1.0.4.jar /home/mass/student/k128576/cassandra/apache-cassandra-2.0.4/lib/" +end
--- a/distributed/hello_post.rb Thu Jan 23 05:52:31 2014 +0900 +++ b/distributed/hello_post.rb Fri Jan 24 18:09:16 2014 +0900 @@ -4,7 +4,7 @@ require 'uri' require 'benchmark' -#uri = URI.parse('http://mass12.cs.ie.u-ryukyu.ac.jp:8080/createBoard?bname=hello%20world&author=oshiro&key=0&msg=hogehoge') -uri = URI.parse('http://mass48.cs.ie.u-ryukyu.ac.jp:8080/createBoard?bname=hello%20world&author=oshiro&key=0&msg=hogehoge') +url="http://mass48.cs.ie.u-ryukyu.ac.jp:8080/createBoard?bname=hello%20world&author=oshiro&key=0&msg=hogehoge" +uri = URI.parse(url) res = Net::HTTP.post_form(uri, {}) puts res
--- a/distributed/nodes.txt Thu Jan 23 05:52:31 2014 +0900 +++ b/distributed/nodes.txt Fri Jan 24 18:09:16 2014 +0900 @@ -1,46 +1,3 @@ -mass01.cs.ie.u-ryukyu.ac.jp -mass02.cs.ie.u-ryukyu.ac.jp -mass03.cs.ie.u-ryukyu.ac.jp -mass04.cs.ie.u-ryukyu.ac.jp -mass05.cs.ie.u-ryukyu.ac.jp -mass06.cs.ie.u-ryukyu.ac.jp -mass07.cs.ie.u-ryukyu.ac.jp -mass08.cs.ie.u-ryukyu.ac.jp -mass09.cs.ie.u-ryukyu.ac.jp -mass10.cs.ie.u-ryukyu.ac.jp -mass11.cs.ie.u-ryukyu.ac.jp -mass12.cs.ie.u-ryukyu.ac.jp -mass13.cs.ie.u-ryukyu.ac.jp -mass14.cs.ie.u-ryukyu.ac.jp -mass15.cs.ie.u-ryukyu.ac.jp -mass16.cs.ie.u-ryukyu.ac.jp -mass17.cs.ie.u-ryukyu.ac.jp -mass18.cs.ie.u-ryukyu.ac.jp -mass19.cs.ie.u-ryukyu.ac.jp -mass20.cs.ie.u-ryukyu.ac.jp -mass21.cs.ie.u-ryukyu.ac.jp -mass22.cs.ie.u-ryukyu.ac.jp -mass23.cs.ie.u-ryukyu.ac.jp -mass24.cs.ie.u-ryukyu.ac.jp -mass25.cs.ie.u-ryukyu.ac.jp -mass26.cs.ie.u-ryukyu.ac.jp -mass27.cs.ie.u-ryukyu.ac.jp -mass28.cs.ie.u-ryukyu.ac.jp -mass29.cs.ie.u-ryukyu.ac.jp -mass30.cs.ie.u-ryukyu.ac.jp -mass31.cs.ie.u-ryukyu.ac.jp -mass32.cs.ie.u-ryukyu.ac.jp -mass33.cs.ie.u-ryukyu.ac.jp -mass34.cs.ie.u-ryukyu.ac.jp -mass35.cs.ie.u-ryukyu.ac.jp -mass36.cs.ie.u-ryukyu.ac.jp -mass37.cs.ie.u-ryukyu.ac.jp -mass38.cs.ie.u-ryukyu.ac.jp -mass39.cs.ie.u-ryukyu.ac.jp -mass40.cs.ie.u-ryukyu.ac.jp -mass41.cs.ie.u-ryukyu.ac.jp -mass42.cs.ie.u-ryukyu.ac.jp -mass43.cs.ie.u-ryukyu.ac.jp mass44.cs.ie.u-ryukyu.ac.jp mass45.cs.ie.u-ryukyu.ac.jp mass46.cs.ie.u-ryukyu.ac.jp
--- a/distributed/nodes_stress_write_cassandra.rb Thu Jan 23 05:52:31 2014 +0900 +++ b/distributed/nodes_stress_write_cassandra.rb Fri Jan 24 18:09:16 2014 +0900 @@ -13,7 +13,7 @@ sleepTime = schedule - time sleep(sleepTime) -UUID="13814000-1dd2-11b2-af85-0050568b0070" +UUID="13814000-1dd2-11b2-99d5-0050568b0070" nodeList = get_node_list("/home/mass/share/student/k128576/jungle_benchmark/distributed/nodes.txt") urlList = get_url_list(nodeList, ':8080/editMessage?bname=hello%20world&uuid='+UUID);