Skip to content

Instantly share code, notes, and snippets.

@bxb100
Last active May 23, 2022 14:18
Show Gist options
  • Save bxb100/02e22b8b2d3e1d6384b9524efde0800b to your computer and use it in GitHub Desktop.
Save bxb100/02e22b8b2d3e1d6384b9524efde0800b to your computer and use it in GitHub Desktop.
记一次 windows docker 安装 ES 8.x 问题汇总

max_map_count 过小无法启动

  • 使用 .wslconfig 来控制 wsl 的内存大小1
  • 然后 wsl --shutdown 使其生效
  • 进入 wsl 容器后调整 vm.max_map_count=262144, 详细命令是 sudo sysctl -w vm.max_map_count=262144 注意不要 sudo vim 那是没用的.2

8.x 默认 ssl

  • Docker 中使用 cp 复制 /usr/share/elasticsearch/config/certs/http_ca.crt 然后移入受信任的根证书颁发机构3

Footnotes

  1. https://docs.microsoft.com/en-us/windows/wsl/wsl-config#configure-global-options-with-wslconfig

  2. https://www.elastic.co/guide/en/elasticsearch/reference/8.0/docker.html#_windows_with_docker_desktop_wsl_2_backend

  3. https://github.com/cars10/elasticvue/wiki/Access-clusters-using-SSL

@bxb100
Copy link
Author

bxb100 commented May 23, 2022

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment