### 安装方法: ``` yum install tinyproxy ``` ### 配置: vi /etc/tinyproxy/tinyproxy.conf Port 8888 //预设是8888 Port,你可以更改 Allow 127.0.0.1 //将127.0.0.1改成你自己的IP //Allow 192.168.1.0/24 #表示一个网络的IP //例如你的IP 是1.2.3.4,你改成Allow 1.2.3.4,那只有你才可以连上这个Proxy //若你想任何IP都可以连到Proxy在Allow前面打#注释 ### 启动停止服务 ``` chkconfig tinyproxy on service tinyproxy start service tinyproxy stop service tinyproxy restart ``` ### 本地测试 打开终端输入: ``` curl -x : www.baidu.com ``` 返回百度页面代码,说明代理成功。 ### 查看代理请求日志 ``` tail -f /var/log/tinyproxy/tinyproxy.log ``` ### 检测服务 ``` netstat -anpt | grep tinyproxy ``` ###开机自启 ``` chmod +x /etc/init.d/tinyproxy chkconfig --add tinyproxy chkconfig --level 2345 tinyproxy on ``` Loading... ### 安装方法: ``` yum install tinyproxy ``` ### 配置: vi /etc/tinyproxy/tinyproxy.conf Port 8888 //预设是8888 Port,你可以更改 Allow 127.0.0.1 //将127.0.0.1改成你自己的IP //Allow 192.168.1.0/24 #表示一个网络的IP //例如你的IP 是1.2.3.4,你改成Allow 1.2.3.4,那只有你才可以连上这个Proxy //若你想任何IP都可以连到Proxy在Allow前面打#注释 ### 启动停止服务 ``` chkconfig tinyproxy on service tinyproxy start service tinyproxy stop service tinyproxy restart ``` ### 本地测试 打开终端输入: ``` curl -x <IP>:<PORT> www.baidu.com ``` 返回百度页面代码,说明代理成功。 ### 查看代理请求日志 ``` tail -f /var/log/tinyproxy/tinyproxy.log ``` ### 检测服务 ``` netstat -anpt | grep tinyproxy ``` ###开机自启 ``` chmod +x /etc/init.d/tinyproxy chkconfig --add tinyproxy chkconfig --level 2345 tinyproxy on ``` Last modification:February 2, 2022 © Allow specification reprint Like 如果觉得我的文章对你有用,请随意赞赏