聊一下squid

126 views
Skip to first unread message

autumnwind0131

unread,
Oct 7, 2014, 11:43:56 PM10/7/14
to osa...@googlegroups.com
最近遇到一個大麻煩,原因是花蓮縣網限制每一個IP的連線數只能512,
對於我要利用iptabels+squid做通透代理來說,真是我的媽阿,全校連線
速度很慢。

網路上找了一下終於發現有個設定tcp_outgoing_address可以設定來源IP從哪個IP出去
也發現了即便利用squid也可以顯現內部IP
forwarded_for 這個設定必須要打開,但要改成forwarded_for transparent
如果設定forwarded_for off 碰到有查IP的ASP網頁會打不開

花蓮網路真是惠我良多。

willie

unread,
Oct 8, 2014, 12:02:37 AM10/8/14
to osa...@googlegroups.com
所以花蓮縣各學校都是直接使用 public ip,沒有用 NAT?

我自己學校上學期有架了 proxy,transparent mode 和 bridge mode 我都有用過

但我觀察防火牆的流量紀錄,發現其實用了 proxy 對降低流量似乎有限?

我是還沒空去統計到底目標網站的排行,但我猜測也許原因是 facebook / google 這類流量大的網站都已經強制跑 SSL 的緣故?

你們學校用 proxy 之前和之後流量與連線數量有差很多嗎?我很好奇
> --
> 這是 Google 網上論壇針對「Open Source At Taiwan For Education」群組發送的訂閱通知郵件。
> 如要取消訂閱這個群組並停止接收來自這個群組的郵件,請傳送電子郵件到 osatfe+un...@googlegroups.com
> 如需更多選項,請前往:https://groups.google.com/d/optout

autumnwind0131

unread,
Oct 8, 2014, 12:30:44 AM10/8/14
to osa...@googlegroups.com
我是用bandwidthd來監控流量的,因為我沒有設快取,且校內老師瀏覽網頁次數不像台北那麼多,
比較使用前後流量和連線數,感受也不明顯。因為全校老師少,整體的連線數之前測大概六百多。

像我學校就只有1/4C網段的public ip,但教育處另外給每個學校4個C網段的private ip
因此一般電腦都是走private ip出去

而我們學校之前是要求縣府開放一個不受限的IP,就無視連線數了,但在上個月,全花蓮縣網被癱瘓,
管理者又重新限制了,我才變得很頭痛。


William Wu於 2014年10月8日星期三UTC+8下午12時02分37秒寫道:

謝勝任 [實習處職員]

unread,
Oct 5, 2015, 11:33:55 PM10/5/15
to Open Source At Taiwan For Education
請教各位高手
目前小弟負責的學校安裝好squid後
否些網站會出現以下訊息
還請各位前輩指導一夏

ERROR

The requested URL could not be retrieved


While trying to retrieve the URL: http://www.pchome.com.tw/

The following error was encountered:

  • Unable to forward this request at this time.

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.

Your cache administrator is webmaster


Generated Tue, 06 Oct 2015 03:27:43 GMT by ProxyServer (squid/2.7.STABLE8)

autumnwind0131

unread,
Oct 6, 2015, 1:21:19 AM10/6/15
to Open Source At Taiwan For Education
http://www.cnblogs.com/pipc/archive/2009/11/16/1603388.html

參考一下連結試試。

謝勝任 [實習處職員]於 2015年10月6日星期二 UTC+8上午11時33分55秒寫道:

謝勝任 [實習處職員]

unread,
Oct 6, 2015, 4:33:47 AM10/6/15
to Open Source At Taiwan For Education
感謝您的協助
我試試看

autumnwind0131於 2015年10月6日星期二 UTC+8下午1時21分19秒寫道:

willie

unread,
Oct 6, 2015, 10:00:34 AM10/6/15
to 謝勝任 [實習處職員], Open Source At Taiwan For Education
 要大家幫忙找問題,光是這個訊息還不夠,需要您將 squid 的 log 貼出來,才會知道真正的問題發生原因喔

--
Reply all
Reply to author
Forward
0 new messages