You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@whirr.apache.org by to...@apache.org on 2012/09/20 22:45:40 UTC
git commit: WHIRR-649. Make install_cdh_hadoop.sh idempotent,
fast failing if already run. Contributed by Graham Gear.
Updated Branches:
refs/heads/trunk 7bd831d65 -> a67be676c
WHIRR-649. Make install_cdh_hadoop.sh idempotent, fast failing if already run. Contributed by Graham Gear.
Project: http://git-wip-us.apache.org/repos/asf/whirr/repo
Commit: http://git-wip-us.apache.org/repos/asf/whirr/commit/a67be676
Tree: http://git-wip-us.apache.org/repos/asf/whirr/tree/a67be676
Diff: http://git-wip-us.apache.org/repos/asf/whirr/diff/a67be676
Branch: refs/heads/trunk
Commit: a67be676ca670e12bd54b9e6a479e0056c9fa8b1
Parents: 7bd831d
Author: Tom White <to...@apache.org>
Authored: Thu Sep 20 21:45:02 2012 +0100
Committer: Tom White <to...@apache.org>
Committed: Thu Sep 20 21:45:02 2012 +0100
----------------------------------------------------------------------
CHANGES.txt | 3 +++
.../main/resources/functions/install_cdh_hadoop.sh | 5 +++++
2 files changed, 8 insertions(+), 0 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/whirr/blob/a67be676/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 447e8e9..e836495 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -10,6 +10,9 @@ Release 0.8.1 (unreleased changes)
WHIRR-548. Whirr can now reuse existing compute services.
Misc osgi/karaf integration improvements. (Ioannis Canellos)
+
+ WHIRR-649. Make install_cdh_hadoop.sh idempotent, fast failing if already
+ run. (Graham Gear via tomwhite)
BUG FIXES
http://git-wip-us.apache.org/repos/asf/whirr/blob/a67be676/services/cdh/src/main/resources/functions/install_cdh_hadoop.sh
----------------------------------------------------------------------
diff --git a/services/cdh/src/main/resources/functions/install_cdh_hadoop.sh b/services/cdh/src/main/resources/functions/install_cdh_hadoop.sh
index 0ccae85..ef666b4 100644
--- a/services/cdh/src/main/resources/functions/install_cdh_hadoop.sh
+++ b/services/cdh/src/main/resources/functions/install_cdh_hadoop.sh
@@ -60,6 +60,11 @@ function install_cdh_hadoop() {
local OPTIND
local OPTARG
+ if [ "$INSTALL_HADOOP_DONE" == "1" ]; then
+ echo "Hadoop is already installed."
+ return;
+ fi
+
REPO=${REPO:-cdh4}
REPO_HOST=${REPO_HOST:-archive.cloudera.com}
MAPREDUCE_VERSION=${MAPREDUCE_VERSION:-1}