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

Temporary 100% CPU Load - How to Identify Root Cause?

Hello Folks,

This is the situation:
From time to time (on a day/in a week) our Astaro ASG320 v.8.202 runs on 100% CPU. All inhouse Internet traffic is very slow then and users are complaining.

RAM is usually ~60% used, SWAP ~30% and Log and Data Disk have enough space.

Using the console and the "top" command it shows me among other information:


  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
19658 postgres  20   0 52616  35m  32m S 52.8  3.5   0:01.95 postgres
 4323 httpprox  20   0 1268m 288m 5048 S  38.6 28.7 432:21.06 httpproxy


These values differ. Sometimes the postgres and the httpproxy have a CPU load of 30-70% even. But everytime its these both services using most of the Astaro's device performance.

I GUESS someone causes some overload within the network. 
I cannot figure out where from or who is doing so.
The users use the webfilter proxy to browse through the Internet.
Having the webfilter live log running there is nothing suspicious during those "slow" times.

We are using an Online Hard Disk service by Strato by the way. Users upload and download data mostly using a https (WebDAV) connection therefore. 
The webfilter does NOT scan HTTPS traffic.

How can I identify and SOLVE the root cause of this 100% CPU load problem?

Thank you in advance!!
Regards,
Uwe

* * *

PS: Today this situation is happening very often! :-(

PPS: I cannot say that for sure but I think the following (and similar) webfilter live log lines occur when the CPU is on 100%:

2012:01:11-15:10:59 disgwac httpproxy[4323]: id="0003" severity="info" sys="SecureWeb" sub="http" request="(nil)" function="sc_handle_cmd" file="scr_scanner.c" line="510" message="cffs11.astaro.com: write: Connection refused"


2012:01:11-15:15:03 disgwac httpproxy[4323]: id="0003" severity="info" sys="SecureWeb" sub="http" request="(nil)" function="confd_config_reload_func" file="confd-client.c" line="757" message="reloading config done, new version 25231"
2012:01:11-15:15:03 disgwac httpproxy[4323]: id="0003" severity="info" sys="SecureWeb" sub="http" request="(nil)" function="confd_config_reload_func" file="confd-client.c" line="722" message="reloading config"

2012:01:11-15:15:14 disgwac httpproxy[4323]: id="0003" severity="info" sys="SecureWeb" sub="http" request="(nil)" function="sc_check_servers" file="scr_scanner.c" line="721" message="server 'cffs13.astaro.com' access time: 296ms"

012:01:11-15:45:55 disgwac httpproxy[4323]: id="0003" severity="info" sys="SecureWeb" sub="http" request="(nil)" function="sc_check_servers" file="scr_scanner.c" line="721" message="server 'cffs10.astaro.com' access time: 706ms"
2012:01:11-15:45:55 disgwac httpproxy[4323]: id="0003" severity="info" sys="SecureWeb" sub="http" request="(nil)" function="sc_check_servers" file="scr_scanner.c" line="721" message="server 'cffs12.astaro.com' access time: 99ms"
2012:01:11-15:45:55 disgwac httpproxy[4323]: id="0003" severity="info" sys="SecureWeb" sub="http" request="(nil)" function="sc_handle_cmd" file="scr_scanner.c" line="510" message="cffs01.astaro.com: write: Connection refused"
2012:01:11-15:45:56 disgwac httpproxy[4323]: id="0003" severity="info" sys="SecureWeb" sub="http" request="(nil)" function="sc_check_servers" file="scr_scanner.c" line="721" message="server 'cffs06.astaro.com' access time: 419ms"


This thread was automatically locked due to age.
  • Can I reinitalize the DB with these commands?:

    /etc/init.d/postgresql stop
    
    rm -fr /var/log/reporting/pgsql
    /etc/init.d/postgresql start
    mkdir /var/log/reporting/pgsql
    chown postgres[:P]ostgres /var/log/reporting/pgsql
    /var/storage/pgsql/init/reporting_db_init.sh -v
  • You can use those commands to wipe and recreate the reporting database.
    __________________
    ACE v8/SCA v9.3

    ...still have a v5 install disk in a box somewhere.

    http://xkcd.com
    http://www.tedgoff.com/mb
    http://www.projectcartoon.com/cartoon/1
  • The PostgreSQL service hosts the reporting tables e.g. Logging & Reporting > Mail Security > Mail Usage. If you don't use these tables you can disable them at Logging & Reporting > Reporting Settings > Settings. 

    See online help for this:
    Note - Disabling needless reports will lower the base load of your machine and can reduce performance bottlenecks. Try to keep time frames as short as possible since high amounts of stored data result in a higher base load and decreased responsiveness on the dynamical reporting pages.

    Regards,
    Marco
  • Someone should fix the help text; 'dynamical' isn't a word.

    Barry
  • The PostgreSQL service hosts the reporting tables e.g. Logging & Reporting > Mail Security > Mail Usage. If you don't use these tables you can disable them at Logging & Reporting > Reporting Settings > Settings. 

    See online help for this:
    Note - Disabling needless reports will lower the base load of your machine and can reduce performance bottlenecks. Try to keep time frames as short as possible since high amounts of stored data result in a higher base load and decreased responsiveness on the dynamical reporting pages.

    Regards,
    Marco


    That I did a very long time ago already, Marco. 
    The ASG only logs: Accounting (1month),  Authentication (1month), Firewall (1month), IPS (1month), RemoteAccess (1month), WebSecurity (1month)
  • An Astaro L2 technician remotely looked on our Astaro.

    Probably there is a hardware performance problem using a single core CPU and 1GB RAM. 

    Tremendous overload occurs since we are using an online storage service via HTTPS (WebDAV) access. How could one optimize that traffic on the Astaro?

    Btw:

    Can someone help me to get more out more information of the console "atop" command?
  • if you are overloading the appliance then it is time for a faster appliance or to get your own box and go software.  I would contact your nearest reseller for advice on that one.

    Owner:  Emmanuel Technology Consulting

    http://etc-md.com

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

    PfSense w/Suricata, ntopng, 

    Other addons to follow

  • upgrading to faster hardware is best solution. Alternatively upgrade RAM on the box to >2gig mem.
     may help little too...

    For tweaking asg settings follow the link in my signature. Would be nice if you comment result, especially if tweaking helped ;o)

    Sent from my iPad using Astaro.org (finally got One)
  • Put the 8.203 update on the system. I had to downgrade several of my systems after going to 8.201 or 8.202 after experiencing this and another RDNS check problem (took them all back to 8.103). I have moved them up to 8.203 and have monitored them for a couple weeks now and the problem seems to have gone away. Support never acknowledged this problem, just the RDNS for which they have since added a Strict check box, but both problems appeared at the same time.
  • Uwe, it's unfortunate that your school wasn't able to take advantage of the upgrade to 2GB for the ASG 320.  You might see if anyone in the world still has one available - I know our distributors ran out over a year ago.  I don't know that that alone would help you - if you have fairly-high swap, then it might be enough, but I bet that Sascha and William are right - that you also need more horsepower.

    Cheers - Bob
     
    Sophos UTM Community Moderator
    Sophos Certified Architect - UTM
    Sophos Certified Engineer - XG
    Gold Solution Partner since 2005
    MediaSoft, Inc. USA