Linux中国  设为主页
 收藏本站
 
当前位置: > 首页 ->Linux技术 ->服务器相关 ->服务器squid 2.5 stable快速安装指南
  相关分类: 
入门与提高
系统管理
网络应用
嵌入式系统
内核研究
服务器相关
发行版专区
Linux程序设计
Linux安全
BSD相关
桌面应用
  站内搜索: 
热门文章排行
热门文章排行 手把手教您配置Linux目录服务器(04-11)
Linux系统上vpn的服务端和客户端配置(04-11)
Linux系统下代理服务器安装调试一例(04-11)
Samba使Linux成为“文件服务器”(一)(04-11)
手把手教您配置Liunx目录服务器(04-11)
精采文章排行
精采文章排行 增加Apache最大连接数的方法详细介绍(04-20)
PHP站点用Squid再次疯狂加速你的WEB (04-20)
怎么样使用Rsh/Tar快速克隆Linux服务(04-11)
怎么样把Linux服务器当作Mac的服务器(04-11)
Linux系统下代理服务器安装调试一例(04-11)
  ·增加Apache最大连接数的方法详细介绍 ·Linux系统的服务器攻防技术详细介绍·Linux系统上vpn的服务端和客户端配置·在RHEL4上的日志服务器配置案例解析·Apache配置文件里的LogLevel指令介绍·Linux系统上架设VSFTP服务器实例解析·Linux Apache服务器系统的设置与优化·Linux操作系统下怎么样配置DHCP服务器·在Linux系统下面架设Sendmail服务器

服务器squid 2.5 stable快速安装指南

作者:   来源:   点击:   日期:2007-04-11 [收藏] [投稿]

  IE是否经常中毒?推荐您

squid 2.5 stable快速安装指南

阿土/Aborigen Yin

http://www.bsdbase.com

目标:在网关上为内网提供普通代理以及透明代理服务,以ip地址为访问控制条件,不需要其他访问控制。

#安装

#如果是FreeBSD,建议安装如下ports:

cd /usr/ports/devel/autoconf

make clean

make install clean

cd /usr/ports/devel/automake

make clean

make install clean

#首先,配置好你的网络,保证安装squid的主机能正常上网;

ping www.163.com

#用域名是为了测试DNS解析;

#以下以root身份执行。

#获得最新stable源码

http://www.squid-cache.org

mkdir -p /usr/local/src/distfiles

cd /usr/local/src/distfiles

#FreeBSD

fetch http://www.squid-cache.org/Versions/v2/2.5/squid-2.5.STABLE1.tar.gz

#Linux

wget http://www.squid-cache.org/Versions/v2/2.5/squid-2.5.STABLE1.tar.gz

tar xfz squid-2.5.STABLE1.tar.gz -C ..

cd ../squid-2.5.STABLE1

./configure --prefix=/usr/local/squid

make

make install

#权限改变是必要的;参考squid.conf

#cache_effective_user nobody

#cache_effective_group nobody

#默认使用

chown -R nobody:nobody /usr/local/squid/var

#按照你的需要配置;

#vi /usr/local/squid/etc/squid.conf

# TAG: http_port

# Usage: port

# hostname:port

# 1.2.3.4:port

#Default:

# http_port 3128

http_port 60080

#逃避讨厌的代理扫描,使用一个自定义的端口;

#设置不代理的url,一些动态网页,比如江湖、聊天室。

# TAG: no_cache

# A list of ACL elements which, if matched, cause the request to

# not be satisfied from the cache and the reply to not be cached.

# In other words, use this to force certain objects to never be cached.

#

# You must use the word 'DENY' to indicate the ACL names which should

# NOT be cached.

#

#We recommend you to use the following two lines.

acl QUERY urlpath_regex cgi-bin \? asp php shtml php3 cgi

no_cache deny QUERY

# ACCESS CONTROLS

# -----------------------------------------------------------------------------

# TAG: acl

# Defining an Access List

#

# acl aclname acltype string1 ...

# acl aclname acltype "file" ...

#

# when using "file", the file should contain one item per line

#定义内网(假设有172.16.0.0/16;192.168.0.0/16;10.0.0.0/8);

acl lan-a src 172.16.0.0/16

acl lan-b src 192.168.0.0/16

acl lan-c src 10.0.0.0/8

#squid的默认配置是拒绝所有连接;

#Default:

# http_access deny all

#

#对上述内网地址开放

http_access allow lan-a

http_access allow lan-b

http_access allow lan-c

#Recommended minimum configuration:

#



 如果您对本文有任何疑问或者建议,请到讨论区发表您的意见: >> 论坛入口 <<

上一页12 下一页

上一篇:Linux服务器架设:我的CACTI--FAQ   下一篇:怪!SCO专家在服务器上允许Linux系统?
文章评论】 【收藏本文】 【推荐好友】 【打印本文】 【我要投稿】 【论坛讨论

   相关文章:
·PHP站点用Squid再次疯狂加速你的WEB

   文章评论:(2条)
  
 请留名: 匿名评论   点击查看所有评论 论坛讨论
 

 声明:刊登此文章是为了传递更多信息,文章内容仅供参考,转载请注明出处。