LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 02-06-2009, 01:39 AM   #1
cjagdish69
Member
 
Registered: Oct 2003
Location: Bombay,Maharashtra,India
Posts: 60

Rep: Reputation: 15
Squid with SquidGuard working slow.


I have installed squid-2.6.STABLE6-3.el5(binary package installation) on centos as well as on RHEL5 alongwith the squidGuard-1.3(compiled from source) , db-4.7.25.

My squid is working very slow. Can you please suggest me the reason why the squid is going slow ?

Secondly on this server i have created only 3 users namely "chunky , internet & jagdish". Now in my lan most of the machines are accessing internet using proxy user "internet". In this case can i restrict the machines so that if one machine is accessing internet using proxy user "internet" then other machines should not access internet using the same proxy user. Is it possible ? If it is then how can it be achieved ?

Kindly guide me in this regard.
 
Old 02-06-2009, 08:25 AM   #2
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Northeast Ohio
Distribution: linuxdebian
Posts: 7,249
Blog Entries: 5

Rep: Reputation: 191Reputation: 191
Is there enough RAM in the system or is it swapping out to the Hard drive.?

Quote:
18.3.3. System Requirements

The most important thing is to determine the maximum load the system must bear. It is, therefore, important to pay more attention to the load peaks, because these might be more than four times the day's average. When in doubt, it would be better to overestimate the system's requirements, because having Squid working close to the limit of its capabilities could lead to a severe loss in the quality of the service. The following sections point to the system factors in order of significance.

18.3.3.1. Hard Disks

Speed plays an important role in the caching process, so this factor deserves special attention. For hard disks, this parameter is described as random seek time, measured in milliseconds. Because the data blocks that Squid reads from or writes to the hard disk will tend to be rather small, the seek time of the hard disk is more important than its data throughput. For the purposes of a proxy, hard disks with high rotation speeds are probably the better choice, because they allow the read-write head to be positioned in the required spot much quicker. Fast SCSI hard disks nowadays have a seek time of under 4 milliseconds.

One possibility to speed up the system is to use a number of disks concurrently or to employ striping RAID arrays.

18.3.3.2. Size of the Disk Cache

In a small cache, the probability of a HIT (finding the requested object already located there) is small, because the cache is easily filled so the less requested objects are replaced by newer ones. On the other hand, if, for example, 1 GB is available for the cache and the users only surf 10 MB a day, it would take more than one hundred days to fill the cache.

The easiest way to determine the needed cache size is to consider the maximum transfer rate of the connection. With a 1 Mbit/s connection, the maximum transfer rate is 125 KB/s. If all this traffic ends up in the cache, in one hour it would add up to 450 MB and, assuming that all this traffic is generated in only eight working hours, it would reach 3.6 GB in one day. Because the connection is normally not used to its upper volume limit, it can be assumed that the total data volume handled by the cache is approximately 2 GB. This is why 2 GB of disk space is required in the example for Squid to keep one day's worth of browsed data cached.

18.3.3.3. RAM

The amount of memory required by Squid directly correlates to the number of objects in the cache. Squid also stores cache object references and frequently requested objects in the main memory to speed up retrieval of this data. Random access memory is much faster than a hard disk.

In addition to that, there is other data that Squid needs to keep in memory, such as a table with all the IP addresses handled, an exact domain name cache, the most frequently requested objects, access control lists, buffers, and more.

It is very important to have sufficient memory for the Squid process, because system performance is dramatically reduced if it must be swapped to disk. The cachemgr.cgi tool can be used for the cache memory management. This tool is introduced in Section 18.3.7.1. “cachemgr.cgi”.

18.3.3.4. CPU


Squid is not a program that requires intensive CPU usage. The load of the processor is only increased while the contents of the cache are loaded or checked. Using a multiprocessor machine does not increase the performance of the system. To increase efficiency, it is better to buy faster disks or add more memory.

Last edited by farslayer; 02-06-2009 at 08:28 AM.
 
  


Reply

Tags
squid, squidguard



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
squidguard is not working with squid proxy ssilayaraja Linux - Server 5 12-06-2010 06:52 PM
squid conf: squid failed when I type insert redirect_program /usr/bin/squidguard laxmantsharma Linux - Software 1 02-24-2009 06:02 AM
Squid And Squidguard SBN Linux - Software 1 07-27-2006 05:21 AM
squid and squidguard metallica1973 Linux - Networking 5 12-07-2005 10:23 AM
squid conf: squid failed when I type insert redirect_program /usr/bin/squidguard Niceman2005 Linux - Software 1 11-24-2004 02:29 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 09:22 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration