Centos7.9_Huawei OpenEuler system_Personal test was successful_The agent used the intranet machine_Through the springboard machine_Set up the agent for networking_Perform Yum install software installation---Linux work notes 061

[[email protected] /]# telnet 10.233.255.199 10000
Trying 10.233.255.199...
Connected to 10.233.255.199.

First, use telnet to confirm whether our shift machine can connect to the Internet.

That is to say, our current server cannot connect to the Internet, but if we want to use yum to install software, it will definitely not work without the Internet. We are not allowed to connect to the Internet due to security issues.

At this time, we can find a machine that can connect to the Internet, open tcp and upd on port 10000, and then proxy our machine that cannot connect to the Internet to the corresponding 10000 port of the machine that can connect to the Internet. For example, this will allow us For machines that cannot be connected to the Internet, connect to the Internet to install the software. After installing yum, just disconnect the agent.

[root@host-10-233-255-198/]# ping www.baidu.com
/etc/host.conf:行 3:错误命令“nospoof on”
ping: www.baidu.com: 未知的名称或服务
[root@host-10-233-255-198/]# export https_proxy=http://10.233.255.199:10000  //设置代理
[root@host-10-233-255-198/]# cd /etc/yum  //进入yum源
yum/         yum.repos.d/ 
[root@host-10-233-255-198/]# cd /etc/yum.repos.d/ 进入yum源
[[email protected]]# ll
总用量 8.0K
-rw-r--r-- 1 root root  529  4月 27 19:14 openEuler.repo
-rw-r--r-- 1 root root 2.0K  4月 27 19:08 openEuler.repo.bak
[[email protected]]# vim openEuler.rep

Guess you like

Origin blog.csdn.net/lidew521/article/details/132227976