Skip to content

Commit

Permalink
Copy final cluster xml file to output dir
Browse files Browse the repository at this point in the history
When the final cluster.xml is generated it is placed in
outputdir/step3 folder. Copy it to outputdir as well.
  • Loading branch information
voldemort authored and jayjwylie committed Jun 20, 2013
1 parent f9936c1 commit 1807fae
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
9 changes: 6 additions & 3 deletions rebalance-new-cluster.sh
Expand Up @@ -15,9 +15,9 @@
# See the License for the specific language governing permissions and
# limitations under the License.

# This script generates a final cluster.xml for spinning up a new cluster.
# This script generates a final-cluster.xml for spinning up a new cluster.
# Argument = -v vold_home -c current_cluster -s current_stores -o output dir
# The final cluster is placed in output_dir/step3
# The final cluster is placed in output_dir/

# This script uses getopts which means only single character switches are allowed.
# Using getopt would allow for multi charcter switch names but would come at a
Expand All @@ -41,7 +41,7 @@ EOF
exit 1
}

# initiliaze varibles to an empty string
# initialize varibles to an empty string
vold_home=""
current_cluster=""
current_stores=""
Expand Down Expand Up @@ -146,3 +146,6 @@ $vold_home/bin/run-class.sh voldemort.tools.RepartitionerCLI \
--attempts 4 \
--output-dir $output_dir/step3/ \

echo "[rebalance-new-cluster] Placing final-cluster.xml in '$output_dir'"
cp $output_dir/step3/final-cluster.xml $output_dir/final-cluster.xml

5 changes: 4 additions & 1 deletion rebalance-zone-expansion.sh
Expand Up @@ -19,7 +19,8 @@
# Using getopt would allow for multi charcter switch names but would come at a
# cost of not being cross compatibility.

# This script generates a cluster.xml and a plan for the zone expansion
# This script generates a cluster.xml and a plan for the zone expansion.
# The final cluster is placed in output_dir/
# Argument = -v vold_home -c current_cluster -s current_stores -i interim_cluster -f final_stores
# -o output dir

Expand Down Expand Up @@ -172,4 +173,6 @@ $vold_home/bin/run-class.sh voldemort.tools.RebalancePlanCLI \
--final-stores $final_stores \
--output-dir $output_dir/step3/ | tee $output_dir/step3/plan.txt

echo "[rebalance-new-cluster] Placing final-cluster.xml in '$output_dir'"
cp $output_dir/step3/final-cluster.xml $output_dir/final-cluster.xml

0 comments on commit 1807fae

Please sign in to comment.