[syslog-ng] Per-destination log_msg_size?

Jakub Jankowski shasta at toxcorp.com
Wed Feb 19 23:12:28 CET 2014


On 19.02.2014 08:10, David Schweikert wrote:
> We have some setups where we want to have a large log_msg_size, but need
> to send some logs to an external party which only can handle standard
> BSD syslog messages with a maximum size of 1024 bytes.
>
> Question: would it be possible to add a per-destination log-msg-size to
> truncate the messages on a per-destination basis? I think that it would
> be very useful. Something like:
>
> destination d_remote { udp("192.168.65.10" port(514) log_msg_size(1024)); };
>
> Do you find it a good idea and is there any chance that this might be
> implemented?

Use a template() that utilizes $(substr) template function. See 
http://www.balabit.com/sites/default/files/documents/syslog-ng-ose-3.4-guides/en/syslog-ng-ose-v3.4-guide-admin/html/reference-template-functions.html 
for more details.


HTH.

-- 
Jakub Jankowski|shasta at toxcorp.com|http://toxcorp.com/
GPG: FCBF F03D 9ADB B768 8B92 BB52 0341 9037 A875 942D


More information about the syslog-ng mailing list