eschweit-at-tibco / tci-elk-logging

Files for use with ELK to dump TCI logs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

tci-elk-logging

Contents

This is a small contribution aimed at getting you started more quickly when about to dump TCI (TIBCO Cloud Integration) log files into ELK (Elasticsearch Logstash, and Kibana)

You'll find the two necessary files:

  • tci-log.conf: the configuration file for logstash,
  • patterns/tci-grok-patterns: the patterns file for logstash's grok filter.

This extracts a number of properties from the logs, which will be dropped in Elasticsearch, that you can use in Kibana to discover you data and visualise it:

  • errlvl the error level ERROR, DEBUG, WARN, or INFO,
  • tcipt the process and thread information
as well as the following ones for BusinessWorks applications:
  • tcijobid the job ID,
  • tcipiid the process ID,
  • tcippiid the parent process ID (if this is about a subprocess),
  • tciactivity the activity name,
  • tciprocess the process name,
  • tcimod the module name,
  • tciapp the application name.

Running the ELK stack

There are many options when it comes to running the ELK stack you'll dump those contents to, included running it directly from GCP (Hosted on GCP, offered by Elasticsearch) or AWS (Amazon Elasticsearch Service). I tried Bitnami's ELK image for Amazon EC2 and would recommend it: it is well documented, leaves access to server via ssh, and leaves a lot of flexibility when it comes to configuration, including installing TCI's tibcli. You get all the documentation on Bitnami's website.

Configuring Logstash and streaming the logs

Should you happen to use Bitnami's image, here is what to do with the two files:

  • cp tci-log.conf /opt/bitnami/logstash/conf
  • mkdir /opt/bitnami/logstash/patterns
  • cp patterns/tci-grok-patterns /opt/bitnami/logstash/patterns

And here is how you would start logstash (making sure you are logged in TCI with tibcli): ./tibcli monitor applog -s <your application's name> | sudo /opt/bitnami/logstash/bin/logstash -f /opt/bitnami/logstash/conf/tci.conf

Built With

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

License

This project is licensed under the MIT License - see the LICENSE.md file for details.

Acknowledgements

  • Philippe Gabert

About

Files for use with ELK to dump TCI logs

License:MIT License