Hi,
when i was typing
metricbeat setup
then this error appear
[root@localhost share]# metricbeat setup
Index setup complete.
Loading dashboards (Kibana must be running and reachable)
Exiting: error connecting to Kibana: fail to get the Kibana version: HTTP GET request to https://192.168.0.85:5601/api/status fails: fail to execute the HTTP GET request: Get https://192.168.0.85:5601/api/status: x509: certificate signed by unknown authority. Response:
but when in my web - https://192.168.0.85:5601/api/status
it can be get kibana version
{"name":"Kibana","uuid":"c1580b77-f439-4b99-9e11-8f4662b03747","version":{"number":"7.1.0","build_hash":"7bdb99203c3b0d113668b9a96b1daaa920d654a2","build_number":23222,"build_snapshot":false},"status":{"overall":{"state":"green","title":"Green","nickname":"Looking good","icon":"success","uiColor":"secondary","since":"2019-06-05T07:37:17.662Z"},"statuses":[{"id":"plugin:kibana@undefined","state":"green","icon":"success","message":"Ready","uiColor":"secondary","since":"2019-06-05T07:37:17.662Z"} ~~~~~~~~~~~~~~~~{"number_of_elapsed_periods":0,"number_of_times_throttled":0,"time_throttled_nanos":0}}}},"response_times":{"avg_in_millis":173.875,"max_in_millis":1165},"requests":{"disconnects":0,"statusCodes":{},"total":7,"status_codes":{"200":4,"304":4}},"concurrent_connections":0}}
This is my metricbeat.yml
#==================== Elasticsearch template setting ==========================
setup.template.name : "metricbeat"
setup.template.pattern: "metricbeat-*"setup.template.settings:
index.number_of_shards: 1
index.codec: best_compression
#_source.enabled: false#============================== Kibana =====================================
#Starting with Beats version 6.0.0, the dashboards are loaded via the Kibana API.
#This requires a Kibana endpoint configuration.
setup.kibana:kibana Host
#Scheme and port can be left out and will be set to the default (http and 5601)
#In case you specify and additional path, the scheme is required: http://localhost:5601/path
#IPv6 addresses should always be defined as: https://[2001:db8::1]:5601
host: "https://192.168.0.85:5601"
ssl.certificate: /etc/pki/root/server2.crt
ssl.key: /etc/pki/root/server.key
ssl.certificateAuthorities: /etc/pki/root/server.cakey.pem
#ssl.vertification_mode: none#-------------------------- Elasticsearch output ------------------------------
output.elasticsearch:
#Array of hosts to connect to.
hosts: ["https://192.168.0.85:9200"]#Optional protocol and basic auth credentials.
protocol: "https"
username: "elastic"
password: "d8Z46pgoFEd1rQNdOfDX"
index: "metricbeat-%{[agent.version]}"
ssl.certificate_authorities: "/etc/pki/root/root.crt"
ssl.certificate: "/etc/pki/root/client2.crt"
ssl.key: "/etc/pki/root/client.key"
#ssl.key_passphrase: "qlalfqjsgh12!"
ssl.verification_mode: "none"#================================= Setup ILM ==================================
#The index lifecycle write alias name.
#The default is metricbeat-{agent.version}.
#Setting this option changes the prefix in the alias name.
#It doesn’t remove agent.version from the alias name.
#setup.ilm.rollover_alias: "metricbeat"#The rollover index pattern. The default is %{now/d}-000001
setup.ilm.pattern: "0000001"
this is my kibana.yml
elasticsearch.username: "kibana"
elasticsearch.password: "Y3B2c5U0izQF2Who2qyj"server.ssl.certificate: /etc/kibana/server2.crt
server.ssl.key: /etc/kibana/server.key
server.ssl.certificateAuthorities: /etc/kibana/ES/server.cakey.pemelasticsearch.ssl.certificate: /etc/kibana/ES/client2.crt
elasticsearch.ssl.key: /etc/kibana/ES/client.keyelasticsearch.ssl.certificateAuthorities: /etc/kibana/ES/root.crt
elasticsearch.ssl.verificationMode: none
Help me please.
Thanks.