Re: Mod_proxy problem in 2.2.4

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 5/31/07, Pavel Mateja <pavel@xxxxxxxxxx> wrote:
> But the disk cache often has better performance than the memory cache
> even on a normal disk. There are two reasons for this:
>
> 1. The disk cache is shared between all processes, while the mem cache
> must keep copies of each object for each processes.
>
> 2. The disk cache takes full advantage of your OSes buffer caches and
> zero-copy networking. If you have enough memory, then frequently
> accessed stuff from the disk cache is going to be kept in memory by
> your OS. And instead of apache having to handle all the
> synchronization itself, it will all be handled in the kernel where it
> is the most efficient.

I know all of this. But our application has cca 10M hits per day per proxy and
we are trying to cache cca 3GB of images in 200MB of RAM (rest of 1GB is
consumed by apache and iptables) to save some traffic. No harddisk known to
me can really handle this.

Some definite miscommunication going on here.

The hard disk doesn't need to handle it, because any
frequently-requested object is going to wind up in the OS buffer cache
(in memory). If you used mem_cache, performance could be worse because
you'll have many copies of the same object in memory (one for each
process) whereas with disk_cache, the OS is smart enough to maintain
just one copy.

If you don't have enough memory for the OS to maintain the important
stuff in the buffer cache, then mem_cache isn't going to help because
it will just shove other important stuff out of memory and onto disk.

Joshua.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
  "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux