Tech Tips

  1. Uncategorized
  2. 373 view

Install fluentd and try to use it on ubuntu 12.04LTS

fluentd

Target

Install fluentd and try to make it output what is echo output.

Install Fluentd

$ sudo apt-add-repository 'deb http://packages.treasure-data.com/debian/ lucid contrib'
$ sudo apt-get update
$ sudo apt-get install td-agent
$/usr/lib/fluent/ruby/bin/fluentd --version
fluentd 0.10.39

Config File Setting

$ sudo mkdir /etc/td-agent/conf
$ sudo vim /etc/td-agent/conf/test.conf
# Standard Input
<source>
  type forward
</source>
# Output File
<match debug.**>
  type file
  path /var/log/td-agent/debug
</match>

Start Script Setting

="/usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/"
  3 ENV["GEM_PATH"]="/usr/lib/fluent/ruby/lib/ruby/gems/1.9.1/"

<  4 ENV["FLUENT_CONF"]="/etc/td-agent/td-agent.conf"
---
>  4 ENV["FLUENT_CONF"]="/etc/td-agent/conf/test.conf"

  5 ENV["FLUENT_PLUGIN"]="/etc/td-agent/plugin"
  6 ENV["FLUENT_SOCKET"]="/var/run/td-agent/td-agent.sock"
  7 load "/usr/lib/fluent/ruby/bin/fluentd"

Start

$ sudo /etc/init.d/td-agent restart
$ echo '{"test":"message"}' | fluent-cat debug.test
$ cat /var/log/td-agent/debug.20131006.b4e80c93fc8c29d46
2013-10-06T06:23:46+00:00	debug.test	{"test":"message"}

Uncategorized recent post

  1. Run Amazon FreeRTOS on M5Stack Core2 for AWS …

  2. Udacity Self-Driving Car Engineer Nanodegree …

  3. Install sbt 1.0.0 and run sample template

  4. Visualization of Neural Network and its Train…

  5. [Machine Learning]Created docker image includ…

関連記事

PAGE TOP