简体   繁体   中英

How to check Elasticsearch logs in Amazon Elasticsearch Service?

I am trying to sync my data from MongoDB in to Amazon Elasticsearch Service using mongoosastic For some reason, sync is not happening as expected.

I do not see any error from the mongoosastic plugin. Not sure what is failing in AWS Elasticsearch service

Is there any way to get Elasticsearch logs in Amazon Elasticsearch Service?

elasticsearch = require('elasticsearch');

this.es_connection = new elasticsearch.Client("Amazon Elasticsearch Service address");
return this.es_connection.ping({
  requestTimeout: 30000,
  hello: 'elasticsearch'
}, function(error) {
  if (error) {
    console.error('elasticsearch cluster is down!' + JSON.stringify(error));
  } else {
    logger.info('All is well in elasticsearch');
  }
});

In order to troubleshoot AWS elasticsearch service, you'll need to configure the log shipping to CloudWatch: https://aws.amazon.com/blogs/big-data/viewing-amazon-elasticsearch-service-error-logs/

Then you will be able to use CloudWatch console in order to view your logs and understand if the issue is in Elasticsearch or is it mongoosastic issue / mapping/ index failures issues.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM