How to send the same log event to different/multiple destinations in Red Hat Enterprise Linux 6
Environment
- Red Hat Enterprise Linux 6 (All Minor Versions)
rsyslog
Issue
- How can I specify multiple destinations for the same log event or message category?
- Need to send same log event to
/var/log/messageand/or different remote systems.
Resolution
- Modify file
/etc/rsyslog.confand define multiple destinations as below:
local6.* @@remoteserver:514
local6.* /var/log/messages
Note:- Here local6.* is event which need to send at two different destinations.
This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
