You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

如何配置无安全验证的APM Server对接Elasticsearch 8.6+测试环境

解决无安全验证Elasticsearch对接APM Server的索引模板缺失问题

一、确认Elasticsearch的安全禁用配置

确保elasticsearch.yml中已完全禁用X-Pack安全相关模块,修改后重启ES:

xpack.security.enabled: false
xpack.security.enrollment.enabled: false
xpack.security.http.ssl.enabled: false
xpack.security.transport.ssl.enabled: false
network.host: 0.0.0.0
http.port: 9200

二、配置APM Server对接无安全验证的ES

编辑apm-server.yml,更新以下核心配置:

# 禁用APM Server自身的身份验证(测试环境专用)
apm-server.auth.enabled: false

# 配置Elasticsearch输出目标
output.elasticsearch:
  hosts: ["http://localhost:9200"] # 替换为你的ES实际地址
  ssl.enabled: false
  # 清空身份验证参数(ES无安全验证)
  username: ""
  password: ""

# 开启索引模板自动创建,禁用索引生命周期管理(ILM依赖X-Pack组件)
setup.template.enabled: true
setup.template.overwrite: true
setup.ilm.enabled: false

三、预创建APM所需索引模板

启动APM Server前,先执行setup命令触发索引模板创建(解决logs-apm.error模板缺失问题):

apm-server setup --index-management

四、启动并验证配置

启动APM Server后,检查日志确认无resource_not_found_exception报错,再通过以下命令验证运行状态:

curl http://localhost:8200/

返回结果中"publish_ready": true即表示配置成功。

内容的提问来源于stack exchange,提问作者PatPanda

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.08.02 03:01:02