且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

正向代理squid 以及tinyproxy的安装方法(centos8上)

更新时间:2022-06-02 16:56:42

https://github.com/tinyproxy/tinyproxy.github.io
//初始位置在,源码安装,因为没找到yum源
/root

git clone git://github.com/tinyproxy/tinyproxy
cd tinyproxy
autoreconf -i
./configure
make
cd docs/web
make

启动服务器代理tinyproxy方法
/root/tinyproxy/src/tinyproxy -c /root/tinyproxy/etc/tinyproxy.conf
杀掉之前进程重启方法

kill -9 $(ps aux | grep tinyproxy | grep -v grep | tr -s ' '| cut -d ' ' -f 2) && /root/tinyproxy/src/tinyproxy -c /root/tinyproxy/etc/tinyproxy.conf
ps aux | grep tinyproxy | grep -v grep | tr -s ' '| cut -d ' ' -f 2 | xargs kill -9 && /root/tinyproxy/src/tinyproxy -c /root/tinyproxy/etc/tinyproxy.conf

《========================================================》

//yum安装
yum -y install squid
vim /etc/squid/squid.conf

//修改配置文件的服务端口以及允许所有访问

http_access deny all

http_access allow all
http_port 5678

//启动服务,以及停止服务命令
systemctl start squid.service
systemctl stop squid.service