Snort mailing list archives
Re: Multiple snorts on its own cpu core?
From: "Chan, Wilson" <wchan () honolulu gov>
Date: Thu, 18 Mar 2010 11:40:34 -1000
What does this do? "schedtool -M 2 -p 10 $PID" Is this really needed?
From some quick reading it seems that using "schedtool -a 0x01 $PID" should do the trick for locking the snort pid to cpu1.
==Schedtool man parameters==
-M policy
for manual/raw mode; policy is the number of the scheduling policy (see above for 0-4). This option is mostly for
kernel guys that want to test their new implementations.
-p prio
specify static priority required for SCHED_FIFO and SCHED_RR. Usually ranged from 1-99.
Wilson Chan
-----Original Message-----
From: Edward Bjarte Fjellskål [mailto:edward.fjellskal () redpill-linpro com]
Sent: Wednesday, March 17, 2010 9:59 PM
To: Chan, Wilson
Cc: snort-users () lists sourceforge net
Subject: Re: [Snort-users] Multiple snorts on its own cpu core?
Chan, Wilson wrote:
How do you run each instance of snort on its own CPU core? I have a server that has 8 cores and vaguely remember someone on the list mentioning it was possible to run snort on its own core. Thanks!
Hi Chan Wilson,
A basic way of doing this, is shown here (Linux):
----8<----
#!/bin/bash
PIDFILE="/var/run/snort_eth1.pid"
if [ -r $PIDFILE ] && [ -s $PIDFILE ];then
PID=`cat $PIDFILE`
schedtool $PID
schedtool -a 0x01 $PID
schedtool -M 2 -p 10 $PID
schedtool $PID
else
echo "No pid file, or empty pidfile! - exit!"
fi
----8<----
Depending on your multi-setup, you should add some logic to
check for which snort instance you run, and pin that to a
different cpu 0x02 etc...
Read up on schedtool... there are some other tools that
you also can use for doing the same.
I also wrote this in my recent blogpost:
http://www.gamelinux.org/?p=81
But ill add the details shown here :)
Regards,
ebf0
*Wilson* ------------------------------------------------------------------------ ------------------------------------------------------------------------------ Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev ------------------------------------------------------------------------ _______________________________________________ Snort-users mailing list Snort-users () lists sourceforge net Go to this URL to change user options or unsubscribe: https://lists.sourceforge.net/lists/listinfo/snort-users Snort-users list archive: http://www.geocrawler.com/redir-sf.php3?list=snort-users
------------------------------------------------------------------------------ Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev _______________________________________________ Snort-users mailing list Snort-users () lists sourceforge net Go to this URL to change user options or unsubscribe: https://lists.sourceforge.net/lists/listinfo/snort-users Snort-users list archive: http://www.geocrawler.com/redir-sf.php3?list=snort-users
Current thread:
- Multiple snorts on its own cpu core? Chan, Wilson (Mar 17)
- Re: Multiple snorts on its own cpu core? Eoin Miller (Mar 17)
- Re: Multiple snorts on its own cpu core? Edward Bjarte Fjellskål (Mar 18)
- Re: Multiple snorts on its own cpu core? Chan, Wilson (Mar 18)
- Re: Multiple snorts on its own cpu core? Edward Bjarte Fjellskål (Mar 19)
- Re: Multiple snorts on its own cpu core? Chan, Wilson (Mar 18)
