The host 10.21.3.69 has no H3C client, so it can't access the internet. With Tinyproxy, we can setuup a proxy server on 10.21.3.31 to enable 69 access the internet.
Server Setup
-
Install tinyproxy with
apt-get install tinyproxy
. On CentOS 7:sudo yum install epel-release; sudo yum install tinyproxy
; -
Configure the proxy server by edit the configuration file with
sudo vi /etc/tinyproxy/tinyproxy.conf
:i. modify listening port to 8848;
i. Comment out "Listen 127.0.0.1", or only client on localhost can use this proxy;
i. Allow incoming clients:
Allow 10.21.3.69
orAllow 192.168.0.0/16
; -
Apply the changes:
sudo service tinyproxy restart
(orsudo systemctl restart tinyproxy
);
Monitor the log with: sudo tail -f /var/log/tinyproxy/tinyproxy.log
.
After job is done, run sudo service tinyproxy stop
to stop the server.
Client
Used with browser:
https_proxy=http://10.1.2.179:8848 http_proxy=http://10.144.251.179:8848 chromium-browser
Used in console:
sudo su -
http_proxy=http://10.1.2.179:8848 apt upgrade -y
For dropbox client: in [Preferences > Proxies]:
-
Proxy type: HTTP
-
Server: 10.1.2.179
-
Port: 8848