1

I have an Ubuntu 18.04 system installed on a Digital Ocean server. I have installed the Magento 2.3.1 version. I have installed Java and Elasticsearch using the following commands:

JAVA

sudo add-apt-repository -y ppa:webupd8team/java
sudo apt-get -y update
sudo apt-get install -y oracle-java8-installer

ELASTICSEARCH

wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | sudo apt-key add -
echo "deb https://artifacts.elastic.co/packages/6.x/apt stable main" | sudo tee -a /etc/apt/sources.list.d/elastic-6.x.list
sudo apt update
sudo apt install elasticsearch
Edit this file: /etc/elasticsearch/elasticsearch.yml and add this info: network.host: localhost
sudo systemctl daemon-reload
sudo systemctl start elasticsearch
sudo systemctl enable elasticsearch

If I execute this command:

curl -XGET -H "Content-Type: application/json" http://localhost:9200/_cluster/health?pretty=true

This is the result:

{
"cluster_name" : "elasticsearch",
"status" : "yellow",
"timed_out" : false,
"number_of_nodes" : 1,
"number_of_data_nodes" : 1,
"active_primary_shards" : 20,
"active_shards" : 20,
"relocating_shards" : 0,
"initializing_shards" : 0,
"unassigned_shards" : 20,
"delayed_unassigned_shards" : 0,
"number_of_pending_tasks" : 0,
"number_of_in_flight_fetch" : 0,
"task_max_waiting_in_queue_millis" : 0,
"active_shards_percent_as_number" : 50.0
}

The status is yellow and unassigned_shards is 20. How can I solve this problem? Please could you help me?

1 Answer 1

1

Yellow status is due to Shard replication, so you need to create duplicates. There are various guides on how to set this up. Note that a yellow status doesnt mean that it wont work as it should, it basically means you dont have any backups

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.