mirror of
https://github.com/krislamo/graylog_demo
synced 2025-10-23 13:28:33 +00:00
Route the syslog through fluentd via UDP
This commit is contained in:
8
Vagrantfile
vendored
8
Vagrantfile
vendored
@@ -38,13 +38,9 @@ Vagrant.configure("2") do |config|
|
||||
systemctl start rsyslog
|
||||
systemctl -q enable rsyslog
|
||||
|
||||
# Enable TCP syslog reception
|
||||
sed -i 's/#\$ModLoad imtcp/\$ModLoad imtcp/g' /etc/rsyslog.conf
|
||||
sed -i 's/#\$InputTCPServerRun 514/\$InputTCPServerRun 514/g' /etc/rsyslog.conf
|
||||
|
||||
# Add rsyslog forwarding option if it does not exist
|
||||
if ! grep -q "#{PRIVATE_NET_IP}:1514" /etc/rsyslog.conf; then
|
||||
echo "*.* @@#{PRIVATE_NET_IP}:1514;RSYSLOG_SyslogProtocol23Format" >> /etc/rsyslog.conf
|
||||
if ! grep -q "127.0.0.1:5140" /etc/rsyslog.conf; then
|
||||
echo "*.* @127.0.0.1:5140" >> /etc/rsyslog.conf
|
||||
systemctl restart rsyslog
|
||||
fi
|
||||
|
||||
|
Reference in New Issue
Block a user