After installing x-pack on ELK, Logstash not create index to elasticsearch

You need to set credentials so that the Elasticsearch output plugin of Logstash can authenticate to Elasticsearch. I shared the link to the documentation for that above