Guest User!

You are not Sophos Staff.

This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

UTM Performance Crashes with A/V Scanning, but CPU only at 12%

I'm having an issue with Sophos UTM 9.307 that when it performs A/V scanning on large file (300 MB) downloads, my entire network comes to a screeching halt, with several machines dropping network connection or freezing up.  BTW, I'm using the dual A/V scan.

My UTM installation is on a home-built machine using an Intel i7-4790k CPU @ 4.0 GHz, hyperthreaded with 8 cores, 8 GB RAM and a 60 GB SSD, Z97 chipset.  NIC's are a single Intel i-350, 4 port (only 2 used - one WAN, one LAN) and an Intel NIC built onto the motherboard.  I wouldn't think I'd be potentially hardware limited with this setup.

Per posts here on the Sophos BBS, I've disabled Intel's "Enhanced SpeedStep" and "Turbo Boost" options in BIOS, along with the enhanced "C states".  I've also performed BarryG's recommendation at the console:

echo "performance" >/sys/devices/system/cpu/cpuN/cpufreq/scaling_governor

for each logical CPU 0-7.

The maximum CPU usage I've ever recorded in Sophos UTM during normal operation is around 12% when performing a scan on a single 300 MB download.  Note that this 12% corresponds to about 100% loading of one logical CPU core.  I was able to get around 17% CPU usage once when I tried the same download and scan operations on 2 machines (real machines, not VM's) simultaneously, but that completely locked up the network and I only had a few other machines running.  When not performing A/V scanning, my CPU hovers around 1-2%, since we don't have that much network traffic right now.

It seems like the UTM isn't taking full advantage of all the CPU horsepower that is available.  I could understand one of the connections / scans being tied to a logical CPU (with SNORT, etc) and locking it up, but it seems like the UTM would transfer other connections to other logical CPU's and not lock up the entire network.

BTW, the dual A/V scan of the 300 MB file took a couple of minutes.  Does this sound reasonable given the hardware?

It's almost as if the UTM is only using one of the available 8 logical cores to do almost all of the work in my system.

I'm aware that hyperthreading could be an issue due to the way the OS assigns the logical cores, such that logical core 0 and 1 are essentially the same physical core.  I could see this as being a problem when core 0 is at 100% load and the OS tries to give work to the next logical core (1 in this case), which is really already at 100%, but I thought that the underlying OS was "smart" enough to realize this.

Should I disable hyperthreading?  If so, will this corrupt my current Sophos UTM installation that expects to see 8 CPU's?

Does anyone have any other suggestions on setting, etc that would enable the full potential of this hardware setup or is this "normal" / to be expected?  

Thanks in advance,

- Ben


