The error I get is: Exiting: couldn't connect to any of the configured Elasticsearch hosts. Errors: [error connecting to Elasticsearch at https://192.168.200.169:9200: Get "https://192.168.200.169:9200": x509: certificate is valid for 192.168.200.169, not 192.168.200.169]
My elastic machine is with running on 192.168.200.169. I tried adding the hostname in windows hosts file, generating different types of certs but still get the same error.
On windows server 2016+ it is working without any kind of problem.
I suspect the issue is that your certificate does not contain an IP Subject Alternative Name field. I think when you connect via an IP the server cert must have a SAN value for that IP.
to look at the server's response and certs. Then check the returned leaf cert with openssl x509 -text -noout to verify the presence of "IP Address" in X509v3 Subject Alternative Name:. Like
X509v3 Subject Alternative Name:
DNS:localhost, DNS:xx.consul, DNS:xy.consul, DNS:xyz, IP Address:127.0.0.1, IP Address:10.3.12.34
The DNS is correct, as well as the IP addresses, I tried experimenting with the values and got to the point where it displays NO error message but still do not send any information what so ever.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.