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

[WAR 102] Too much memory for a single process

Hi y'all...

Haven't posted in a while but here it goes...

I've been happily running 4.025 for a while now but I've been getting this error for the past bouple of days:

 Code:

Too much memory for a single process:
129996 kb for (squid) -sYD
squid     2300  8.0  9.8 129996 50784 ?      R    Jan16 168:47 (squid) -sYD


Last WebAdmin login: ***** at Sun Jan 16 19:30:43 from 192.***.***.*** 
System Uptime      : 1 days 11 hours 42 minutes
System Load        : 0.10
System Version     : Astaro Security Linux  4.025
License            : Office Version     
Active IP Count    : 2 protected IPs

Please refer to the manual for detailed instructions.
 

 

Could anybody shed some light into this one?

Thanks


This thread was automatically locked due to age.
Parents
  • Squid is the HTTP proxy.
    You could try restarting the proxy.

    Barry
  • I have restarted the whole machine and the error persists.  I also tried emptying the cache.

    And, just for reference, how would I restart just HTTP Proxy?  Disabling and Enabling?
  • Disabling & Enabling...
    Yes

    You may need to edit the squid.conf file and lower the cache_mem setting, or adjust the config for the Too much memory alerter. (search the forums for how/where to do this, I don't remember atm.)

    Run free or top and see how much memory you have free to decide whether you need to reduce squid's memory or not.

    Barry
  • [ QUOTE ]

    You may need to edit the squid.conf file and lower the cache_mem setting, or adjust the config for the Too much memory alerter. (search the forums for how/where to do this, I don't remember atm.)

    Run free or top and see how much memory you have free to decide whether you need to reduce squid's memory or not.

    Barry 

    [/ QUOTE ]

    I'll check these out and report back...thanks...
  • I searched both squid.conf and suid,conf-defaul and couldn't find the cache_mem setting.  Tried  running free and top but got 'command not found' for both...

    Read some more posts on 'Too much memory' and found some info on logs...emptied the Squid logs to see if it makes a difference...
Reply
  • I searched both squid.conf and suid,conf-defaul and couldn't find the cache_mem setting.  Tried  running free and top but got 'command not found' for both...

    Read some more posts on 'Too much memory' and found some info on logs...emptied the Squid logs to see if it makes a difference...
Children
  • I don't have ASL 4 handy, but on 5.1, I've got 256MB RAM installed, and ASL has set it like this:
    cache_mem 16 MB

    Squid & the OS uses 3-4X the amount you set (due to buffers, filehandles, etc), so don't set it too high.

    You should put it in the squid.conf-default or it will get lost.

    How much RAM do you have?

    If you have enough RAM, just edit the watchdog config (sorry, don't remember where it is) and change the line for squid.

    Barry
  • I have 512MB and have set these items in squid.conf-default

    cache_mem 64 MB
    maximum_object_size 102400 KB
    maximum_object_size_in_memory 64 KB

    So far no WAR 102 emails...we'll see...

    Anybody else know where this watchdog config is?

    Thanks,
  • Not sure about 4.x, but on 3.x the config file you need to edit is
    /etc/wfe/conf/selfmonitoring

    on our 3.x box, under 
    procmem {
    there is a line which reads
            squid = 128000

    This should probably be somewhere around 128000 - 200000 if you've set squid to use 64MB.

    Barry
  • [ QUOTE ]
    This should probably be somewhere around 128000 - 200000 if you've set squid to use 64MB. 

    [/ QUOTE ]

    It is set now at 128000...

    Would that setting be enough or should I bump it up higher?

    BTW No WAR 102 errors yet...

    Thanks,
  • Well, IIRC, the squid docs say to expect up to 3X the memory you told squid to use, but it all depends on how busy it is I guess.

    If you're worried about it, increase it, otherwise see if you get any more emails.

    Barry
  • [ QUOTE ]
    Hi y'all...

    Haven't posted in a while but here it goes...

    I've been happily running 4.025 for a while now but I've been getting this error for the past bouple of days:

     Code:

    Too much memory for a single process:
    129996 kb for (squid) -sYD
    squid     2300  8.0  9.8 129996 50784 ?      R    Jan16 168:47 (squid) -sYD


    Last WebAdmin login: ***** at Sun Jan 16 19:30:43 from 192.***.***.*** 
    System Uptime      : 1 days 11 hours 42 minutes
    System Load        : 0.10
    System Version     : Astaro Security Linux  4.025
    License            : Office Version     
    Active IP Count    : 2 protected IPs

    Please refer to the manual for detailed instructions.
     

     

    Could anybody shed some light into this one?

    Thank 

    [/ QUOTE ]
    Squid is a hog..in v 4.025 and v5.1 it is a pig..[:)]  here are some mods i use in both 4.x and 5.x that put the caching load mostly on the hard disk instead of in main memory:

    to adjust max object size on disk and in mem:
    Login to your firewall using an ssh client (I use ZOC on windows but PuTTY I believe works just as well) using the "loginuser" ID.

    Once logged in "su" to root...
    ASL> su -
    Password: 

    Open the .conf file in "joe".
    ASL> joe /var/chroot-squid/etc/squid.conf-default

    As the above article suggests, look at the /var/chroot-squid/etc/reference-squid.conf file first since it has all the original annotations regarding the different options contained in the file.

    cache_mem
    Default cache_mem 8 MB
    (add this line without the word default and changethe 8 to zero)

    Default maximum_object_size 4096 KB
    Objects larger than this size will NOT be saved on disk. The value is specified in kilobytes, and the default is 4 MB
    (i jack this one way up..on my v5 setup i have this set to 200 megs on a 20 gig drive that uses a 6 gig storage partition)

    maximum_object_size_in_memory (bytes)
    Objects greater than this size will not be attempted to be kept in the memory cache. This should be set high enough to keep objects accessed frequently in memory to improve performance while, low enough to keep larger objects from hoarding cache_mem.
    Default maximum_object_size_in_memory 8 KB
    ( I make this one zero as well.  Between this one at zero and the cache mem at zero it reduces by at least 50%(maybe more) the amount of ram squid chews up.  I never noticed a huge performance hit from using the hdd as my primary cache even with a 3 meg connection to the internet.)

    These three changes alone will drastically reduce the amount of RAM squid takes up during caching.  The hard disk will have the load shifted to it as a result(which for me is what i was looking to do).  You can modify these values as you wish..but for 256 megs i would  use the above values.  Just my .02.

    Owner:  Emmanuel Technology Consulting

    http://etc-md.com

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

    PfSense w/Suricata, ntopng, 

    Other addons to follow

  • He's got 512mb (I've got 256mb)

    I run squid on another linux box, and it's well-behaved with about cache_mem = 64mb and a few users.

    If you're tight on memory, then yes, you need to restrict it more.

    Barry
  • [ QUOTE ]
    He's got 512mb (I've got 256mb)

    I run squid on another linux box, and it's well-behaved with about cache_mem = 64mb and a few users.

    If you're tight on memory, then yes, you need to restrict it more.

    Barry 

    [/ QUOTE ]
    quote fixed sorry barry..

    Owner:  Emmanuel Technology Consulting

    http://etc-md.com

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

    PfSense w/Suricata, ntopng, 

    Other addons to follow