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

increasing swapping since 8.102

Hi,

have anyone seen something similar and resolved it?
We have one ASG220 in HA. RAM Usage is about 60% but the swapping is steadily increasing. Same on a Software Version with 2GB RAM and also around 60% RAM usage. I'm wondering where this swapping comes from. Rebooting is the last solution.

Regards

Achim


This thread was automatically locked due to age.
  • Is your webadmin console left open by any chance?
    That is what caused a growth in memory usage on my ASG 8.102 system
    Read this thread:  https://community.sophos.com/products/unified-threat-management/astaroorg/f/51/t/21201
  • What is the process high High CPU?  (EIther execute the "top" command via CLI or go to Support>Advanced>Process List)
  • Hi,

    no there's no open connection to webadmin [[;)]]
    Highest CPU consumption is from snort but only peaks. As I see this behaviour on 3 ASGs one software and two 320 ASGs everyone in HA Cluster, I was wondering if someone else had seen this before. So this should be a support case [[;)]]

    Regards

    Achim
  • Hi Achim,

    I've recognized this behavior on our 320 too since the update to 8.102. We also have no (constantly) open webadmin session. The most memory consuming process is the http-proxy (up to 25%). If I stop and start the proxy, the mem consumtion drops to a normal level, but over 10 to 15 days it rises again ... lets hope for a 8.103...

    Regards
    Manfred
  • I asked about swapping here about a year ago.  To make a long story short, the swap file size never goes down unless you reboot.  If you aren't seeing RAM usage at 100%, you can just ignore the swap size.

    Cheers - Bob
  • As an addendum to Bob, we've covered this in the past, and to make a long story short, 
    'allocated' swap isn't the same as 'actively used' swap. As mentioned, if your not at 100% memory usage, the amount allocated for swap won't be in use, just ready for it. [:)] You can do a search for more in-depth explanations of this behavior and other options available if your feeling adventurous.
  • As an addendum to Bob, we've covered this in the past, and to make a long story short, 
    'allocated' swap isn't the same as 'actively used' swap. As mentioned, if your not at 100% memory usage, the amount allocated for swap won't be in use, just ready for it. [:)] You can do a search for more in-depth explanations of this behavior and other options available if your feeling adventurous.


    Hello, I would spend two words about this argument.
    Yesterday I have upgraded from v7.510 to v8.102 . The first thing that I observed today, seeing the first daily report, is the memory usage. I have added no features after the migration, the configuration is the same of v7. Comparing a random daily report in the past week with this one, you can see (I attatched 2 screenshot) the (almost) absence of swap in v7 and the 8% of swap in v8 (that becomes 12% today). Ok, you say that swap could be allocated but not used... on the other hand, if I see that RAM usage is decreasing and swap is increasing, perhaps it means that swap is really in use...

    eclipse79 a little worried...

    nb: perhaps I could try to install 32bit version of v8, that should use less ram
  • I asked about swapping here about a year ago.  To make a long story short, the swap file size never goes down unless you reboot.  If you aren't seeing RAM usage at 100%, you can just ignore the swap size.

    Cheers - Bob



    you won't see ram at 100% because the default kernel swappiness is 60 which means the system will start swapping looooong before you actually exhaust your ram.  vm.swappiness=0 will make sure swap isn't touched until there is real memory pressure and will prevent the system from swapping too early and hurting your system's performance.
  • Hi,

    have anyone seen something similar and resolved it?
    We have one ASG220 in HA. RAM Usage is about 60% but the swapping is steadily increasing. Same on a Software Version with 2GB RAM and also around 60% RAM usage. I'm wondering where this swapping comes from. Rebooting is the last solution.

    Regards

    Achim


    the early swapping is from a "misconfiguration" of the kernel swapping by Astaro.  I saw this as well and am familiar with this phenomenon  The default kernel swappiness is 60.  What needs to be done is to set that to zero or maybe 20.  This means the system will actually evacuate cache ram BEFORE heading to the many orders of magnitude slower disk.  If you have active support this tweak voids your support though.  So you need to add more ram or if you are feeling adventurous you can do the following:

    log into ssh as root
    cd /etc
    joe sysctl.conf
    add vm.swappiness=0 under the last line
    hold down control press k then press x
    reboot
  • There is no real consensus on swappiness hence the high default setting of 60 as william mentioned. This default setting is used by a few different distros and is not limited to astaro. 

    I always use 10-20 range as recommended by william but keep in mind that swappiness setting is no substitute to the lack of ram. If you have 1GB ram and are running local content database with swappiness setting of 0, one of your daemons might die unexpectedly due to lack of ram. 

    The old time unix/linux admins like no swapping for speed and efficiency but for a firewall like astaro, your setup may or may not let you experience the performance increase by limiting the swap usage. 

    Hope that helps.

    Regards 
    Bill.