Skip to content

Instantly share code, notes, and snippets.

@fduran
Created February 20, 2012 18:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fduran/1870549 to your computer and use it in GitHub Desktop.
Save fduran/1870549 to your computer and use it in GitHub Desktop.
Linux remote syslog
www.fduran.com
Remote syslogging in Linux
1. On logging server 'logserver':
# nano /etc/rsyslog.conf
uncomment:
# provides UDP syslog reception
$ModLoad imudp
$UDPServerRun 514
2. On sending server:
# nc -w0 -u logserver 514 <<< "<14>FDV User Info msg from remote"
You can use 'logger' to save locally too
codes:
<13> User.Notice
<14> User.Info
see http://linux.byexamples.com/archives/412/syslog-sending-log-from-remote-servers-to-syslog-daemon/
Check on log server:
# tail /var/log/messages
...
FDV User Info msg from remote
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment