# fluentd-bit 설치

curl https://raw.githubusercontent.com/fluent/fluent-bit/master/install.sh | sh

curl https://packages.fluentbit.io/fluentbit.key | gpg --dearmor > /usr/share/keyrings/fluentbit-keyring.gpg


# fluent bit 실행테스트
/opt/fluent-bit/bin/fluent-bit -c /etc/fluent-bit/fluent-bit.conf



# gameLog* 로그를 input 으로
# parser 는 test_parser 사용 parsers.conf 에 정의
[INPUT]
    name tail
    path /root/test_dev1/logs/gameLog*.log
    parser test_parser
    tag testlog

# 태그 재설정
# name 값을 tag 뒤에 붙임
[FILTER]
    Name rewrite_tag
    Match testlog
    Rule $name ^[a-zA-Z]+$ $TAG.$name false
    Emitter_name re_emitted

# 기본 stdout
[OUTPUT]
    name  stdout
    match *

# fluentd 로 쏴주자
[OUTPUT]
    name forward
    match *
    host 10.10.10.35
    port 24224





Posted by 이그제민
l