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

[9.0044-33] Spikes of High CPU and memory

Hi All

I am using v9.0044-33 with UTM 120 rev 5. I am also using disk as part of the htp_local_db

It seems that the box is spiking on cpu and the memory is high .I have attached the relevant pic

As part of the troubleshooting I used perf top
Results 
  
   PerfTop:    1403 irqs/sec  kernel:22.1%  exact:  0.0% [1000Hz cycles],  (all, 2 CPUs)
-------------------------------------------------------------------------------------------------------------------------------------

    58.13%  pngquant                [.] 0x558a
     4.60%  libz.so.1.2.3           [.] longest_match
     2.41%  libpng12.so.0.31.0      [.] 0xf93c
     2.21%  [kernel]                [k] read_hpet
     1.40%  [unknown]               [.] 0x8050ed3
     1.07%  libz.so.1.2.3           [.] deflate_slow
     0.97%  libc-2.11.3.so          [.] msort_with_tmp
     0.93%  libcairo.so.2.10800.8   [.] unpremultiply_data
     0.68%  perf                    [.] 0x1e000
     0.59%  libc-2.11.3.so          [.] memcpy
     0.58%  libexpat.so.1.5.2       [.] 0xf9e6
     0.56%  libz.so.1.2.3           [.] fill_window
     0.48%  libfontconfig.so.1.3.0  [.] .L110
     0.47%  ld-2.11.3.so            [.] do_lookup_x
     0.39%  libc-2.11.3.so          [.] _int_malloc
     0.36%  ntpd                    [.] 0x1d013
     0.36%  libfreetype.so.6.3.18   [.] TT_RunIns
     0.33%  libfreetype.so.6.3.18   [.] 0x17a25
     0.33%  libfontconfig.so.1.3.0  [.] FcCompareFamily
     0.32%  libasapsdk.so           [.] 0x20c35
     0.29%  libc-2.11.3.so          [.] strstr
     0.27%  libz.so.1.2.3           [.] adler32
     0.24%  libperl.so              [.] 0x101f1f
     0.22%  libc-2.11.3.so          [.] __i686.get_pc_thunk.bx
     0.21%  postgres                [.] 0x2b7d4c
     0.20%  libpixman-1.so.0.16.0   [.] pixman_rasterize_edges
     0.20%  libc-2.11.3.so          [.] malloc
     0.20%  libc-2.11.3.so          [.] strcmp
     0.19%  [kernel]                [k] __kmalloc
     0.19%  libc-2.11.3.so          [.] __memset_ia32
     0.18%  libz.so.1.2.3           [.] inflate_fast
     0.18%  [kernel]                [k] unmap_vmas
     0.17%  [vdso]                  [.] 0x55576431
     0.16%  [kernel]                [k] __schedule
     0.16%  [kernel]                [k] page_fault
     0.16%  [kernel]                [k] ia32_sysenter_target
     0.16%  libpthread.so.0         [.] 0xefbf
     0.15%  [kernel]                [k] timerqueue_add
     0.14%  libc-2.11.3.so          [.] _int_free
     0.14%  libpixman-1.so.0.16.0   [.] pixman_edge_init
     0.14%  [kernel]                [k] _raw_spin_lock
     0.14%  [kernel]                [k] hpet_legacy_next_event
     0.14%  libc-2.11.3.so          [.] free


what is that process and why it's inroducing spikes to the box?

/root # top -b -n 1 | head -n 12  | tail -n 5
13298 root      39  19  3640 2080  632 R     90  0.1   0:00.73 pngquant
 3729 root      20   0 11528 4788 1772 S     12  0.2  91:02.42 selfmonng.plx
 4162 root      20   0 10140 6212 1668 S      9  0.3  23:28.03 dns-resolver.pl
13299 root      20   0  2808 1212  804 R      9  0.1   0:00.07 top
 4686 root      20   0 32940  11m 3028 S      4  0.6 163:57.32 ctasd


Memory is normal at the moment: 

/root # ps auxf | sort -nr -k 4 | head -5
810      28489  1.0 18.9 1205400 387520 ?      Ssl  12:18   3:07 /var/chroot-http/usr/bin/httpproxy -f -c /var/chroot-http -u httpproxy
root      4324  1.8 12.3 339384 253364 ?       Ssl  16:27   0:58 /usr/bin/cssd -d
snort     5520  0.3  5.5 385324 113612 ?       S


Most of the swap is allocated to the HTTP proxy (Run top then press 'O' (capital letter o) followed by 'p' then 'enter'. Now processes should be sorted by their swap usage.)

top - 17:22:28 up 3 days,  8:16,  1 user,  load average: 0.67, 1.22, 1.30
Tasks: 344 total,   1 running, 341 sleeping,   0 stopped,   2 zombie
Cpu(s):  2.4%us,  2.7%sy,  0.0%ni, 94.6%id,  0.3%wa,  0.0%hi,  0.0%si,  0.0%st
Mem:   2048484k total,  1666536k used,   381948k free,     3732k buffers
Swap:  1048572k total,   401552k used,   647020k free,   606832k cached

  PID USER      PR  NI  VIRT  RES  SHR S   %CPU %MEM    TIME+  SWAP COMMAND
28489 httpprox  20   0 1177m 377m 1312 S      0 18.9   0:36.18 799m httpproxy
28490 httpprox  20   0 1177m 377m 1312 S      0 18.9   0:07.72 799m httpproxy
28491 httpprox  20   0 1177m 377m 1312 S      0 18.9   0:00.74 799m httpproxy
28505 httpprox  20   0 1177m 377m 1312 S      0 18.9   0:00.14 799m httpproxy
28508 httpprox  20   0 1177m 377m 1312 S      0 18.9   0:00.75 799m httpproxy
28509 httpprox  20   0 1177m 377m 1312 S      0 18.9   0:00.83 799m httpproxy
28510 httpprox  20   0 1177m 377m 1312 S      0 18.9   0:00.50 799m httpproxy

28511 httpprox  20   0 1177m 377m 1312 S      0 18.9   0:00.47 799m httpproxy
28512 httpprox  20   0 1177m 377m 1312 S      0 18.9   0:00.43 799m httpproxy
28513 httpprox  20   0 1177m 377m 1312 S      0 18.9   0:00.43 799m httpproxy
28514 httpprox  20   0 1177m 377m 1312 S      0 18.9   0:00.41 799m httpproxy
28515 httpprox  20   0 1177m 377m 1312 S      0 18.9   0:00.45 799m httpproxy


There are  too many child-processes for httpproxy is this normal?


