ユーザ用ツール

サイト用ツール


serverapps:fluentd

差分

このページの2つのバージョン間の差分を表示します。

この比較画面へのリンク

次のリビジョン
前のリビジョン
次のリビジョン両方とも次のリビジョン
serverapps:fluentd [2017/04/26 03:15] – 作成 hayashiserverapps:fluentd [2019/11/06 06:48] – [tagにホスト名を入れる] hayashi
行 1: 行 1:
 ====== Fluentd ====== ====== Fluentd ======
 +===== tagにホスト名を入れる =====
 +e.g.
  
-===== 見出し =====+<code> 
 +<source> 
 +  @type tail 
 +  path /var/log/messages 
 +  tag "td.log.messages.#{Socket.gethostname}" 
 +  pos_file /var/log/messages.td.pos 
 +  format syslog 
 +</source> 
 +</code> 
 + 
 +  - record_transformer filter pluginを使う 
 +===== Log受信に失敗する =====
  
   error_class=MessagePack::MalformedFormatError error="invalid byte" tag="WebM04/dms.ssl_member_error_log"   error_class=MessagePack::MalformedFormatError error="invalid byte" tag="WebM04/dms.ssl_member_error_log"
行 7: 行 20:
 ”Specify time_as_integer true in your configuration of out_forward in v0.14. ”Specify time_as_integer true in your configuration of out_forward in v0.14.
 See "Sub-second time": http://www.fluentd.org/blog/fluentd-v0.14.0-has-been-released” See "Sub-second time": http://www.fluentd.org/blog/fluentd-v0.14.0-has-been-released”
 +
 +要約:適当
 +
 +v0.12までは秒単位であったLogの時間分解能がv0.14からnano秒となりました。\\
 +このため、Fluentd v0.14から転送されたナノ秒の分解能を含むバイナリデータの受信にFluentd v0.12は失敗します。\\
 +Fluentd v0.14からFluent v0.12にデータを転送する場合、forward出力プラグインの設定でtime_as_integer true指定します。
 +
 +
 +===== 参考 =====
 +
 +[[https://www.fluentd.org/guides/recipes/apache-add-hostname|Adding Hostname to Event Logs (Apache httpd Example)]]
 +
serverapps/fluentd.txt · 最終更新: 2020/09/24 03:03 by hayashi