blacktop / docker-elastic-stack

ELK Stack Dockerfile
MIT License
190 stars 75 forks source link

elasticsearch exit accidentally #5

Closed yafngzh closed 7 years ago

yafngzh commented 7 years ago

env: ubuntu 16.04 with vmware

the command was this sudo docker run -p 80:80 -p 9200:9200 blacktop/elastic-stack:5.1

the result was: image

and the kibana ui turned out: image

Could you help me to find out the cause?

blacktop commented 7 years ago

Can you try doing this before you start elastc-stack -

echo "vm.max_map_count=262144" | sudo tee -a /etc/sysctl.conf
sudo sysctl -w vm.max_map_count=262144
yafngzh commented 7 years ago

This was already set. image

blacktop commented 7 years ago

Can you try:

$ sudo docker run -d --name elstack -p 80:80 -p 9200:9200 blacktop/elastic-stack:5.1
$ sudo docker exec elstack head -n30 /var/log/elasticsearch.stdout.log
yafngzh commented 7 years ago

yafngzh@ubuntu:~$ docker exec elstack_A head -n30 /var/log/elasticsearch.stdout.log

# There is insufficient memory for the Java Runtime Environment to continue.
# Native memory allocation (mmap) failed to map 1798569984 bytes for committing reserved memory.
# An error report file with more information is saved as:
# /tmp/hs_err_pid24.log
#
# There is insufficient memory for the Java Runtime Environment to continue.
# Native memory allocation (mmap) failed to map 1798569984 bytes for committing reserved memory.
# An error report file with more information is saved as:
# /tmp/hs_err_pid59.log
#
# There is insufficient memory for the Java Runtime Environment to continue.
# Native memory allocation (mmap) failed to map 1798569984 bytes for committing reserved memory.
# An error report file with more information is saved as:
# /tmp/hs_err_pid91.log
#
# There is insufficient memory for the Java Runtime Environment to continue.
# Native memory allocation (mmap) failed to map 1798569984 bytes for committing reserved memory.
# An error report file with more information is saved as:
# /tmp/hs_err_pid154.log

The reason seems to be not sufficient memory. And it works well after I resize the memory of the VM. Thanks!