<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=ks_c_5601-1987"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:"¸¼Àº °íµñ";
panose-1:2 11 5 3 2 0 0 2 0 4;}
@font-face
{font-family:±¼¸²Ã¼;
panose-1:2 11 6 9 0 1 1 1 1 1;}
@font-face
{font-family:"\@¸¼Àº °íµñ";
panose-1:2 11 5 3 2 0 0 2 0 4;}
@font-face
{font-family:"\@±¼¸²Ã¼";
panose-1:2 11 6 9 0 1 1 1 1 1;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
text-align:justify;
text-justify:inter-ideograph;
text-autospace:none;
word-break:break-hangul;
font-size:10.0pt;
font-family:"¸¼Àº °íµñ";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
pre
{mso-style-priority:99;
mso-style-link:"¹Ì¸® ¼½ÄÀÌ ÁöÁ¤µÈ HTML Char";
margin:0cm;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:±¼¸²Ã¼;}
span.EmailStyle17
{mso-style-type:personal-compose;
font-family:"¸¼Àº °íµñ";
color:windowtext;}
span.HTMLChar
{mso-style-name:"¹Ì¸® ¼½ÄÀÌ ÁöÁ¤µÈ HTML Char";
mso-style-priority:99;
mso-style-link:"¹Ì¸® ¼½ÄÀÌ ÁöÁ¤µÈ HTML";
font-family:±¼¸²Ã¼;}
.MsoChpDefault
{mso-style-type:export-only;
font-family:"¸¼Àº °íµñ";}
/* Page Definitions */
@page WordSection1
{size:612.0pt 792.0pt;
margin:3.0cm 72.0pt 72.0pt 72.0pt;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=KO link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span lang=EN-US>HI!<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>As I enabled the packet profiling, packet drop was generated.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>The packet drop was confirmed by ¡°packet.kernel_drop¡± in stats.log.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>I want to always enable the packet profiling in my product, how can I improve?<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>I generated 160 Kpps(packet per sec) traffic and lost 30% of the packets. The size of each packet size is 64 bytes.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>I have analyzed the source code and have found that packet drop will not occur if the SCProfilingPrintPacketProfile() function is not executed.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>How do I improve this function and are there any other improvement options?<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>Below is the hardware specification and suricata configuration information.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>Hardware spec.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>CPU : Intel(R) Xeon(R) CPU E5-2660 v3 @ 2.60GHz<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> 10 cores, 20 threads<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>Memory : 16G<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>Ethernet : Intel Corporation 82580 Gigabit ( 1Gbps)<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>Suricata Version : 3.2.1<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>OS – linux debian 8<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>excute command : "suricata -c /etc/suricata/suricata.yaml --af-packet"<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>number of rules : 9000<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>suricata.yaml<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>af-packet:<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> - interface: eth0<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> threads: auto<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> cluster-id: 99<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> cluster-type: cluster_flow<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> defrag: yes<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> use-mmap: yes<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> buffer-size: 64535<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> copy-mode: ips<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> copy-iface: eth1<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US> - interface: eth1<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> threads: auto<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> cluster-id: 98<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> cluster-type: cluster_flow<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> defrag: yes<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> use-mmap: yes<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> buffer-size: 64535<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> copy-mode: ips<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> copy-iface: eth0<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US> packets:<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> # Profiling can be disabled here, but it will still have a<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> # performance impact if compiled in.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> enabled: yes<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> filename: packet_stats.log<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> append: yes<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US> # per packet csv output<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> csv:<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US> # Output can be disabled here, but it will still have a<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> # performance impact if compiled in.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> enabled: yes<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US> filename: packet_stats.csv<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>Sincerely<o:p></o:p></span></p></div></body></html>