Search squid archive

Re: HTTP performance hit with Squid

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

 



I am using Squid version 3.1.20 running on Intel I7 processor with 16GB RAM. Even on connecting a single client I could able to reproduce this problem.

2015/10/22 20:34:23.146| ipcache_nbgethostbyname: Name 'mail.com'.   <<<<<<<<<<<<<<<<<<<<<<<<<<<< DNS start time
2015/10/22 20:34:23.146| ipcache_nbgethostbyname: MISS for 'mail.com'
2015/10/22 20:34:23.146| cbdataLock: 0x7f9c3f4ca628=2
2015/10/22 20:34:23.146| idnsALookup: buf is 26 bytes for mail.com, id = 0x7a4f
2015/10/22 20:34:23.146| cbdataLock: 0x7f9c3f46df28=1
2015/10/22 20:34:23.146| comm_udp_sendto: Attempt to send UDP packet to 8.8.8.8:53 using FD 8 using Port 46787
2015/10/22 20:34:23.146| event.cc(343) schedule: schedule: Adding 'idnsCheckQueue', in 1.00 seconds
2015/10/22 20:34:23.146| StoreEntry::unlock: key '0F71D6DA8407C509D35DA6ADB5BD52BD' count=2

2015/10/22 20:34:24.114| idnsRead: FD 8: received 84 bytes from 8.8.8.8:53
2015/10/22 20:34:24.114| idnsGrokReply: ID 0x7a4f, 0 answers
2015/10/22 20:34:24.114| idnsGrokReply: mail.com has no AAAA records. Looking up A record instead.
2015/10/22 20:34:24.114| comm_udp_sendto: Attempt to send UDP packet to 8.8.8.8:53 using FD 8 using Port 46787
2015/10/22 20:34:24.114| comm_udp_recvfrom: FD 8 from 8.8.8.8:53
2015/10/22 20:34:25.064| idnsRead: FD 8: received 226 bytes from 8.8.8.8:53
2015/10/22 20:34:25.064| idnsGrokReply: ID 0xe9c1, 1 answers
2015/10/22 20:34:25.065| dns_internal.cc(1152) idnsGrokReply: Sending 1 DNS results to caller.  <<<<<<<<<<<<<<<<<<<<<<<<<<<  DNS end time

It looks like almost 2 seconds spent in resolving  DNS for an URL. I guess it could be the reason. Also it tries for IPv6 first even i configured dns_v4_first option.
It looks bad. Suppose if an URL has many embedded pages a delay of 2 second is added to total page load time for each embedded page request.  

Regards,
Saravanan N

On Thu, Oct 22, 2015 at 3:54 PM, Eliezer Croitoru <eliezer@xxxxxxxxxxxx> wrote:
What version of squid are you using now?
Squid 3.1.20 is very old and it is recommended to use newer versions.
If you are having specific troubles I think you figure out the issues pretty fast.
What hardware are you using for you squid? is it a VM? RAM? CPU?Disk?
How many clients? Have you used the squid cache manager interface?

My first suggestion it to try and use squid 3.4.14 just to make sure you are on something more current then 3.1.20.

Eliezer

On 22/10/2015 21:47, SaRaVanAn wrote:
Hi ,
we have been using squid 3.1.20 comes with debian wheezy 7. We could see
there is a peformance hit in http traffic when we use Squid.

For each HTTP GET request coming from client to proxy server, Squid takes
nearly 2 seconds to generate HTTP GET in order to establish a connection
with server.

There is always a ~2 second delay between the request coming to our system
and going out of Squid. Suppose if a page has lot of embedded URL's it's
taking more time with squid in place.Suppose If I disable squid the page
loads very fast in client browser.

What could be the reason? Do I need to tweak any configuration for this?
The first page request always loads slow with Squid.


*Configuration*http_port 3128

http_port 3129 tproxy
http_port 80 accel defaultsite=example.com
acl manager proto cache_object
acl localhost src 127.0.0.1/32 ::1
acl to_localhost dst 127.0.0.0/8 0.0.0.0/32 ::1
acl QUERY urlpath_regex cgi-bin \?
cache deny QUERY
acl denied_status_404 http_status 404
deny_info  http://example.com/ denied_status_404
http_reply_access deny denied_status_404
acl denied_status_503 http_status 503
deny_info http://example.com denied_status_503
http_reply_access deny denied_status_503
acl SSL_ports port 443
acl Safe_ports port 80
acl Safe_ports port 21
acl Safe_ports port 443
acl Safe_ports port 70
acl Safe_ports port 210
acl Safe_ports port 1025-65535
acl Safe_ports port 280
acl Safe_ports port 488
acl Safe_ports port 591
acl Safe_ports port 777
acl CONNECT method CONNECT
acl PURGE method PURGE
http_access allow PURGE localhost
http_access deny PURGE
http_access allow manager localhost
http_access deny manager
http_access deny !Safe_ports
http_access deny CONNECT all
http_access allow all
icp_access allow all
tcp_outgoing_address x.y.z.5
acl VIDEO  url_regex ^http://example\.examplevideo\.com
cache allow VIDEO
cache_mem 100 mb
maximum_object_size_in_memory 10 kb
memory_replacement_policy heap LFUDA
cache_replacement_policy heap LFUDA
cache_dir aufs //var/logs/cache 6144 16 256
store_dir_select_algorithm round-robin
maximum_object_size  51200 kb
cache_swap_low 70
cache_swap_high 80
access_log //var/logs/access.log squid
cache_store_log none
logfile_rotate 1
mime_table //var/opt/abs/config/acpu/mime.conf
pid_filename /var/run/squid3.pid
  strip_query_terms off
cache_log //var/logs/cache.log
coredump_dir //var/cache
acl apache rep_header server ^apache
refresh_pattern -i ^http://.wsj./.* 10 200% 10 override-expire
override-lastmod reload-into-ims ignore-reload
refresh_pattern -i \.(gif|png|jpg|jpeg|ico)$ 480 100% 480 override-expire
override-lastmod reload-into-ims
refresh_pattern -i \.(htm|html|js|css)$ 480 100% 480 override-expire
override-lastmod reload-into-ims
refresh_pattern ^ftp:       1440    20% 10080
refresh_pattern ^gopher:    1440    0%  1440
refresh_pattern -i (/cgi-bin/|\?) 0 0%  0
refresh_pattern .       0   20% 4320
quick_abort_min 0 kb
quick_abort_max 0 kb
negative_ttl 1 minutes
positive_dns_ttl 1800 seconds
store_objects_per_bucket 100
forward_timeout 2 minutes
shutdown_lifetime 2 seconds
visible_hostname x.y.z.3
server_persistent_connections off
dns_nameservers x.y.z.1 x.y.z.2
ipcache_size 8192
fqdncache_size 8192
memory_pools off

Regards,

Saravanan N



_______________________________________________
squid-users mailing list
squid-users@xxxxxxxxxxxxxxxxxxxxx
http://lists.squid-cache.org/listinfo/squid-users


_______________________________________________
squid-users mailing list
squid-users@xxxxxxxxxxxxxxxxxxxxx
http://lists.squid-cache.org/listinfo/squid-users

_______________________________________________
squid-users mailing list
squid-users@xxxxxxxxxxxxxxxxxxxxx
http://lists.squid-cache.org/listinfo/squid-users

[Index of Archives]     [Linux Audio Users]     [Samba]     [Big List of Linux Books]     [Linux USB]     [Yosemite News]

  Powered by Linux