[Snort-users] Multiple snorts on its own cpu core?

Edward Bjarte Fjellskål edward.fjellskal at ...14590...
Thu Mar 18 03:59:06 EDT 2010


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 at 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





More information about the Snort-users mailing list