首次安装时,将start-local\elastic-start-local\docker-compose.yml 文件中的 xpack.license.self_generated.type=trial 调整为xpack.license.self_generated.type=basic
environment:
- discovery.type=single-node
- ELASTIC_PASSWORD=${ES_LOCAL_PASSWORD}
- xpack.security.enabled=true
- xpack.security.http.ssl.enabled=false
- xpack.license.self_generated.type=basic # 修改 trial
- xpack.ml.use_auto_machine_memory_percent=true
- ES_JAVA_OPTS=-Xms${ES_LOCAL_HEAP_INIT} -Xmx${ES_LOCAL_HEAP_MAX}
- cluster.routing.allocation.disk.watermark.low=${ES_LOCAL_DISK_SPACE_REQUIRED}
- cluster.routing.allocation.disk.watermark.high=${ES_LOCAL_DISK_SPACE_REQUIRED}
- cluster.routing.allocation.disk.watermark.flood_stage=${ES_LOCAL_DISK_SPACE_REQUIRED}
也可以在 运行start-local.sh文件运行产生docker-compose.yml 前,在start-local.sh文件里找到该配置项,修改为:xpack.license.self_generated.type=basic,然后在运行start-local.sh脚本,这样生成的docker-compose.yml就是预期效果