LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 06-16-2015, 04:01 AM   #1
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 22,122

Rep: Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371
squid does not want to use cache


So yes, probably it is my fault. The test case is:
Code:
export http_proxy=localhost:3128
export https_proxy=localhost:3128
wget -O /dev/null https://some_host/deb/ubuntu/dists/precise/Contents-amd64.gz
wget connects to proxy and downloads the file (that is located on an internal server) and access.log contains:
Code:
  2015-06-16T10:45:00.834  13880 127.0.0.1 TCP_MISS/200 22314945 CONNECT some_host:443 - HIER_DIRECT/a.b.c.d -
(obviously a.b.c.d is the ip of some_host)

grep '^[^ #]' squid.conf:
Code:
acl SSL_ports port 443
acl Safe_ports port 80		# http
acl Safe_ports port 21		# ftp
acl Safe_ports port 443		# https
acl Safe_ports port 70		# gopher
acl Safe_ports port 210		# wais
acl Safe_ports port 1025-65535	# unregistered ports
acl Safe_ports port 280		# http-mgmt
acl Safe_ports port 488		# gss-http
acl Safe_ports port 591		# filemaker
acl Safe_ports port 777		# multiling http
acl Safe_ports port 3128
acl CONNECT method CONNECT
http_access allow all                   <= that was inserted by me, but no effect anyway
http_access deny !Safe_ports
http_access allow localhost manager
http_access deny manager

acl our_lan src XX.YY.1.1/16     <= our local network
http_access allow our_lan

http_access allow localhost
http_access deny all
http_port 127.0.0.1:3128
https_port 127.0.0.1:3128
cache_mem 16 GB
cache_dir aufs /squid3/cache 10240 16 256 max-size=100G
maximum_object_size 40 GB
logformat squid %{%Y-%m-%dT%H:%M:%S}tl.%03tu %6tr %>a %Ss/%03>Hs %<st %rm %ru %[un %Sh/%<a %mt
cache_store_log stdio:/var/log/squid3/store.log
coredump_dir /var/spool/squid3
refresh_pattern . 3600  50% 864000
squidgard is not installed (if that counts).
Actually I want to cache huge files (> GB) but nothing was put into the cache, and I have no idea what's wrong.
 
Old 06-16-2015, 07:30 AM   #2
wildwizard
Member
 
Registered: Apr 2009
Location: Oz
Distribution: slackware64-14.0
Posts: 875

Rep: Reputation: 282Reputation: 282Reputation: 282
Remove the max-size directive from the cache_dir line and try again.
 
1 members found this post helpful.
Old 06-19-2015, 03:27 AM   #3
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 22,122

Original Poster
Rep: Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371Reputation: 7371
thanks guy, there were 3 problems:
squid does not handle ssl by default, should be recompiled
there is a bug related to this issue: http://serverfault.com/questions/464...store-my-image
and finally your tip helped....
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Pleassssssss .. I need Help with installing a good squid web cache OR lusca web cache ahmedeqaby Linux - Software 2 02-07-2012 07:56 AM
[SOLVED] squid cache parashuram2011 Linux - Networking 3 08-28-2011 11:27 PM
Using Active directory Authentication of parent non-squid cache to child squid cache espiya7 Linux - Server 0 05-05-2009 08:04 AM
squid just as cache abd_bela Debian 1 01-21-2009 06:21 AM
squid cache JJX Linux - Server 2 07-01-2007 10:12 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 10:26 AM.

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