轉載 http://www.cnblogs.com/xyd21c/archive/2012/12/19/2825314.html
讀取錯誤
錯誤描述:(60)Operation timed out
現象:某些網站無法打開(比如google.com.hk),或開始能夠打開部分內容但頁面刷新幾次後反而無法打開,提示“讀取錯誤”
解決方法:squid.conf配置文件中的 acl allowmax maxconn 30,將最大連接數設置大一點,網頁無法打開的原因,可能是因爲網頁包含的資源文件太多,超過了最大的連接數。
訪問被拒絕
當嘗試取回該 URL 時遇到下面的錯誤:http://www.163.com/
訪問被拒絕。
Access control configuration prevents your request from being allowed at this time. Please contact your service provider if you feel this is incorrect.
緩存服務器的管理員 [email protected].
解決方法
1、代理服務器機器的DNS配置問題,代理服務器機器不能找到指定url的ip地址導致。檢查/etc/resolv.conf文件配置是否正確,如不正確添加正確的配置信息,比如說:
nameserver ###.###.###.###
nameserver ###.###.###.###
可以配置多個DNS server。
重新啓動squid服務。
2、訪問控制http_access allow all
無法進行轉送操作
當嘗試取回該 URL 時遇到下面的錯誤:http://ip/
目前無法將您的請求進行轉送操作
This request could not be forwarded to the origin server or to any parent caches. The most likely cause for this error is that the cache administrator does not allow this cache to make direct connections to origin servers, and all configured parent caches are currently unreachable.
參考:http://home.arcor.de/pangj/squid/chap10.html
檢測squid.conf配置 squid -k parse 報錯
WARNING: Netmasks are deprecated. Please use CIDR masks instead.
2010/10/31 21:39:41| WARNING: IPv4 netmasks are particularly nasty when used to compare IPv6 to IPv4 ranges.
2010/10/31 21:39:41| WARNING: For now we will assume you meant to write /28
2010/10/31 21:39:41| WARNING: Netmasks are deprecated. Please use CIDR masks instead.
2010/10/31 21:39:41| WARNING: IPv4 netmasks are particularly nasty when used to compare IPv6 to IPv4 ranges.
2010/10/31 21:39:41| WARNING: For now we will assume you meant to write /28
解決方法
將配置文件中的192.168.1.0/255.255.255.0 改爲 192.168.1.0/24 形式就OK了。
squid緩存目錄沒有權限
2004/11/01 23:06:29| Creating Swap Directories
FATAL: Failed to make swap directory /Cache1/00: (13) Permission denied
Squid Cache (Version 2.5.STABLE7): Terminated abnormally.
CPU Usage: 0.000 seconds = 0.000 user + 0.000 sys
Maximum Resident Size: 0 KB
Page faults with physical i/o: 10
解決方法:
/Cache1目錄權限錯誤,請檢查/Cache1目錄所有者是否爲squid用戶所有