[syslog-ng] syslog-ng with multiple destinations

Szemere, László laszlo.szemere at oneidentity.com
Wed Aug 22 06:49:28 UTC 2018


Hello Sebastian,
 discussed with others, this error message most probably happens if the log
source sends a TCP RST message.
 an example for this: Firewall terminates a connection due to inactivity,
and syslog-ng tries to read from the connection.


 If I understand correctly I can't use this option ‘flow-control’ with
> destination d_SIEM_


Technically you can use the flow-control option with the d_SIEM destination
included (it will be still valid and applied for the d_BOX destination),
but since UDP is a connection less protocol, syslog-ng can not detect if
the destination has a congestion or not.

If the destination can not process the incoming UDP messages in time, the
incoming buffer will be filled up, and new messages will be dropped.

Br,
Laci



On Tue, Aug 21, 2018 at 2:34 PM, <swald.ext at orange.com> wrote:

> Thanks a lot for this response Laci.
>
>
>
> The file descriptor corresponds to a connection with the source of log
> applications…
>
>
>
> If I understand correctly I can't use this option ‘flow-control’ with
> destination d_SIEM_... Maybe that's what's causing me trouble.
>
>
>
> Best regards. Sebastian.
>
>
>
>
>
>
>
> Hello Sebastian,
>
>  the copied error message indicates that there was a problem with your
> TCP source (s_remote_tcp). But unfortunately I can not reproduce the exact
> same error.
>
>  Just to be sure, please check what connection was associated with the
> mentioned fd (in this case fd='32') when the error message occur.
>
>
>
>
>
>  Undependent from the connection problem. You mentioned: "We lose some
> logs."
>
>  Please notice, that the flow-control option is not interpreted in case of
> UDP connections (in both directions) so it is possible to loose messages
> with this configuration by design.
>
>
>
>
>
> Best regards,
>
> Laci
>
>
>
>
>
> On Tue, Aug 21, 2018 at 11:46 AM, <swald.ext at orange.com> wrote:
>
> Hello,
>
>
>
> We are a syslog-ng configuration with multiple destinations :
>
>
>
> source s_remote_udp {
>
>   udp(ip(0.0.0.0) port(514));
>
> };
>
>
>
> source s_remote_tcp {
>
>   tcp(ip(0.0.0.0) port(514) max-connections(1000) so_keepalive(yes));
>
> };
>
>
>
> destination d_SIEM_ { udp("10.0.1.145" port(514)); };
>
> destination d_BOX_ { file("/var/log/box/FLOW_$R_MONTH$R_DAY$R_HOUR$R_MIN.log"
> create_dirs(yes) dir_perm(0755) dir_owner(root) dir_group(root) owner(root)
> group(root)); };
>
>
>
> filter f_SIEM_ { match("FLOW:"); };
>
>
>
> log { source(s_remote_udp); source(s_remote_tcp); filter(f_SIEM_);
> destination(d_BOX_); destination(d_SIEM_);flags(flow-control,final); };
>
>
>
> We can see kind of errors :
>
> /var/log/syslog-ng.log : Aug  4 23:34:39 host1 syslog-ng[16290]: I/O error
> occurred while reading; fd='32', error='Connection reset by peer (104)'
>
>
>
> We lose some logs. We have a syslog-ng version 3.2.
>
>
>
> Can you help please please ?
>
>
>
> How can I diagnose the problem? How do I get to the root of the problem?
> Maybe debugging syslog-ng?
>
>
>
> Thanks in advance.
>
>
>
> Best regards. Sebastian.
>
>
>
> _________________________________________________________________________________________________________________________
>
>
>
> Ce message et ses pieces jointes peuvent contenir des informations confidentielles ou privilegiees et ne doivent donc
>
> pas etre diffuses, exploites ou copies sans autorisation. Si vous avez recu ce message par erreur, veuillez le signaler
>
> a l'expediteur et le detruire ainsi que les pieces jointes. Les messages electroniques etant susceptibles d'alteration,
>
> Orange decline toute responsabilite si ce message a ete altere, deforme ou falsifie. Merci.
>
>
>
> This message and its attachments may contain confidential or privileged information that may be protected by law;
>
> they should not be distributed, used or copied without authorisation.
>
> If you have received this email in error, please notify the sender and delete this message and its attachments.
>
> As emails may be altered, Orange is not liable for messages that have been modified, changed or falsified.
>
> Thank you.
>
>
> ____________________________________________________________
> __________________
> Member info: https://lists.balabit.hu/mailman/listinfo/syslog-ng
> Documentation: http://www.balabit.com/support/documentation/?
> product=syslog-ng
> FAQ: http://www.balabit.com/wiki/syslog-ng-faq
>
>
>
> _________________________________________________________________________________________________________________________
>
> Ce message et ses pieces jointes peuvent contenir des informations confidentielles ou privilegiees et ne doivent donc
> pas etre diffuses, exploites ou copies sans autorisation. Si vous avez recu ce message par erreur, veuillez le signaler
> a l'expediteur et le detruire ainsi que les pieces jointes. Les messages electroniques etant susceptibles d'alteration,
> Orange decline toute responsabilite si ce message a ete altere, deforme ou falsifie. Merci.
>
> This message and its attachments may contain confidential or privileged information that may be protected by law;
> they should not be distributed, used or copied without authorisation.
> If you have received this email in error, please notify the sender and delete this message and its attachments.
> As emails may be altered, Orange is not liable for messages that have been modified, changed or falsified.
> Thank you.
>
>
> ____________________________________________________________
> __________________
> Member info: https://lists.balabit.hu/mailman/listinfo/syslog-ng
> Documentation: http://www.balabit.com/support/documentation/?
> product=syslog-ng
> FAQ: http://www.balabit.com/wiki/syslog-ng-faq
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.balabit.hu/pipermail/syslog-ng/attachments/20180822/356aa037/attachment.html>


More information about the syslog-ng mailing list