This thread was automatically locked due to age.
  • the big ram eater is the http proxy..the ips also has issues.  Combine the two and it's disastrous.  You are only using ips and minor things so your config is fine.  turn on http proxy though and your box will fall over..your 150 users will think they are on dialup if they can get to the net at all.


    I'm with you on this. I have about 100 users behind my asg320 of which a couple are pretty heavy users. I'm about to Switch to a 425 because it is becoming a real pain. httpproxy more or less eats up most of the ressources and is soooo slow!

    I'm kind of wondering how they can still promote the 320 for 200-800 Users. I can't even get 100 Users to work properly. How on earth is anyone getting 800 stations to work behind this? deactivate all functions?!
  • How on earth is anyone getting 800 stations to work behind this? deactivate all functions?!

    Pretty much. Just basic packet filtering and nothing else. 

    If you're running FullGuard UTM with regular users, a 320 tops out at around 200 users. If however you are a "power user" (per astaro's sizing guidelines) with large amounts of email, web, IPS, and/or VPN usage, going up a unit or two in size is indicated.
  • I'm with you on this. I have about 100 users behind my asg320 of which a couple are pretty heavy users. I'm about to Switch to a 425 because it is becoming a real pain. httpproxy more or less eats up most of the ressources and is soooo slow!

    I'm kind of wondering how they can still promote the 320 for 200-800 Users. I can't even get 100 Users to work properly. How on earth is anyone getting 800 stations to work behind this? deactivate all functions?!


    once astaro get their ram usage fixed in two areas:
    1. the rampant memory leaks
    2. realistic minimum ram minimums

    then their recommendations make sense.  It seems they are marketing for the bare minimum...aka 2 gigs for 200 folks..yeah that's basically essentials.  I know it's the way it is done and it's technically legal...but it sure sucks in reality.

    Owner:  Emmanuel Technology Consulting

    http://etc-md.com

    Former Sophos SG(Astaro) advocate/researcher/Silver Partner

    PfSense w/Suricata, ntopng, 

    Other addons to follow

  • once astaro get their ram usage fixed in two areas:
    1. the rampant memory leaks
    2. realistic minimum ram minimums

    then their recommendations make sense.  It seems they are marketing for the bare minimum...aka 2 gigs for 200 folks..yeah that's basically essentials.  I know it's the way it is done and it's technically legal...but it sure sucks in reality.


    But will i ignote warranty and open my ASG320 to upgrade RAM to 4GB. Will it still work ? I understand that i will loose support as well ?
  • I may not be a fan of the ASG appliances but i would HIGHLY recommend you NOT do that.  If you want the flexibility of your own hardware purchase the per user license.....use your support contract to bug the snot out of them...don't just throw it away.

    Owner:  Emmanuel Technology Consulting

    http://etc-md.com

    Former Sophos SG(Astaro) advocate/researcher/Silver Partner

    PfSense w/Suricata, ntopng, 

    Other addons to follow

  • Krycek, have you asked you reseller for a trial of a new 320?


    Cheers - Bob

    Sorry for any short responses!  Posted from my iPhone.
     
    Sophos UTM Community Moderator
    Sophos Certified Architect - UTM
    Sophos Certified Engineer - XG
    Gold Solution Partner since 2005
    MediaSoft, Inc. USA
  • Bob: No I haven't. Are they much better than the old ones?

    William: Not a bad idea at all. However I'm a little afraid I will have trouble determining how many licenses I will have to buy. There's a script in this forum somewhere that I can run on the box to see how many active IPs I have. However I don't know its behaviour when I do webhosting and emailserver hosting in a DMZ behind the ASG. Does every accessing external user/IP count as well? Traffic is beeing processed by the ASG and if that's true, that could go into thousands. Right now I would expect about 250 active IPs of which only about 100 are real users.  The rest are Servers, Infrastructure, cellphones, printers, and so on. So I should be fine with the 500 users License?
    I have a bunch of "old" Server machines that would work perfectly well if I throw in a couple of NICs. Any suggestions for those? I have 4x PCIe half-height Slots available.
  • Hi Krycek,

    the new 320's are a big step forward regarding hardware performance. There is a hardware exchange program that makes it quite affordable to get a new 320. We run two 320's as HA Cluster against ~180 Users with almost everything enabled (no ips, no ssl scanning, no pop3) on 9.004 with auto restart of the http proxy as mentioned somewhere here in the thread until the memory leak is fixed).

    Regards
    Manfred
  • Hi Krycek,

    My understanding is that the IP counter excludes IP's originating on the Internet so if you have public facing servers, only the internal servers are counted, not the clients connecting from outside.
  • Hi Krycek,

    My understanding is that the IP counter excludes IP's originating on the Internet so if you have public facing servers, only the internal servers are counted, not the clients connecting from outside.


    Only internal IPS are counted...barring a misconfiguration

    Owner:  Emmanuel Technology Consulting

    http://etc-md.com

    Former Sophos SG(Astaro) advocate/researcher/Silver Partner

    PfSense w/Suricata, ntopng, 

    Other addons to follow