fix elasticsearch instance startup issue

master
Yik Teng Hie 4 years ago
parent 776751b944
commit ada5007a8e

@ -1,7 +1,5 @@
# Setup Elasticsearch
- For single node setup
- [Reference](https://www.elastic.co/guide/en/kibana/8.2/docker.html)
```shell
@ -35,3 +33,17 @@ $ docker-compose down
# Remove all volume and network
$ docker-compose down -v
```
## Fixes
- [Virtual Memory Issue] (https://www.elastic.co/guide/en/elasticsearch/reference/current/vm-max-map-count.html)
```shell
# use --ulimit nofile=65536:65536 to fix issue#1
$ docker run --ulimit nofile=65536:65536 -p 5601:5601 -p 9200:9200 -p 5044:5044 -it --name elk sebp/elk
# Temporary fix virtual memory issue
$ sysctl -w vm.max_map_count=262144
```

@ -94,6 +94,9 @@ services:
- xpack.license.self_generated.type=${LICENSE}
mem_limit: ${MEM_LIMIT}
ulimits:
nofile:
soft: 65536
hard: 65536
memlock:
soft: -1
hard: -1
@ -134,6 +137,9 @@ services:
- xpack.license.self_generated.type=${LICENSE}
mem_limit: ${MEM_LIMIT}
ulimits:
nofile:
soft: 65536
hard: 65536
memlock:
soft: -1
hard: -1
@ -174,6 +180,9 @@ services:
- xpack.license.self_generated.type=${LICENSE}
mem_limit: ${MEM_LIMIT}
ulimits:
nofile:
soft: 65536
hard: 65536
memlock:
soft: -1
hard: -1

Loading…
Cancel
Save