This thread was automatically locked due to age.
  • Ben, I think that trying to solve this is not a good use of your time.  I usually set AV to scan only files under 10MB.

    Cheers - Bob
  • Two thoughts:

    File size can be issue, it kinda depends on what the file is.  You can have a 300 MB pdf that scans quickly and have a 300 MB zip file containing 1000 executable files that scans slowly.  Want something hard to scan?  Try XP Service Pack 2.  It is a 266MB self-extracting zip that takes a little over 2 minutes to av scan.

    The other is what scanner you are using.  The UTM has both SAV (Sophos) and Avira.  I don't recall where you set the default for single scan (not in Web Filtering).  If you are doing single scan in one, and then try the other, and they are both slow then it's probably not the AV scanner's fault (could be file, could be setup/config).
  • Thanks for the advice Bob and Michael.

    The ~300 MB file that brought my system to its knees was the latest NVIDIA GeForce graphics driver.  I was using the dual scan A/V option (SAV is my default for single scan).

    I guess what puzzles me is how this one scan could essentially bring down my network, given the hardware, and the extremely light other network traffic that was occurring at the same time.  I'm only running a small home test environment, whereas the Sophos UTM was designed and operates in much, much larger enterprise, production environments where surely there are many simultaneous A/V scans occurring along with other very heavy network traffic.

    Are there any other setup / configuration options that I could try, other than decreasing the A/V scan maximum file size?

    If I wanted to experiment and disable hypertheading, would my current UTM installation have issues, since it was originally installed and setup expecting to see 8 logical CPU's?

    Or would my current installation automatically adjust to the 4 cores if I disable hyperthreading?

    Thanks in advance.

    - Ben
  • Downloading / scanning something like that should cause that single download to be slow.  It should not bring the entire UTM to a halt.  Other computers should not have a major impact due to this.

    I suspect there is something in your setup which is giving this odd behavior.  Bu I don't know what.  I'm not a hardware expert.
  • Hmmmm, What do you have in 'Local networks' in Intrusion Prevention, Ben?

    Cheers - Bob
  • Thanks for the advice Bob and Michael.

    The ~300 MB file that brought my system to its knees was the latest NVIDIA GeForce graphics driver.  I was using the dual scan A/V option (SAV is my default for single scan).

    I guess what puzzles me is how this one scan could essentially bring down my network, given the hardware, and the extremely light other network traffic that was occurring at the same time.  I'm only running a small home test environment, whereas the Sophos UTM was designed and operates in much, much larger enterprise, production environments where surely there are many simultaneous A/V scans occurring along with other very heavy network traffic.

    Are there any other setup / configuration options that I could try, other than decreasing the A/V scan maximum file size?

    If I wanted to experiment and disable hypertheading, would my current UTM installation have issues, since it was originally installed and setup expecting to see 8 logical CPU's?

    Or would my current installation automatically adjust to the 4 cores if I disable hyperthreading?

    Thanks in advance.

    - Ben


    i would HIGHLY recommend you drop your scanning size to 10 megs....OR you put at least 32 GIGS of ram into the machine.  Since you have two a/v's scanning massive files which chews up loads of ram if you are trying to scan such huge files you force the system into swapping so heavily that the disk subsystem is thrashing and the cpu's have to wait.  While they are waiting they cannot process any other events.  The answer is simple..loads of ram or drop your scanning to 10 megs.  If you want to be sure about large files that's what endpoint a/v is for.
  • Per posts here on the Sophos BBS, I've disabled Intel's "Enhanced SpeedStep" and "Turbo Boost" options in BIOS, along with the enhanced "C states".  I've also performed BarryG's recommendation at the console:

    echo "performance" >/sys/devices/system/cpu/cpuN/cpufreq/scaling_governor

    for each logical CPU 0-7.


    Hi, the scaling trick won't survive a reboot, but shouldn't be needed if the BIOS setttings for disabling SpeedStep work.

    I would leave Turbo Boost ENABLED though; it won't hurt anything and might help.

    Try running 'top' from SSH while a large A/V scan is going.

    Barry
  • Bob, the only Local Network I have in IPS is the single "Internal (Network)" that was created by default during installation.

    William, thanks for the advice.  I guess endpoint A/V is the real solution, coupled with a max scan size of 10 MB.  I may try the additional RAM just to see where the breakpoint is with regards to filesize before I go to massive disk swaps.  Since I have an SSD for my drive, there's no audible hint at how bad it's thrashing.

    Barry, I had enabled / disabled TurboBoost during different tests and I do think that TurboBoost DID help slightly, although I didn't do a strict timing test (yet).  I'll also try running "top" and I'll post the results.  I did do a check from the console prompt as "root" (I forget the command) to check the maximum CPU frequency available.  It reported 4.4 GHz, which is the max TurboBoost frequency for the i7-4790k CPU I'm using.  However, right now, I have all cores set to "performance" which equates to 4.0 GHz.

    I've been re-reading the great previous posts all of you participated in on this subject awhile back, trying to see if I could glean any other insights.  Here's the links to these previous posts:

    https://community.sophos.com/products/unified-threat-management/astaroorg/f/52/t/29162

    https://community.sophos.com/products/unified-threat-management/astaroorg/f/52/t/28805

    Since the bulk of these posts were from a year or so ago, I was hoping that some of the underlying SNORT code had since been updated and optimized to take advantage of more modern CPU architecture [8-)].  Can't hurt to dream, right?

    Somewhere in these previous posts there was mention of someone achieving ~350 Mbps with IPS active.  However, I was unable to find out the specifics on how he achieved this.  Does anyone know / remember what the solution was (hardware and/or software settings)?

    Thanks,

    -Ben
  • Bob, the only Local Network I have in IPS is the single "Internal (Network)" that was created by default during installation.

    William, thanks for the advice.  I guess endpoint A/V is the real solution, coupled with a max scan size of 10 MB.  I may try the additional RAM just to see where the breakpoint is with regards to filesize before I go to massive disk swaps.  Since I have an SSD for my drive, there's no audible hint at how bad it's thrashing.

    Barry, I had enabled / disabled TurboBoost during different tests and I do think that TurboBoost DID help slightly, although I didn't do a strict timing test (yet).  I'll also try running "top" and I'll post the results.  I did do a check from the console prompt as "root" (I forget the command) to check the maximum CPU frequency available.  It reported 4.4 GHz, which is the max TurboBoost frequency for the i7-4790k CPU I'm using.  However, right now, I have all cores set to "performance" which equates to 4.0 GHz.

    I've been re-reading the great previous posts all of you participated in on this subject awhile back, trying to see if I could glean any other insights.  Here's the links to these previous posts:

    https://www.astaro.org/gateway-products/hardware-installation-up2date-licensing/49954-intel-core-processor-haswell-120-mbps-ips-web-filtering.html

    https://www.astaro.org/gateway-products/hardware-installation-up2date-licensing/46634-slow-throughput-fast-cable.html

    Since the bulk of these posts were from a year or so ago, I was hoping that some of the underlying SNORT code had since been updated and optimized to take advantage of more modern CPU architecture [8-)].  Can't hurt to dream, right?

    Somewhere in these previous posts there was mention of someone achieving ~350 Mbps with IPS active.  However, I was unable to find out the specifics on how he achieved this.  Does anyone know / remember what the solution was (hardware and/or software settings)?

    Thanks,

    -Ben


    350 megabits plus is achieved with high numbers of users.  Snort is single threaded and modern cpu's are good for up to 350 Mbps per instance with high amounts of traffic constantly.  Snort is working on a new multi threaded version but it in basically pre-alphpa so it might be a bit..[:)]
  • so if you wanted to get a gigabit it is going to take 4 cpus with massive traffic on each one with a snort instance per cpu.