<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: syslog udp drops in linux in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/syslog-udp-drops-in-linux/m-p/401782#M71517</link>
    <description>&lt;P&gt;We have almost like 7000 devices and its not possible to change to UDP. &lt;/P&gt;

&lt;P&gt;Also I changed the net.core.rmem_max  in the /etc/sysctl.conf&lt;/P&gt;

&lt;P&gt;and also changed the local.conf entry for the so_rcvbuf value.  &lt;/P&gt;

&lt;P&gt;I still see drops. Is there any procedure I need to follow in order to come at the correct value that I should give in the rmem and so_rcvbuf?&lt;/P&gt;</description>
    <pubDate>Tue, 22 Jan 2019 08:13:53 GMT</pubDate>
    <dc:creator>dbashyam</dc:creator>
    <dc:date>2019-01-22T08:13:53Z</dc:date>
    <item>
      <title>syslog udp drops in linux</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/syslog-udp-drops-in-linux/m-p/401780#M71515</link>
      <description>&lt;P&gt;Hi, &lt;/P&gt;

&lt;P&gt;Architecture: &lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt;We have syslog-ng running in our infra. &lt;/LI&gt;
&lt;LI&gt;This syslog resides behind a LB &lt;/LI&gt;
&lt;LI&gt;This alerts come to LB and from LB it gets processed at syslog-ng &lt;/LI&gt;
&lt;LI&gt;The syslog logs are forwarded to splunk &lt;/LI&gt;
&lt;/OL&gt;

&lt;P&gt;Issue: &lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt;When the syslog-ng are sent to LB alerts are getting dropped, this was confirmed by doing a netstat -us &lt;/LI&gt;
&lt;/OL&gt;

&lt;P&gt;netstat -us &lt;BR /&gt;
IcmpMsg: &lt;BR /&gt;
InType3: 86 &lt;BR /&gt;
InType8: 63 &lt;BR /&gt;
InType11: 24 &lt;BR /&gt;
InType13: 6 &lt;BR /&gt;
InType17: 18 &lt;BR /&gt;
OutType0: 63 &lt;BR /&gt;
OutType3: 1719 &lt;BR /&gt;
OutType11: 3394 &lt;BR /&gt;
OutType14: 6 &lt;BR /&gt;
Udp: &lt;BR /&gt;
3541784219 packets received &lt;BR /&gt;
6194 packets to unknown port received. &lt;BR /&gt;
13334858510 packet receive errors &lt;BR /&gt;
3292282273 packets sent &lt;BR /&gt;
13334858510 receive buffer errors &lt;BR /&gt;
44 send buffer errors &lt;BR /&gt;
UdpLite: &lt;BR /&gt;
IpExt: &lt;BR /&gt;
InNoRoutes: 3728 &lt;BR /&gt;
InMcastPkts: 6 &lt;BR /&gt;
InOctets: 13341061420695 &lt;BR /&gt;
OutOctets: 6925411558186 &lt;BR /&gt;
InMcastOctets: 216 &lt;BR /&gt;
InNoECTPkts: 20437111460 &lt;BR /&gt;
InECT0Pkts: 48 &lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt;The configuration in syslog-ng.conf is &lt;/LI&gt;
&lt;/OL&gt;

&lt;P&gt;cat syslog-ng.conf | more &lt;BR /&gt;
@version: 3.5 &lt;/P&gt;

&lt;P&gt;options { &lt;BR /&gt;
threaded (yes); &lt;BR /&gt;
flush_lines (0); &lt;BR /&gt;
keep_timestamp (no); &lt;BR /&gt;
stats-freq (600); &lt;BR /&gt;
mark-freq (0); &lt;BR /&gt;
time_reopen (10); &lt;BR /&gt;
log_fifo_size (120000); &lt;BR /&gt;
create_dirs (no); &lt;BR /&gt;
keep_hostname (yes); &lt;BR /&gt;
dir_perm(0755); &lt;BR /&gt;
perm(0644); &lt;BR /&gt;
chain_hostnames(no); &lt;BR /&gt;
normalize_hostnames(yes); &lt;BR /&gt;
use_dns (yes); &lt;BR /&gt;
use_fqdn (yes); &lt;BR /&gt;
dns_cache(yes); &lt;BR /&gt;
}; &lt;/P&gt;

&lt;P&gt;source s_tcp { tcp(ip(10.xxx.xx.xx) port(6514) keep-alive(yes) tcp-keep-alive(yes) max_connections(3000)); &lt;BR /&gt;
tcp(ip(10.xxx.xx.xx) port(6514) keep-alive(yes) tcp-keep-alive(yes) max_connections(3000)); &lt;BR /&gt;
tcp(ip(10.xxx.xx.xx) port(6514) keep-alive(yes) tcp-keep-alive(yes) max_connections(3000)); &lt;BR /&gt;
tcp(ip(10.xxx.xx.xx) port(6514) keep-alive(yes) tcp-keep-alive(yes) max_connections(3000)); &lt;BR /&gt;
tcp(ip(10.xxx.xx.xx) port(6514) keep-alive(yes) tcp-keep-alive(yes) max_connections(3000)); &lt;BR /&gt;
}; &lt;/P&gt;

