logging - 如何将系统日志发送到graylog

标签 logging centos send syslog graylog

我们有很多 Centos 客户端(Centos 5-7)。我希望所有客户端都通过 syslog 将日志发送到 graylog 服务器。这适用于安装了 rsyslog 的客户端。但是老客户没有rsyslog。他们使用系统日志。

我应该在 /etc/syslog.conf 文件中更改什么才能使其正常工作? 感谢您的帮助。

最佳答案

为其他客户端使用 graylog-collector :

我对 graylog-collector 的配置:

server-url = "http://192.168.254.184:12900/"

inputs {
  win-eventlog-application {
    type = "windows-eventlog"
    source-name = "Application"
    poll-interval = "1s"
  }
  win-eventlog-system {
    type = "windows-eventlog"
    source-name = "System"
    poll-interval = "1s"
  }
  win-eventlog-security {
    type = "windows-eventlog"
    source-name = "Security"
    poll-interval = "1s"
  }
}

outputs {
  gelf-tcp {
    type = "gelf"
    host = "192.168.254.184"
    port = 12201
  }
}

只需在 graylog2 界面中为 GELF 格式创建一个输入即可!

关于logging - 如何将系统日志发送到graylog,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34911505/

相关文章:

python - 在多个主机上通过 Ansible 运行 yum update 不工作

Linux chcon : can't apply partial context to unlabeled file

linux - 如何将 acl 备份到文件然后将其应用到另一个文件夹?

ruby-on-rails - Rails 自定义弃用通知

logging - 使用 slf4j(和 io.symphonia :lambda-logging) in AWS Lambas)登录时,CloudWatch 输出中出现新行问题

c++ - 如何使用 C++ (curl) 发送电子邮件

android - 有没有办法拦截发送到不同传输的Android SMS?

html - 通过 Skype4com 发送 html 消息

logging - 将heroku日志发送到s3

grails - 为什么我的TRACE会收到groovy.lang.MissingPropertyException?