专注云计算教学
新手上云第一站

在 CentOS 7 系统里安装 squid

— 本帖被 不靠谱贝贝 设置为精华(2017-11-20) —
云友“bouyei”等在帖子 里问到,所以实践了一下。

环境:轻量云服务,CentOS 7.3

过程:

  1.     yum update # 更新
  2.     yum install squid # 安装 squid
  3.     vi /etc/squid/squid.conf # 编辑 squid 的配置文件,将默认的 3128 端口替换成其它,如 3888,http_port 3888,且在添加上用户的IP地址,允许访问 squid,如 acl localnet src x.x.x.x/32
  4.     systemctl restart squid # 重启 squid 服务
  5.     systemctl stop firewalld # 停止 CentOS 7 的默认防火墙服务
  6.     在阿里ECS实例安全组规则里,放行相应的端口,如本例的 3888 端口

  7.     在用户的浏览器里填写相应的 http 代理连接信息
  8.     浏览器里测试,可用

参考:https://www.liquidweb.com/kb/how-to-install-squid-caching-proxy-on-centos-7/

赞(8)
未经允许不得转载:WM云建站 » 在 CentOS 7 系统里安装 squid

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址