一、elasticsearch.yml 配置
http.cors.enabled: true
http.cors.allow-origin: “*”
http.cors.allow-headers: Authorization,X-Requested-With,Content-Type,Content-Length
es-head连接方式
在web界面访问时,该框由原来的 http://172.16.3.227:9100替换为 http://172.16.3.227:9100/?auth_user=elastic&auth_password=123456
![在这里插入图片描述](https://img-blog.csdnimg.cn/20210318172251391.png?x-oss-process=image/watermark,type_ZmFuZ3poZW5naGVpdGk,shadow_10,text_aHR0cHM6Ly9ibG9nLmNzZG4ubmV0L3FxXzQzMTY0NTcx,size_16,color_FFFFFF,t_70)