LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 831|回复: 5

急,squid代理

[复制链接]
发表于 2003-6-2 16:50:16 | 显示全部楼层 |阅读模式
哪路高手,首先我 想说一下我的 问题,我 在 LINUX下用squid代理上网,客户机可以和主机的两个网卡 ,ping通,squid也可以正常起动,主机可以上网,但是客户机还是不能通过代理上网,我想请问一下这是什么原因,希望能给出我具体的原因和解决方法
etho :192.168.0.245 /24  gw 192.168.0.1
eth1:192.168.19.23/24    gw  192.168.0.245
我还想问一下内部网的dns怎么设置,是不是和\外部网的dns设置一样?谢谢!
发表于 2003-6-2 20:44:18 | 显示全部楼层

你配置squid.conf这个文件了吗?

我的/etc/squid/squid.conf
*************************************************************************
http_port 3128
icq_port  3130
htco_port 4827
cache_mem 84 MB
cache_swap_high 95
cache_swap_low 90
maximum_object_size 4096 KB
cache_dir ufs /var/spool/squid 1000(mb) 16 256
cache_access_log /var/log/squid/access.log
cache_log           /var/log/squid/cache.log
cache_store_log  /var/log/squid/store.log
acl        all src .0.0.0.0/0.0.0.0
acl         mynet        src 10.3.0.0/255.255.0.0
acl         enablednet        src 10.3.3.0/255.255.0.0
acl localhost src 127.0.0.1/255.255.255.255
acl        denysite        dst        "/etc/squid/denysite.txt"

acl SSL_ports port 443 563
acl Safe_ports port 80                # http
acl Safe_ports port 21                # ftp
acl Safe_ports port 443 563        # https, snews
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 CONNECT method CONNECT
http_access deny all
http_access allow enablednet
http_access allow localhost
http_access deny !Safe_ports
http_reply_access allow all
icq_access allow all
cache_mgr aaniu@supercap.com

# 如果是Transparent Proxy(透明代理) 的設定(加入下面的内容)
# -----------------------------------------------------------------------------
httpd_accel_poprt 80
httpd_accel_host virtual        virtual
httpd_accel_with_proxy on
httpd_accel_user_host_header on
**********************************************************************
要在客户机的浏览器里设代理的,我这http是3128
dns和外部网的dns设置一样就好!
发表于 2003-6-2 22:32:39 | 显示全部楼层

用squid好像只需要设置网关

以及代理ip及端口吧。dns可以不用吧。
发表于 2003-6-3 00:02:20 | 显示全部楼层
是不是用必须要有两张网卡才能实现?
有单网卡实现代理的软件吗?
发表于 2003-6-3 00:49:39 | 显示全部楼层

可以用一块网卡!

做成alias
发表于 2003-6-3 12:14:18 | 显示全部楼层
Howto?
您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表