&lt;P&gt;source s_udp { udp(ip(10.xxx.xx.xx) port(6514) so_rcvbuf(128000000)); &lt;BR /&gt;
udp(ip(10.xxx.xx.xx) port(6514)); &lt;BR /&gt;
udp(ip(10.xxx.xx.xx) port(6514)); &lt;BR /&gt;
udp(ip(10.xxx.xx.xx) port(6514)); &lt;BR /&gt;
udp(ip(10.xxx.xx.xx) port(6514)); &lt;BR /&gt;
}; &lt;/P&gt;

&lt;P&gt;source s_internal { &lt;BR /&gt;
internal(); &lt;BR /&gt;
}; &lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt;cat /etc/sysctl.conf&lt;/LI&gt;
&lt;/OL&gt;

&lt;P&gt;To increase TCP max buffer size up to 128MB&lt;/P&gt;

&lt;P&gt;net.core.rmem_max = 128000000 &lt;BR /&gt;
net.core.wmem_max = 128000000 &lt;/P&gt;

&lt;OL&gt;
&lt;LI&gt;&lt;P&gt;free -m&lt;BR /&gt;
          total        used        free      shared  buff/cache   available&lt;BR /&gt;
Mem:          64249        2914         530           4       60805       60650&lt;BR /&gt;
Swap:          3967        1097        2870&lt;/P&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;P&gt;Environment&lt;BR /&gt;
syslog-ng and snmp (looperng)&lt;BR /&gt;
RHEL 7.3&lt;/P&gt;&lt;/LI&gt;
&lt;/OL&gt;

&lt;P&gt;grep -c ^processor /proc/cpuinfo &lt;BR /&gt;
16&lt;/P&gt;

&lt;P&gt;64GB Memory&lt;/P&gt;

&lt;P&gt;2TB disk&lt;/P&gt;

&lt;P&gt;How do we reduce the "packet receive errors". Is there any tweaking that splunk can recommend so that we don't loose syslog data? &lt;/P&gt;

&lt;P&gt;Thanks for any inputs&lt;/P&gt;

&lt;P&gt;Dinesh&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 22:44:10 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/syslog-udp-drops-in-linux/m-p/401780#M71515</guid>
      <dc:creator>dbashyam</dc:creator>
      <dc:date>2020-09-29T22:44:10Z</dc:date>
    </item>
    <item>
      <title>Re: syslog udp drops in linux</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/syslog-udp-drops-in-linux/m-p/401781#M71516</link>
      <description>&lt;P&gt;Hi, here you can find some tips: &lt;A href="https://support.oneidentity.com/technical-documents/syslog-ng-premium-edition/7.0.12/collecting-log-messages-from-udp-sources"&gt;https://support.oneidentity.com/technical-documents/syslog-ng-premium-edition/7.0.12/collecting-log-messages-from-udp-sources&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;But unless there is a special reason why you must use UDP, I'd suggest using TCP instead.&lt;/P&gt;</description>
      <pubDate>Thu, 10 Jan 2019 09:19:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/syslog-udp-drops-in-linux/m-p/401781#M71516</guid>
      <dc:creator>frobert</dc:creator>
      <dc:date>2019-01-10T09:19:41Z</dc:date>
    </item>
    <item>
      <title>Re: syslog udp drops in linux</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/syslog-udp-drops-in-linux/m-p/401782#M71517</link>
      <description>&lt;P&gt;We have almost like 7000 devices and its not possible to change to UDP. &lt;/P&gt;

&lt;P&gt;Also I changed the net.core.rmem_max  in the /etc/sysctl.conf&lt;/P&gt;

&lt;P&gt;and also changed the local.conf entry for the so_rcvbuf value.  &lt;/P&gt;

&lt;P&gt;I still see drops. Is there any procedure I need to follow in order to come at the correct value that I should give in the rmem and so_rcvbuf?&lt;/P&gt;</description>
      <pubDate>Tue, 22 Jan 2019 08:13:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/syslog-udp-drops-in-linux/m-p/401782#M71517</guid>
      <dc:creator>dbashyam</dc:creator>
      <dc:date>2019-01-22T08:13:53Z</dc:date>
    </item>
    <item>
      <title>Re: syslog udp drops in linux</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/syslog-udp-drops-in-linux/m-p/401783#M71518</link>
      <description>&lt;P&gt;Hi, &lt;BR /&gt;
- You can try increasing the UDP buffers (both kernel and syslog-ng side) even to multiple GBs.&lt;BR /&gt;
- If that does not help, you can split the UDP traffic to even more  different udp sources (different port is enough). Each source will have its own udp buffer so the chance to fill up decreases.&lt;BR /&gt;
- The next thing to consider is to place new syslog-ng machines behind the LB.&lt;BR /&gt;
- Last but not least I would suggest to place multiple syslog-ng relay servers as close as possible to the original UDP log sources (eg. one per each geolocation/subnet/etc) and send the logs to the central syslog-ngs through tcp.&lt;/P&gt;</description>
      <pubDate>Tue, 22 Jan 2019 09:40:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/syslog-udp-drops-in-linux/m-p/401783#M71518</guid>
      <dc:creator>GergelyBodnar</dc:creator>
      <dc:date>2019-01-22T09:40:44Z</dc:date>
    </item>
  </channel>
</rss>

