From 509f0cf2d1d2b144402f60225b07a7473f0d1c44 Mon Sep 17 00:00:00 2001 From: Tsvetomir Hristov Date: Fri, 11 Oct 2024 11:43:15 +0200 Subject: [PATCH] Maybe it's not smart to try to determine the health of the cluster, before starting the cluster --- install/elasticsearch-install.sh | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/install/elasticsearch-install.sh b/install/elasticsearch-install.sh index ff4908e2..850b9bab 100644 --- a/install/elasticsearch-install.sh +++ b/install/elasticsearch-install.sh @@ -34,13 +34,6 @@ $STD apt-get update $STD apt-get install elasticsearch msg_ok "Installed Elastcisearch" -msg_info "Configuring User" -ELASTIC_USER=elastic -ELASTIC_PASSWORD=$(/usr/share/elasticsearch/bin/elasticsearch-reset-password -sbf -u $ELASTIC_USER) -KIBANA_TOKEN=$(/usr/share/elasticsearch/bin/elasticsearch-create-enrollment-token -s kibana) -ENROLLMENT_TOKEN=$(/usr/share/elasticsearch/bin/elasticsearch-create-enrollment-token -s node) -msg_ok "Installed Elastcisearch" - msg_info "Configuring Elasticsearch Memory" $STD sed -i -E 's/## -Xms[0-9]+[Ggm]/-Xms3g/' /etc/elasticsearch/jvm.options $STD sed -i -E 's/## -Xmx[0-9]+[Ggm]/-Xmx3g/' /etc/elasticsearch/jvm.options @@ -52,6 +45,13 @@ $STD /bin/systemctl enable elasticsearch.service $STD /bin/systemctl start elasticsearch.service msg_ok "Created Service" +msg_info "Configuring User" +ELASTIC_USER=elastic +ELASTIC_PASSWORD=$(/usr/share/elasticsearch/bin/elasticsearch-reset-password -sbf -u $ELASTIC_USER) +KIBANA_TOKEN=$(/usr/share/elasticsearch/bin/elasticsearch-create-enrollment-token -s kibana) +ENROLLMENT_TOKEN=$(/usr/share/elasticsearch/bin/elasticsearch-create-enrollment-token -s node) +msg_ok "Configured User" + msg_info "Checking Health" ELASTIC_PORT=9200 echo "User: $ELASTIC_USER"