[squid-users] swap.state growing large

From: Chris Wilson <chris@dont-contact.us>
Date: Tue, 17 Feb 2004 15:10:35 +0000 (GMT)

Hi all,

I'm trying to configure Squid to run on machines with no writable
permanent storage (just a ramdisk) and little memory. I've allocated a
4Mb ramdisk for the Squid cache. Ideally I would like to disable disk
caching entirely and have Squid only use RAM, but I haven't figured out
how to do that yet.

It has been working very well under light usage, however today Squid
stopped working due to insufficient disk space on the ramdisk. When I
investigated, I found that swap.state was using almost all the 4Mb space.

The current swap configuration is:

  cache_mem 1 MB
  maximum_object_size 1024 KB
  cache_dir ufs /cache 2 4 16

  (most other options are left at defaults).

which I hoped would be enough to keep the cache small. Indeed, the cache
dirs themselves don't get too big, but the size of swap.state is a real
problem.

Does this file normally grow without bounds, and if so, can it be avoided
in any way? I would rather lose performance than risk having Squid crash,
or being forced to restart it regularly.

I found some articles which seem related:

* Joe Cooper asked if it was possible to run without a swap.state file,
  and nobody replied directly as far as I can see:
  [http://www.squid-cache.org/mail-archive/squid-dev/200111/0057.html]

* Dancer thinks that swap on tmpfs is not a good idea, but doesn't say
  why: [http://www.squid-cache.org/mail-archive/squid-users/199912/0455.html]

Thanks in advance for your help,

Cheers, Chris.

-- 
_  __ __     _
 / __/ / ,__(_)_  | Chris Wilson -- UNIX Firewall Lead Developer |
/ (_  ,\/ _/ /_ \ | NetServers.co.uk http://www.netservers.co.uk |
\__/_/_/_//_/___/ | 21 Signet Court, Cambridge, UK. 01223 576516 |
Received on Tue Feb 17 2004 - 08:54:41 MST

This archive was generated by hypermail pre-2.1.9 : Mon Mar 01 2004 - 12:00:02 MST