Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
i have installed squid and i configured it but i want to know if i have to put the ip address of the server in http_port option or not ? i made it with the port only 8080 that is enough ?
and how can i measure the performance of the squid ?..
You don't need the IP address. In mine, I have: http_port 3128
Performance in what way? Are you trying to see if your users have reduced access times for pages in the cache? Are you checking whether your overall network bandwidth usage is less?
thanx for your replay u used port : http_port 3128 but i use 8080 that makes different
simply i said that i want to make http caching to cache the requested pages for the users on the web server how that could be done ? and how i determine the performance of caching process
If you want squid to be transparent to your clients bind it only at 127.0.0.1
Code:
http_port 127.0.0.1:3128 transparent
If you want it non-transparent, bind it at your gateway's internal NIC's IP. I'm sure to be prudent, we don't want squid as well running on our gateway's external/public NIC.
Squid automatically store objects on its cache, both in RAM and disk and to achieve performance, you can tune it and it's self documented in the squid.conf or you may refer to squd-cache.org WiKi.
Code:
# TAG: cache_mem (bytes)
# NOTE: THIS PARAMETER DOES NOT SPECIFY THE MAXIMUM PROCESS SIZE.
# IT ONLY PLACES A LIMIT ON HOW MUCH ADDITIONAL MEMORY SQUID WILL
# USE AS A MEMORY CACHE OF OBJECTS. SQUID USES MEMORY FOR OTHER
# THINGS AS WELL. SEE THE SQUID FAQ SECTION 8 FOR DETAILS.
#
# 'cache_mem' specifies the ideal amount of memory to be used
# for:
# * In-Transit objects
# * Hot Objects
# * Negative-Cached objects
#
# Data for these objects are stored in 4 KB blocks. This
# parameter specifies the ideal upper limit on the total size of
# 4 KB blocks allocated. In-Transit objects take the highest
# priority.
#
# In-transit objects have priority over the others. When
# additional space is needed for incoming data, negative-cached
# and hot objects will be released. In other words, the
# negative-cached and hot objects will fill up any unused space
# not needed for in-transit objects.
# If circumstances require, this limit will be exceeded.
# Specifically, if your incoming request rate requires more than
# 'cache_mem' of memory to hold in-transit objects, Squid will
# exceed this limit to satisfy the new requests. When the load
# decreases, blocks will be freed until the high-water mark is
# reached. Thereafter, blocks will be used to store hot
# objects.
#
#Default:
# cache_mem 8 MB
An accelerator caches incoming requests for outgoing data (i.e., that which you publish to the world). It takes load away from your HTTP server and internal network. You move the server away from port 80 (or whatever your published port is), and substitute the accelerator, which then pulls the HTTP data from the "real" HTTP server (only the accelerator needs to know where the real server is). The outside world sees no difference (apart from an increase in speed, with luck).
If it would accelerate a public web server accessed from outside, this is a reverse proxy or http accelerator and it uses the standard http port 80.
Then if its to accelerate or cache in http requests going outside to the internet from within a local network, this is a forward proxy that normally uses port 3128.
you are very helpful and the last thanks question iam going to set up the squid on my web server so itis better to make the ip of the option http_port = 127.0.0.1 or the ip of the server
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.