Skip to content

Commit

Permalink
bug 1462277. set max local storage
Browse files Browse the repository at this point in the history
  • Loading branch information
jcantrill committed Jun 20, 2017
1 parent 84a5c99 commit 5211196
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
1 change: 1 addition & 0 deletions deployer/conf/elasticsearch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ index:
node:
master: true
data: true
max_local_storage_nodes: 1

network:
host: 0.0.0.0
Expand Down
14 changes: 14 additions & 0 deletions deployer/scripts/upgrade.sh
Original file line number Diff line number Diff line change
Expand Up @@ -670,6 +670,18 @@ function update_es_for_235() {
done
}

#https://bugzilla.redhat.com/show_bug.cgi?id=1462277
function update_es_max_local_storage() {
if oc get configmap logging-elasticsearch -o yaml | grep -q max_local_storage_nodes > /dev/null ; then
return 0
fi

oc get configmap logging-elasticsearch -o yaml | \
sed -e '/^ elasticsearch.yml: /a\
data: true' -e '/^ elasticsearch.yml: /a\
data: true\n max_local_storage_nodes: 1' | oc replace -f -
}

# https://bugzilla.redhat.com/show_bug.cgi?id=1439554
function update_es_for_min_masters() {
echo "Fixing MIN_MASTERS in elasticsearch.yaml conf"
Expand Down Expand Up @@ -983,6 +995,8 @@ function upgrade_logging() {
fi
done

update_es_max_local_storage

scaleUp

if [[ $installedVersion -ne $LOGGING_VERSION ]]; then
Expand Down

0 comments on commit 5211196

Please sign in to comment.