- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Re: recommended size cache_mem
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-07-2007 12:04 AM
тАО09-07-2007 12:04 AM
what would be the recommended size of cache_mem in squid.conf on a dedicated Gateway Server(squid2.6, and iptables), having 1 Gig DDR2 RAM ?
On a 20 users network, What would be the recommended size of hard drive cache size(cache_dir ufs /path/to/cache_dir SIZE 16 256) in squid.cong on a dedicated Gateway Server(squid2.6, and iptables), having 1 Gig DDR2 RAM ?
Regards
Maaz
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-07-2007 12:28 AM
тАО09-07-2007 12:28 AM
Re: recommended size cache_mem
If the server id dedicated for one purpose, squid, you should max out the memory setting.
Here is how I'd calculate.
Start the server. Shut off squid.
free
Leave a few hundred meg, say 200 free for user processes and give the rest to squid. Don't push the system to the point where it pages processes in and out of swap.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-07-2007 03:57 AM
тАО09-07-2007 03:57 AM
Solution>>> As a rule of thumb on Squid uses approximately 10 MB of RAM per GB of the total of all cache_dirs (more on 64 bit servers such as Alpha), plus your cache_mem setting and about an additional 10-20MB. It is recommended to have at least twice this amount of physical RAM available on your Squid server.
So, if you have 1 GB RAM, squid should be configured to use about 500 MB (OS normally uses very small amount of memmory).
The cache_dir depends of your available space, and for each GB, 10 MB or RAM is used.
So, the formula should be:
((cache_dir/1024) * 10 MB ) + cache_mem MB + 20 MB <= 500 MB
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-11-2007 05:58 PM
тАО09-11-2007 05:58 PM
Re: recommended size cache_mem
Ok, cache_mem is 300 now, and cache_dir is 2000(2 GB).
another issue, now when I run free -m I found memory usage 679 MB, and this machine is a dedicated Gateway machine and on the average with only 10 users simultaneously connected to the internet, but when I run top,
1, i dont find squid in the list.. why ?
95% of processes thats in the list(top output) consumes only the 0.0 %MEM, and only 2 or 3 process consumes 1.x or 3.x %MEM.
2, then why "free -m" shows MEM used as 679 MB, as per the output of top it should be very less ?
3, whats the proper way of checking which process is consuming/using how much MEM ?
Regards
Maaz
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-11-2007 06:02 PM
тАО09-11-2007 06:02 PM
Re: recommended size cache_mem
Regards
Maaz
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-11-2007 08:13 PM
тАО09-11-2007 08:13 PM
Re: recommended size cache_mem
ps -elf | grep squid
The 10th column is your memory usage in kilobytes.
In top, you can sort by memory usage by using 'M' (not m). This should also show you 'squid' near the top.
As for question 2, the memory 'used' in top is the same as the memory 'used' in free. These values are grabbed from '/proc/meminfo'. The tools just format it differently.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-11-2007 10:41 PM
тАО09-11-2007 10:41 PM
Re: recommended size cache_mem
I ran the following command
# ps -elf |grep squid
1 S root 2363 1 0 76 0 - 2987 wait 08:21 ? 00:00:00 /etc/init.d/squid start
4 S nobody 3259 2363 0 76 0 - 5594 - 08:21 ? 00:00:05 (squid) start
as per the output ( 2987 + 5594 = 8581 ) and then ( 8581 / 1000 = 8 MB ) its clear that squid is using only 8 MB isn't ?
then which process/software is using 679 MB of Memory on this dedicated Gateway server ?
top also doesnt show me any memory hungry process, so who is using 679-715 MB memory
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-11-2007 10:59 PM
тАО09-11-2007 10:59 PM
Re: recommended size cache_mem
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-11-2007 11:13 PM
тАО09-11-2007 11:13 PM
Re: recommended size cache_mem
ok, one more thing bind is also running on this machine as a cache-only server, and bind is also not visible in top output .. why ?
Regards
Maaz
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-12-2007 03:58 AM
тАО09-12-2007 03:58 AM